Question

Ubuntu + Wordpress not accessible anymore

Posted May 19, 2015 10.5k views
WordPressDigitalOcean 1-Click Apps Marketplace

Hey,

After creating a droplet (with the included one-click installation for wordpress) it’s impossible for me to access Wordpress again.

It all started with installing a Wordpress theme from Themeforest that got denied by Wordpress auto theme installer, so I had to upload the files manually by (s)FTP in the provided Wordpress dir.

I had to fix SSH (login with SSH keys).

After login I did “ls” => WORDPRESS and checked the cd /var/www => this dir only contains a wp-config.php file

but when I try to access Wordpress on site I get the following error

Not Found

The requested URL /wp-admin/ was not found on this server.

and when visiting the website without /wp-admin/ I get

Forbidden

You don’t have permission to access / on this server.

I really have no clue what went wrong, anyone could help me out to get wordpress up & running again? ( @sierracircle )

Kind regards.

Maxime

5 comments
  • Hi Maxime,

    First thing to check might be permissions. You could run these two commands:

    sudo chown -R www-data:www-data /var/www
    sudo chmod -R 774 /var/www
    

    then try to access your site. Does that make any difference?

    Also:

    Do you have an sftp client you can use to access your droplet folders?
    What OS is your computer running?

  • Hi @sierracircle ,

    I use Mac OSX (Yosemite). And I have a SFTP client I can use.

    sudo chown -R www-data:www-data /var/www
    sudo chmod -R 774 /var/www
    

    These are applied and don’t make any difference

  • OK.

    do you have a user (other than root) that you use to log in via sftp?

    if so, run this (which will make a link to the web folder)

    ln -s /var/www ~/
    
  • Hi @sierracircle , I don’t have any other user than root.

    The “troubles” started when I was playing around with adding SSH key to perform SSH from Mac OSX Terminal.

  • I see. It is difficult to know exactly what happened, so I am sort of going down a list to see where how things stand.

    Worst-case scenario is that you accidentally deleted your Wordpress files, but I don’t think it is that.

    Okay, what do you see when you sftp into your droplet and view the folder /var/www

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.

×
Submit an Answer
22 answers

@sierracircle => cd /var/www => this dir only contains a wp-config.php file

  • ok. I have never used the one-click wordpress install, but there might be a different folder that DigitalOcean uses.

    In your root folder, is there a folder called WORDPRESS? /root/WORDPRESS
    if so, what is in there?

another question: is this a fairly new Wordpress install? Did you add a lot of content?

If it is a new install we could just hose everything and re-install WP…not a huge job to do that. Your db is probably still intact, so the only thing you would lose is any images or files you uploaded.

@sierracircle it was a fresh install. and there is a dir /root/WORDPRESS

can you see the contents of /root/WORDPRESS

I wonder if that is where it is installed at?

@sierracircle if I try to do CD WORDPRESS I get

root@BELPOLTEX:~# cd WORDPRESS
-bash: cd: WORDPRESS: Not a directory

ah. It is a file, not a directory.

@sierracircle aha. So there must have gone something wrong?

so, a few options here: we can spend more time investigating if your files might be somewhere.

you can do a clean install of Wordpress on your existing server (I can install Wordpress in about 5 minutes.

you can nuke your entire droplet and create a new one.

You can do a quick search like so:

find / -type d -name "*wp-admin*" -print

should tell you if there is a folder named wp-admin anywhere

@sierracircle I did the

“`root@BELPOLTEX:~# find / -type d -name ”wp-admin“ -print
root@BELPOLTEX:~#

So there is not a folder to be found.

I prefer to do a clean install of Wordpress but want to be sure it will be very good secured installation.

Any ideas? Or How-Tos? (not really my strongest field)

Thanks already for the help!

I am willing to spend a little time walking you through some steps, if you have the time now. Otherwise I can point you to a few tutorials

Previous 1 2 3 Next