How can I undo the following command: chmod -R a+rwX /
? I used it to modify some permissions, but it did not do as I had expected.
-
2Usually you need to re-install. I have seen only one person recover from this problem.– PantherNov 15, 2013 at 4:13
-
@bodhizazen, How did they do it?– tjonsNov 15, 2013 at 4:17
-
3@TJonS I know 1 person that compared each individual file to the file on another system. I would re-install...– RinzwindNov 15, 2013 at 6:38
-
if you search this site, someone posted a script here on this site. otherwise it is as Rinzwind indicated, one file at a time. considering it takes 15 min to re-install ...– PantherNov 15, 2013 at 13:30
-
I reinstalled. Was very easy– tjonsNov 15, 2013 at 15:05
1 Answer
I had a similar issue faced once.
Now you have two options as you have changed the permission of /
and a lot of services depends upon it. (Ex: most probably your sudo su
must not be working etc.)
The short way is to re-install your system again. This is the best way I would recommend take backup of your files and data and do a re-install.
The long way is to you will have to boot your system in recovery mode then mount the
/
partition inrw
mode usingmount -o remount,rw /
mount --all
and then you will have to set permissions of various services manually so yes it is possible to do that but for this you need to know what are the permissions of these services in a default ubuntu working OS.
Now in this case you may seem to change the permission of many of the services but there are chances that you may miss alot of special permissions which may cause problem in the near future.