When you have configured a remote server in Aegir (6.x-2.0) it appears that provision does not set the correct group permissions to the /private/temp folder. This problem occurs when you want to clone or migrate an existing drupal website on the remote webserver.

When the clone or migration process has been finished you cannot upload new media elements since the private/temp folder is not writable for the 'www-data' user. When you navigate to 'Configuration' > 'Media' > 'File system' you will see the following message: "The directory sites/your_website_ext/private/temp exists but is not writable and could not be made writable.". This problem only occurs on a remote webserver.

After some investigation I found out that the system did not set the group permissions on the /private/temp folder.

drwxrwsr-x   4  aegir  www-data  4096  Jan 20 11:6 files
drwxrwsr-x   4  aegir  aegir     4096  Jan 20 11:6 temp

The group for the temp folder should be 'www-data' but is 'aegir'. This is pretty easy to solve using the bash command chown

chown aegir:www-data temp

When you have to maintain a lot of websites this is not the ideal workaround. To solve this problem I have created a patch that adds an extra command to the deployment that changes the group permissions to aegir:www-data automatically.

Support from Acquia helps fund testing for Drupal Acquia logo

Comments

patrickwatzeels’s picture

FileSize
938 bytes
tvl’s picture

Same issue here, on Aegir 2.0, Redhat, apache 2.2.15, php 5.3.3
Patch #1 applied manually and works perfect.

Many thanks

  • helmo committed ad48db1 on 6.x-2.x-backports authored by pwatzeels
    Issue #2177315 by pwatzeels: Fixed Group permissions on private/temp...
  • helmo committed 4f71173 on 7.x-3.x authored by pwatzeels
    Issue #2177315 by pwatzeels: Fixed Group permissions on private/temp...
helmo’s picture

Status: Needs review » Fixed

Looks good, thanks :)

Status: Fixed » Closed (fixed)

Automatically closed - issue fixed for 2 weeks with no activity.