Never execute the 10 most dangerous commands in Linux

  
        The Linux command line is useful, efficient, and fun, but sometimes it's dangerous, especially if you're not sure what you are doing. This article is not intended to provoke your anger at the Linux or Linux command line. We just want to make you realize that you should think twice before you run certain commands. (Annotation: Of course, the following commands are usually under the root authority to play stupidity to hopelessness; under the ordinary user identity, the destruction is only one acre of three acres.)
1. rm -rf Commands
The rm -rf command is one of the fastest ways to delete a folder and its contents. Just a little bit of mistake or ignorance can lead to an unrecoverable system collapse. The following are some of the options for the rm command.
The rm command is usually used to delete files under Linux.
The rm -r command recursively deletes folders, even empty folders. (Annotation: Personally think that this should be wrong, from common sense, it should be "even a non-empty folder")
rm -f command can directly delete & lsquo; read-only file & rsquo; . (Annotation: Linux delete files does not care whether the file is read-only, but just care whether its parent directory has write permission. Therefore, the -f parameter simply means that you do not have to delete the confirmation one by one, but will be silently deleted. The original rm command does not actually delete the prompt, but the general distribution will add rm by alias to the -i parameter to request deletion confirmation, and -f suppress this prompt.)
rm -rf /: Forcibly delete all the roots under the root directory. (That is, after the deletion is completed, nothing is done...)
rm -rf *: Forces deletion of all files in the current directory.
rm -rf . : Forces deletion of the current folder and its subfolders.

From now on, be careful when you want to execute the rm -rf command. We can create an rm-i alias in the “.bashrc” file pair ‘rm‘ command to prevent accidents when deleting files with the ‘rm‘ command, which will ask you to confirm each delete request. (Annotation: Most distributions have already done this, if not, please do so, and must consider what you are doing before using the -f parameter! The translator himself has a lesson of blood and tears.)
2. :(){:
Copyright © Windows knowledge All Rights Reserved