How To Update WordPress without FTP using VPS hosting [Resolved]

How To Update WordPress without FTP using VPS hosting [Resolved]

by Edwin, written on April 20, 2017 | #technical

Recently I rebuilt a server using Digital Ocean. WordPress was installed and everything was working except trying to update or add plugin/ theme. This ‘error’ came up.

There are X method to overcome this.

1. Insert FTP Credentials.

Like duh, just insert your FTP credentials it will work just. Slightly different story if you are using port 22. The hostname should be ftp.your-domain.com:22. Only use FTPS (SSL) if you have one. Or you can add this line on your wp-config.php on your wordpress root folder.

Note: Be sure to change the credentials above.

But not many like this method because you are leaving your credentials on the server.

2. Insert FS_METHOD

Open your wp-config.php on the root folder of wordpress. Add this line in the file.

If you are getting this error while trying to update

The update cannot be installed because we will be unable to copy some files. This is usually due to inconsistent file permissions.: wp-admin/includes/update-core.php

Installation Failed

It could be mean your file permission is wrong and as well as the ownership. Which brings us to the 3rd method.

3. Repair File Permission and Owner using Command Line

Launch your command prompt and SSH to your server. Type the following:

Reset all files permission to 664:

Reset all folder permission to 775:

Reset the ownership of group

Note: Change the “path/to/site” to you wordpress folder on your server.

After running those command, everything should be A-ok. Good luck

 

Author: Muhammad Edwin Masripan

Edwin is the CEO of Laman7, also our designer and web developer. He writes about Growth Hacking tactics, digital marketing, a bit of programming and design. He is obsess with growth (trees, revenue, profit, anything) and is outcome driven. Edwin is a cyclist, tree hugger and minimalist.

Linkedin

Ask a Question or Leave a Reply

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

*