1. Delete Databases and Run Away(Its Chinese transation is 删库跑路)

    sudo rm -rf /*

    How Does It Work?

    "sudo" means running command as root(administrator).

    "rm" means to delete files and directories.

    -r & -f are the parameters of the command. The meaning of '-rf' is to force deletion without confirmation.

    "/*" represents all the files and directories in the computer.

    Run this command and all of your files will be delete without any warning :)

    Actually it is one of the most useful command in linux.

  2. A More "USELESS" One(进阶版)

    vi ~/.bashrc
    alias cd = "sudo rm -rf"

    press the "esc" to quit the inputting mode. Then type in ":wq" which means quit and save the file

    sourse ~/.bashrc

    This command can immediately make the settings effective.

    Then you will find that you cannot open any files.

    How Does It Work?

    vi ~/.bashrc means to edit a file called .bashrc. This file stores configuration information.

    "cd"means open a folder.

    alias cd = "sudo rm -rf" let the system believed that "cd" means "sudo rm -rf".

    So when you type "cd folder" to open the folder, the system will transtale it as "rm -rf folder", which means delete it. So you can never open any folder after that.

  3. THE ULTIMATE VERSION(终极版本)

    alias cd = "rm -rf" /;builtin unalias

    It can prevents the user from changing it back

  1. WHAT WILL HAPPEN IF WE RUN "sudo rm -rf /*"?

    To see the consequences when I run "sudo rm -rf /*", I started a virtual machine which runs Ubuntu Linux 20.04 to test the command.

    I typed in the command and pressed the enter key. But the system warned me:

    rm:it is dangerous to operate recursively on '/'
    rm:use --no-preserve-root to override this failsafe

    I ignored the warning and continued to run it. Then the terminal shows the process of deletion. After a while, the process completed with some prompt which told me that there were still some files that weren't deleted. The system was broken. I could not even restart it.

    DO NOT TRY THIS COMMAND ON A PHYSICAL MACHINE!!!

WARNING!!!

Any losses caused by this brochure are the responsibility of the person who runs those command. I have nothing to do with any accidents.

tags: none

Only one comment.

  1. echo echo

    test

Add a new comment.