Why is “chmod -R 777 /” destructive?

First of all a minor terminology nitpick: chmod doesn’t remove permissions. It CHANGES them. Now the meat of the issue — The mode 777 means “Anyone can read, write or execute this file” – You have given permission for anyone to do (effectively) whatever the heck they want. Now, why is this bad? You’ve just … Read more

changing the owner of folder in linux

Use chown to change ownership and chmod to change rights. use the -R option to apply the rights for all files inside of a directory too. Note that both these commands just work for directories too. The -R option makes them also change the permissions for all files and directories inside of the directory. For example will change ownership (both user and group) … Read more