reset all the permissions to the default permissions under CentOS

Above command combination will reset all the permissions to the default permissions under CentOS / RHEL / Fedora Linux.

 

Reset the permissions of the all installed RPM packages
You need to use combination of rpm and a shell for loop command as follows:

for p in $(rpm -qa); do rpm –setperms $p; done
for p in $(rpm -qa); do rpm –setugids $p; done

 

http://forum.parallels.com/showthread.php?t=108924

Leave a comment