David Nash

Wordpress Guru Sydney

Fixing Windows File Permissions in Linux

Posted on February 20, 2009

Find all files (not directories) and remove the eXecutable bit. I don’t know what the characters on the end do:
find . -type f -exec chmod a-x {} \;

Make all directories executable to user, read/writable to groups others (good for when the web server is in ‘others’):
find . -type d -exec chmod 755 {} \;

Make all files read/write/executable for user, readable for the group and others:
find . -type f -exec chmod 644 {} \;

Leave a Reply

Your email address will not be published. Required fields are marked *

*

You may use these HTML tags and attributes: <a href="" title=""> <abbr title=""> <acronym title=""> <b> <blockquote cite=""> <cite> <code> <del datetime=""> <em> <i> <q cite=""> <strike> <strong>