Take the 2-minute tour ×
Server Fault is a question and answer site for professional system and network administrators. It's 100% free, no registration required.

wordpress uses the wp-content folder to store uploads, and the uploads are also stored in their own folder depending on the month you upload the file like:

wp-content/uploads/month/day/file.jpg

the folder needs 755 permissions and I believe on all sub-folders.

How can i do this?

share|improve this question
add comment

3 Answers

up vote 1 down vote accepted

to change existing files and folders: chmod -R 755 *

to change future files umask 022

share|improve this answer
add comment

The folder only needs 700 permission. All access should be done as the apache user (www-data on ubuntu). To ensure the appche sets 755 permisions on directories ensure it is run with 'umask 022'. It is important that the directory be owned writable by the web-server user.

It is more secure to have only the uploads directory writable by apache. However, it means you will need to update themes, plugins, and languages by another mechanism. The Ubuntu package uses /var/www/wp-uploads as the uploads directory.

share|improve this answer
    
I'm using nginx, so I guess I need to give www-data the permissions right? –  Blankman May 31 '10 at 17:07
add comment

Generally, if you get the perms right on the wp-content/uploads folder the newly created subfolders should inherit them as they're created.

share|improve this answer
add comment

Your Answer

 
discard

By posting your answer, you agree to the privacy policy and terms of service.

Not the answer you're looking for? Browse other questions tagged or ask your own question.