• Home
  • The Song
  • The Avatar
  • The Cat
  • Contact the Cat

Gyp the Cat dot Com

WordPress not Updating – Asking for FTP Details – Fixed
internet

WordPress not Updating – Asking for FTP Details – Fixed

I was asked to have a look at a particular problem on a WordPress site, where nothing was auto updating at the click of the appropriate button, it was going and asking for FTP details that we didn’t have and shouldn’t have even needed.

Firstly I made sure that the wp-content director had permissions as 755, it did, and still not working.

It transpires that there was another problem in that the directories were not owned by process running Apache.

Logon to your Ubuntu box via SSh.

Type in the following:

ps aux | grep ‘apache’

You should be looking at something like this:

root@ubuntu-box:/# ps aux | grep ‘apache’
root 2233 0.0 2.3 44900 12032 ? Ss Jul21 1:37 /usr/sbin/apache2 -k start
www-data 3536 0.0 6.1 66468 31244 ? S Aug12 0:08 /usr/sbin/apache2 -k start
www-data 4043 0.0 6.3 66884 32512 ? S Aug12 0:11 /usr/sbin/apache2 -k start
www-data 4376 0.0 5.6 64156 28832 ? S Aug12 0:07 /usr/sbin/apache2 -k start
www-data 5205 0.0 6.4 67988 32892 ? S Aug12 0:10 /usr/sbin/apache2 -k start
www-data 7051 0.0 5.5 63664 28272 ? S Aug12 0:04 /usr/sbin/apache2 -k start
www-data 9724 0.0 6.4 68040 32884 ? S 05:41 0:02 /usr/sbin/apache2 -k start
www-data 10130 0.0 4.7 60648 24204 ? S 06:28 0:00 /usr/sbin/apache2 -k start
www-data 10554 0.0 5.4 63600 27780 ? S 07:32 0:01 /usr/sbin/apache2 -k start
www-data 10968 0.0 1.0 44900 5576 ? S 08:34 0:00 /usr/sbin/apache2 -k start
www-data 10992 0.0 1.0 44900 5332 ? S 08:35 0:00 /usr/sbin/apache2 -k start

This will tell us who the Apache service is running as, in our case it’s running as www-data user.  Now we need to know the UID of the user, type in:

id www-data

You should see something like:

root@ubuntu-box:/# id www-data

uid=33(www-data) gid=33(www-data) groups=33(www-data)

Excellent, we’ve got all we need, now we need to update the permission WordPress is using with the chown command, like this:

chown -hR [user]:[group] /path/to/http/directory

So:

chown -hR www-data:www-data /var/companya.com/httpdocs

Or:

chown -hR 33:33 /var/companya.com/httpdocs

Leave that command to run, and you’re all done.  Log back onto WordPress, and update freely.

Wordpress Successful Updates
Wordpress Successful Updates

Related

Written by gyp - August 13, 2011 - 2742 Views
Tags | apache2, linux, wordpress

You Might Also Like

Backing Up All MySQL Databases Individually using Cron

November 11, 2012

Blocking Countries on Nginx without the GeoIP Module

April 25, 2015

Saving Bandwidth the Postfix Way

October 26, 2010

1 Comment

  • How to Install Wordpress with SSH and Nginx | Gyp the Cat dot Com July 12, 2012 at 9:51 pm

    […] make sure that the WordPress permissions are comfortable. chown -hR […]

    Reply
  • Please Post Your Comments & Reviews
    Cancel reply

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

    Previous Post
    Next Post

    Latest Posts

    • How to Convert CSV to Parquet Easily with Python on Linux Shell
    • Kusto Geolocation IP Lookup
    • Monitoring Tor Usage in Azure Sentinel, ASC, MDATP and ALA
    • HTTP to HTTPS Redirect on Azure CDN
    • Strongswan IPSec (Including Cryptomap) to Microsoft Azure Virtual Network Gateway
    • Black Ops 3 NAT Type Strict & PS4 NAT Type 3 with pfSense Fixed!
    • Sorry for the lack of posts
    • How to Block Internet Access with Group Policy (GPO)
    • Enforcing Microsoft Office 365 and Azure Tennancy with McAfee Web Gateway (MWG)
    • Scanning Subnet for Issuing Certificate Authority with OpenSSL

    Top Posts & Pages

    • How to Block Internet Access with Group Policy (GPO)
      How to Block Internet Access with Group Policy (GPO)
    • How to Configure Windows 2012 NPS for Radius Authentication with Ubiquiti Unifi
      How to Configure Windows 2012 NPS for Radius Authentication with Ubiquiti Unifi
    • Kusto Geolocation IP Lookup
      Kusto Geolocation IP Lookup
    • Tinyproxy A Quick and Easy Proxy Server on Ubuntu
      Tinyproxy A Quick and Easy Proxy Server on Ubuntu
    • Monitoring Tor Usage in Azure Sentinel, ASC, MDATP and ALA
      Monitoring Tor Usage in Azure Sentinel, ASC, MDATP and ALA
    • How to DNSPerf on Ubuntu 14.04 with Installation and Quick Start
      How to DNSPerf on Ubuntu 14.04 with Installation and Quick Start
    • How to Add Different Disclaimers using alterMIME and Postfix based on Domain
      How to Add Different Disclaimers using alterMIME and Postfix based on Domain
    • Blocking Countries on Nginx without the GeoIP Module
      Blocking Countries on Nginx without the GeoIP Module
    • How to Enable Squid Anonymous Stealth Mode
      How to Enable Squid Anonymous Stealth Mode
    • Configuring Suite B, VPN-A and VPN-B in IPSec with Strongswan
      Configuring Suite B, VPN-A and VPN-B in IPSec with Strongswan

    Tags

    apache2 azure azure log analytics blops business centos cheating cissp cloudflare cryptography dns game google gyp internet iphone ipsec isc linux mac marketing microsoft mw2 mx mysql nginx pfsense postfix proxy ps3 qualification radius revision security seo smtp socks squid ssh strongswan tinyproxy ubuntu windows 2012 wordpress xdecrypt.com
    Gyp the Cat dot Com

    Some rights retained Gyp the Cat Dot Com