Question

Wordpress permission issues using LEMP install on Ubuntu 12.04

  • Posted March 24, 2014

Hi all,

I used the tutorial over at https://www.digitalocean.com/community/articles/how-to-install-wordpress-with-nginx-on-ubuntu-12-04 to get a LEMP setup quickly up and running but I’m having troubles updating and using plugins that create files on the server (backup plugins).

The php5-fpm process seems to be running under my user, should it be running using www-data?

Any help would be much appreciated.

Subscribe
Share

Submit an answer
You can type!ref in this text area to quickly search our full set of tutorials, documentation & marketplace offerings and insert the link!

These answers are provided by our Community. If you find them useful, show some love by clicking the heart. If you run into issues leave a comment, or add your own answer to help others.

Can you pastebin php5-fpm’s config file and the output of the following two commands? <br><pre>sudo service php5-fpm restart <br>sudo ps wwaux | grep php5-fpm</pre>

Hi, <br> <br>I am not, I’m using BackWPup. Regardless of plugin, I’m sure that the process running under the wrong user can cause problems and I’d like to try and fix it anyway if possible.

taking a wild guess… <br> <br>are you using the Duplicator plugin? <br> <br>I tried that on my first droplet a few months ago, I quit because of issues with PHP. I decided to manually upload the backup (ftp the files, load the db through mysql). <br> <br>

Thanks for that leoadhemartan, so from what I understood of your reply, I ran: <br>sudo usermod -a -G www-data www-data <br>Which I’m assuming sets the ownership to the www-data user, however restarting the php5-fpm shows that my user is still the one running it (as opposed to www-data). <br> <br>What am I doing wrong?

Try <br> <br>sudo chown -R www-data:www-data /var/www <br> <br>From what I understand… The instruction in the article https://www.digitalocean.com/community/articles/how-to-install-wordpress-with-nginx-on-ubuntu-12-04 <br> <br>“Give ownership of the directory to the nginx user, replacing the “username” with the name of your server user. <br> <br>sudo chown www-data:www-data * -R <br>sudo usermod -a -G www-data username” <br> <br>reverts ownership to you as the user rather than www:data <br> <br>try to revert it back to www-data. <br>

In my www.conf file in /etc/php5/fpm/pool.d/ I have set the user to www-data yet for someone reason it’s still running under my user. <br> <br>Anyone have any ideas on how I can fix this?

On my installation php5-fpm has ‘www-data’ as the user. Also my htdocs folder belong to the user ‘www-data’ and the permission is set to 755

I should note, the specific error I am getting when trying to do anything is: <br> <br>WARNING: wp-includes/functions.php:1378 - mkdir(): Permission denied