1- Linux administrator very often uses this command to format and assign the file system to the newly created disk partition.
But if used irresponsibly, this can also format the data drive on it:
$ mkfs.ext4 / dev / sda
Therefore, when using this command, make sure the correct disk partition is selected.
2- Remove directories / etc or / boot
/ etc contains all the system configuration files, and / boot contains all the kernel, InitRD, and GRUB files required to boot the system.
If you delete any of these folders, then your system will not boot:
$ rm -rf / etc
$ rm -rf / boot
Another way to remove your system configuration files and leave it irrecoverable is to use the following command:
$ find / -iname “* .conf” -exec rm -rf {} \;
This will find and remove all files ending in .conf (configuration files).
3- Delete entire filesystem
Most of you may know about this command, and it looks like this:
$ rm -rf /
This will remove the entire filesystem from your server, deleting every byte of data on the disk.
4- Fork bomb
This command creates copies of itself indefinitely, and in no time all the memory of your system will be clogged and therefore it will crash the system,
$ : () {: |: &} ;:
It can also damage the disc.
5- Fill the disk with random data
$ dd if = / dev / urandom of = / dev / sda
This will fill the disk with random data.
Another variation of this command overwrites the disk multiple times over the original data:
$ shred / dev / sda
This command is actually a useful tool, especially when you are throwing away your old drive and you don’t want the data from the old drive to fall into the wrong hands (and another way I learned from the movies is you can drill some holes in the drives as well) …
6- File Violation
All of the above commands are for deleting or overwriting data.
But there are ways to disable your system using file permissions.
First command:
$ chmod -Rv 000 /
This command will remove all file permissions for all files and folders on the system, and since no one will have permissions on files and folders, no one will be able to access them.
$ chown -R nobody: nobody /
ANY Doubt’s Shoot them on the discussion group.
