Unable to add content or install plugins on Wordpress

August 5, 2014 1.2k views

Hi there,

Since migrating my website to Digital Ocean (www.jamesgphotography.co.uk) I am unable to upload new content or install/update plugins due to file permission issues?

Can anyone help point me in the right direction?



Using Ubuntu 14.04

2 Answers

Did you try to change the chmod via ssh?

  • Hi

    I tried that but still doesn't seem to be working

  • What commands have you tried to run? Can you briefly describe your setup? (Where Wordpress is stored and what user you use to SSH in)

First find out the username of the PHP/Apache process by creating the following PHP script:

$processUser = posix_getpwuid( posix_geteuid() );
print $processUser['name'];

Access this script on your browser and it'll print a name, usually www-data or apache. Then execute chown as follows:

chown -R username:username /var/www/html/

Replace username with what the script printed.

Have another answer? Share your knowledge.