Rate Thread
  • 0 Vote(s) - 0 Average
  • 1
  • 2
  • 3
  • 4
  • 5
Never type this stuff into your computer
#1
....Unless you know what you're doing. This example will apply to linux distros (and MacOS) (although there's plenty of stuff for Windows so don't worry).

Part of the problem with linux is a lot of instructions for linux involve the terminal (command line) and a lot of novice users will copy/paste commands into the terminal without understanding what the command really does.

The more popular dirty trick is this...

Code:
sudo rm -rf /*

Running this command will erase everything off the computer, including any mount points so this would erase data in other places.

sudo is short for super user do, this is a security mechanism to prevent commands that need elevated privileges from running, sudo requires the user to enter the supervisor password or a user account that has sudo access.

rm is the remove command, the -r means recursive, meaning that rm will drill into sub folders. The -f means to remove by force, such as read only files or locked files. Finally / is the "root" directory. The filesystem structure in linux is much different than windows, / can include all hard disks, network shares, devices, etc, that are present on the computer. Lastly the * is what makes this command particularly destructive. The asterisk is a wildcard, having it by itself will match everything, since it matches everything and we're recursing through the filesystem everything will get erased.

However, if that command isn't evil enough this command is it's more sinister brother...

Code:
sudo dd if=/dev/urandom of=/dev/sda bs=1M

DD has been coined the term "disk destroyer" and for good reason. Not understanding how DD works can...well destroy everything on your hard drive. However, dd has very useful purposes such as making an exact backup of your hard drive in this example:

Code:
sudo dd if=/dev/sda of=/dev/sdb

The "if" means input file and "of" is output file. The urandom in the above example is a pseudo device present in linux that creates random data. So you guessed, it running the above command will write random data to the hard disk sda. This can be useful if you're wanting to erase the contents of the hard drive but often we're not wanting to do that. The second command will copy the hard drive sda to sdb.

The bottom line is if you're new to linux and following tutorials don't blindly copy and paste stuff in to the terminal. Looks up what the commands do first. Yes, a lot of tutorials and blogs aren't nefarious but you can never be sure. Also make sure that if you are following a guide that it is written recently, sometimes things change, programs get depreciated and so forth.

In Windows 10, Microsoft has PowerShell which is more or less the equivalent of the Linux Terminal in Windows, so much of the same "power" exists in PowerShell that exists in the Linux terminal, so you also have to watch out there are well although most of the commands in PowerShell are more spelled out in my opinion.
"I’m not expecting to grow flowers in a desert, but I can live and breathe and see the sun in wintertime"
Check out my stuff!
Reply

#2
If you know what you're doing, DD can be quite useful. Yes, it's risky but not in the hands of an experienced user. However, it's also quite pointless - esp. if you're using it to create a bootable USB drive (this is the most popular function of DD), bc there are many FOSS programs that do it perfectly, not to mention faster.

As for the remove command, it's perfect if you use it in the mount point of a Windows 10 installation... Big Grin
Arch Linux, Core i7 4770, GTX 1660 Ti 6GB, 32GB DDR3 RAM
home is where root is.
Reply

#3
(02-26-2021, 08:43 PM)rado84 Wrote: If you know what you're doing, DD can be quite useful. Yes, it's risky but not in the hands of an experienced user. However, it's also quite pointless - esp. if you're using it to create a bootable USB drive (this is the most popular function of DD), bc there are many FOSS programs that do it perfectly, not to mention faster.

As for the remove command, it's perfect if you use it in the mount point of a Windows 10 installation... Big Grin

Oh yes, dd is useful, just one typo away from oh shit! lol And I agree that it is just easier to build a bootable USB from a GUI app.

As far as removing Windows 10 installation I think dd is also a good use case since who wants NTFS?

To be honest I do have a Windows 10 install on my machine alongside Linux, but not your typical dual-boot setup, at least not in the "traditional" sense. Instead of allowing GRUB and Windows sharing the same boot space I simply have it where GRUB is on the disk with Linux and the Windows Bootloader is on the disk with Windows. Also have Linux in RAID 10 with 3 SSD's so it runs pretty nice. Oh it's about time I start planning my next system build this 6700k is getting long in the tooth.
"I’m not expecting to grow flowers in a desert, but I can live and breathe and see the sun in wintertime"
Check out my stuff!
Reply

#4
(02-26-2021, 11:27 PM)InbetweenDreams Wrote: As far as removing Windows 10 installation I think dd is also a good use case since who wants NTFS?
I do bc the most games won't run properly from a linux file system, even with all the necessary permissions, especially the games on Steam. So I'm using NTFS, just not the Windows NTFS. My NTFS was created by GParted. There are some minor differences between NTFS created by Windows and the one created by GParted. I'm not sure what exactly the differences are but there are - a Windows NTFS (when empty) has 500 MB space occupied whereas the GParted NTFS has just about 100 MB space occupied right after file system creation. For some reason that makes the GParted NTFS less... stubborn, so to speak.


(02-26-2021, 11:27 PM)InbetweenDreams Wrote: To be honest I do have a Windows 10 install on my machine alongside Linux, but not your typical dual-boot setup, at least not in the "traditional" sense. Instead of allowing GRUB and Windows sharing the same boot space I simply have it where GRUB is on the disk with Linux and the Windows Bootloader is on the disk with Windows. Also have Linux in RAID 10 with 3 SSD's so it runs pretty nice. Oh it's about time I start planning my next system build this 6700k is getting long in the tooth.
I too have a dual boot with Windows 7 which I'm only using it for reprogramming the special keys of my gaming keyboard. This can't be done in Linux bc A4Tech wrote drivers only for Windows. When I installed Windows 7 I physically dettached the Linux SSD from the motherboard, installed Windows and then reattached the SSD to the motherboard. Thus Windows was unable to screw up GRUB and all I had to do was to simply enable os-prober.
Arch Linux, Core i7 4770, GTX 1660 Ti 6GB, 32GB DDR3 RAM
home is where root is.
Reply

#5
@rado84 Interesting, I'm a bit puzzled by that and my experience has been that NTFS is more of a pain to deal with under linux...especially in the old days. "Oh your NTFS partition is dirty, not going to mount it...still not going to mount it."

The reason for Windows is software and that is why Windows is relevant today, it's software. LibreOffice is fine and all but it just isn't quite as good as Microsoft Office. Like or Hate Microsoft it is a good product and as evil as Microsoft is they're not as evil as Amazon, at least their employees don't have to piss themselves in diapers...so, I'll give them that.

But yes, that was my approach as well, install them separately. Linux will be like GRUB will be the bootloader, then Windows is like the f*ck is this, here fixed your problem and Steve Ballmer gives you the stink eye.
"I’m not expecting to grow flowers in a desert, but I can live and breathe and see the sun in wintertime"
Check out my stuff!
Reply

#6
Never ever had that problem with mounting NTFS because of my fstab:

Code:
# /dev/sdb1 Arch Linux
/dev/sdb1    /             ext4          rw,relatime    0 1
/dev/sdc1 /media/1000GB ntfs-3g defaults,auto,nofail,x-systemd.device-timeout=10,uid=1000,gid=1000,umask=000 0 0
/dev/sda2 /media/390GB ntfs-3g defaults,auto,nofail,x-systemd.device-timeout=10,uid=1000,gid=1000,umask=000 0 0

But recently I had a weird case where Windows said a certain directory on the NTFS partition didn't exist and so it wouldn't open it whereas Linux never said such a thing and opened the said directory without a problem. Big Grin
Arch Linux, Core i7 4770, GTX 1660 Ti 6GB, 32GB DDR3 RAM
home is where root is.
Reply

#7
@rado84 I'm talking about like 15 years ago, but yeah much better now. Remember Mandrake Linux?
"I’m not expecting to grow flowers in a desert, but I can live and breathe and see the sun in wintertime"
Check out my stuff!
Reply

#8
(02-27-2021, 12:34 PM)InbetweenDreams Wrote: @rado84 I'm talking about like 15 years ago, but yeah much better now. Remember Mandrake Linux?
My first experience with Linux was with Ubuntu 10.10 which wasn't very responsive to drivers at the time, resulting at 1024x768 res at 60 Hz RR on a CRT monitor. Guess how much I enjoyed that, so in the next 5 years I rolled back to Windows. Only at the end of 2015 I moved to Linux Mint and only after I managed to fix (by myself) a problem that no linux guru was able to fix. And while there was a period of time when I was distro hopping and I've tried the most of the known distributions, I've never even seen Mandrake Linux. I may have heard that name somewhere bc it sounds vaguely familliar but that's it.
Arch Linux, Core i7 4770, GTX 1660 Ti 6GB, 32GB DDR3 RAM
home is where root is.
Reply

#9
@rado84 So Mandrake linux was a port of Red Hat back in the early 2000's. I had dial-up at the time and I downloaded 3 CD ISO files which took like 2 months or something since I was only able to download while I was online. I did figure out how to dual boot it with Windows after destroying Windows and Windows destroying Linux several times. I guess I did alright since I was like 16 and didn't know diddly squat about linux and you didn't have stack exchange so researching problems and how tos definitely not as easy as it is now. It was a neat distro. They renamed the distro to Mandriva and now called OpenMandriva. I also tried Gentoo Linux... Right now I just use Mint and Kubuntu, I really like KDE. Cinnamon just seemed to be more trouble and Gnome is just weird.
"I’m not expecting to grow flowers in a desert, but I can live and breathe and see the sun in wintertime"
Check out my stuff!
Reply

#10
(02-27-2021, 05:44 PM)InbetweenDreams Wrote: Right now I just use Mint and Kubuntu, I really like KDE. Cinnamon just seemed to be more trouble
Never had trouble with Cinnamon. On top of that any bug you report, it gets fixed eventually, whereas there are 5 years old bugs on KDE that Nate Graham says he doesn't know how to fix. KDE users found a way to fix it and offered solutions but Graham refused to fix it anyway. He had the nerve to tell KDE users they should pay someone else to clean up KDE's mess!

[Image: KDE-nate-graham-about-bugs.png]

There's also another bug about which Graham admits he has no idea how to fix it - multimedia keys don't work in KDE (at least not all the multimedia keys of my keyboard; only play and pause work) and the response was the same - "pay someone else to do our job". I don't understand why would anyone wanna use this desktop environment made by an arrogant pseudo-programmer. In Cinnamon, if there's a bug that comes with the new update and I report it, it gets a confirmed status and is fixed with the next update, I don't get a "fix it yourself" response from Lefrevre and his team!

I used Mint (18.3) for almost 4 years but it was breaking its own packages out of the blue, so I switched to Arch Linux which appears to be idiot proof. Now I'm so hooked to Arch that I can't use anything else and I tried. It's just that everything is happening so easily on Arch that every other distro feels like a freight train dragging 1500 train cars.
Arch Linux, Core i7 4770, GTX 1660 Ti 6GB, 32GB DDR3 RAM
home is where root is.
Reply



Related Threads…
Thread Author Replies Views Last Post
  Terrible Computer Products InbetweenDreams 5 1,791 06-01-2020, 01:08 AM
Last Post: InbetweenDreams
  Eye Relief for Computer Screen Display - f.lux add-on palbert 1 1,134 09-29-2014, 11:03 PM
Last Post: ChadCoxRox

Forum Jump:


Recently Browsing
1 Guest(s)

© 2002-2024 GaySpeak.com