Closed (cannot reproduce)
Project:
Drupal core
Version:
6.x-dev
Component:
install system
Priority:
Minor
Category:
Bug report
Assigned:
Unassigned
Reporter:
Created:
5 Feb 2008 at 21:34 UTC
Updated:
20 Jun 2011 at 08:51 UTC
The Drupal created directories, files have incorrect user and group settings. Example:
balu@vas:~/projects/drupal/6/RC3/sites/default$ ls -al
total 20K
drwxr-xr-x 2 balu users 1.0K 2008-02-05 19:29 CVS/
-rw-r--r-- 1 balu users 8.8K 2007-12-20 10:35 default.settings.php
drwxr-xrwx 3 balu users 1.0K 2008-02-05 19:30 files/
-r--r--r-- 1 nobody 4294967295 8.8K 2008-02-05 19:30 settings.php
This is from my local machine, but I just had the "luck" of bumping into this on a shared host, where I can't remove these files using cPanel. The last line is the Drupal created settings php.
Its not possible to write such files, not even using PHP based file manager (that normally should work since it runs under the webserver privileges). As a restult if you do install Drupal 6 on a host where you don't have root privileges it will be impossible to remove.
Comments
Comment #1
snufkin commentedi tried with uploaded files, same result. invalid user and group, which means the sites/default/files directory will be impossible to remove on hosts where one can't get root privileges. im setting it to critical, and hope someone can reproduce it.
my local testing environment was linux, shared host unknown (probably linux too).
Comment #2
scoutbaker commentedI have not had any issues in this regard. I've been working with RC3 and DEV without any issues on a shared hosting system. As a quick test, I just went in and deleted the files directory using cPanel. Then in D6 under Administer-Site configuration-File system I clicked Save Configuration and was able to recreate the directory and then delete it again.
Comment #3
techczech commentedThis is related to the discussion in http://drupal.org/node/194369.
Comment #4
snufkin commented#2: there is a /files folder which is shipped with Drupal, but by default it uses /sites/default/files, which is not. And the issue won't come up with this directory unless it was created by drupal. Try deleting an uploaded file to see if you can reproduce the issue .
Comment #5
pwolanin commentedum, this has been true for all of 6.x. Perhaps we should ship a little helper script to fix this? A PHP-based file manager must be able to set the permissions back, since PHP set them in the first place.
The problem may also occur for all files uploaded by Drupal, so you won't be able to remove any of the uploaded files. This is true for 5.x, 4.7.x, etc.
Comment #6
scoutbaker commented@snufkin: There is no files folder. I did my testing against the sites/default/files folder created by Drupal, or recreated after I deleted it. I was able to successfully delete the uploaded files in the folder, and the folder itself. I also teste using both Public and Private files settings.
Comment #7
snufkin commentedpwolanin: its not true for 5.x, there an uploaded file for example gets
-rw-rw-r-- 1 nobody users, so basically inherits the directory structure around and adds no user ownership.ScoutBaker: can you by any chance check what are the file attributes and ownership settings for these created files on your install?
Comment #8
snufkin commentedI failed to reproduce it on another machine, though on my local computer i can, and also on the shared host. It seems this is PHP dependant, worked: PHP 5.2.0-8+etch7, not worked: PHP 5.2.5
Comment #9
scoutbaker commentedI don't currently have access to the ownership information on the shared host. The site is running on PHP 5.2.5 there however.
Comment #10
dpearcefl commentedThis sounds like a OS and filesystem issue to me. is this still a reproducible issue?
Comment #11
snufkin commentedI think you are right and its an OS related issue, so i'll close it.