Resetting permissions and ownership on all DA related system files.


Enter Your Query:
Use '%' for wildcards and quotes for "exact phrases"


Top Level » System Level

Resetting permissions and ownership on all DA related system files.Last Modified: May 17, 2009, 2:35 pm
If you've just transferred all of your data to a new disk:
eg: http://www.directadmin.com/paths.html

if the ownerships and permissions are not correct, then you can get the set_permissions.sh script to do it for you:

cd /usr/local/directadmin/scripts
./set_permissions.sh all



Note that this script will not touch files uploaded by your users as it doesn't know what their permissions should be.
If you are not worried about potentiall permission problems and just want a very basic level of operation for all of the files your user have uploaded (eg, if all of their files are owned by root and you need to change them), then you can run the following for a basic reset of the permisisons:

cd /home
for i in `ls`; do { chown -R $i:$i $i; }; done;

But just as warning, this wipes all ownership settings, including any email data that may have a mail ownership, so you'd best run this script first, and the set_permissions.sh second to ensure any system related files (eg, mail inbox, spam, etc) are chowned correctly.
 
Related Helpfiles
How to create a full backup of all accounts via the command line.

2003 JBMC Software, Suite 173  3-11 Bellerose Drive, St Albert, AB  T8N 1P7  Canada.  Mon-Fri 9AM-5PM MST