Review your favorite Linux distribution.
Go Back > Forums > Linux Forums > Linux - Newbie
User Name
Linux - Newbie This Linux forum is for members that are new to Linux.
Just starting out and have a question? If it is not in the man pages or the how-to's this is the place!


  Search this Thread
Old 05-21-2009, 07:17 AM   #1
LQ Newbie
Registered: Jul 2008
Location: Mumbai
Distribution: CentOs 5
Posts: 5

Rep: Reputation: 1
Unhappy Apache Permissions

I have a setup of apache , the users are working on it through network , I have added the 5 users to 1 group, and i have given the full rights for the group members , when working on base machine the users can change each others dirs and files bcoz default permission assigned to them is 775 , but when working on network if a user creates a folder and file then the permission get set is 755 , this causes the group members not to change each others dirs and file , now i want the users to create a dir or files with 775 even when working on network so that the users can change each dirs and files . hw can i do so..
Old 05-22-2009, 01:16 PM   #2
Senior Member
Registered: Nov 2004
Location: Texas
Distribution: RHEL, Scientific Linux, Debian, Fedora
Posts: 3,935
Blog Entries: 5

Rep: Reputation: Disabled
Given a group 'webusers' which contains your five users:
# mkdir /some/path/shared-folder
# chown root:webusers /some/path/shared-folder
# chmod 2770 /some/path/shared-folder
Now everything created within shared-folder will have group ownership of 'webusers'. You may additionally need to do a little umask magic to get things working just right.

For example:
$ umask
$ touch foo
$ ls -l foo
-rw-r--r-- 1 e e 0 May 22 12:14 foo
$ umask 0006
$ touch bar
$ ls -l bar
-rw-rw---- 1 e e 0 May 22 12:14 bar
Permanent umask settings changes can be placed in each users' ~/.bashrc file.
Old 05-22-2009, 02:18 PM   #3
Registered: Apr 2009
Posts: 107

Rep: Reputation: 19
This is not an Apache issue. Each directory created by a specific user will belong to that user with the standard restriction (permissions set to 755). Either the user has to chmod permissions to allow rw access for the group, or if directories are created and managed via a web interface, then the related script needs to take care of that. It is also possible to run a cron job with proper permissions to automatically adjust directory permissions for a certain directory hierarchy, but the previous suggestions are to be preferred.

Linux Archive

Last edited by soleilarw; 06-18-2009 at 05:07 AM.
Old 05-23-2009, 02:33 AM   #4
LQ Newbie
Registered: Jul 2008
Location: Mumbai
Distribution: CentOs 5
Posts: 5

Original Poster
Rep: Reputation: 1
Thanks a lot .....
Actually at back end there was samba server
So i just made a change in smb.conf
the entry of 2 lines
create mask=0775
directory mask=0775
then it worked out , now my clients when saving a dir or a file they are getting the group permission which was to be done ........
thanks a lot once again

Last edited by smoothpeddi; 05-25-2009 at 07:28 AM.


apache, permissions

Thread Tools Search this Thread
Search this Thread:

Advanced Search

Posting Rules
You may not post new threads
You may not post replies
You may not post attachments
You may not edit your posts

BB code is On
Smilies are On
[IMG] code is Off
HTML code is Off

Similar Threads
Thread Thread Starter Forum Replies Last Post
Apache file permissions problem. {Apache/2.2.6 Fedora 8} hacker supreme Linux - Server 5 01-31-2008 04:26 PM
Apache permissions MicahCarrick Programming 2 07-26-2006 05:38 PM
Apache permissions doing... nothing? wrbob Linux - Software 5 08-22-2005 09:46 AM
Apache permissions mylo2003 Linux - Newbie 7 08-01-2003 08:06 PM
apache permissions, maybe? roadie Linux - General 4 06-14-2001 10:52 AM > Forums > Linux Forums > Linux - Newbie

All times are GMT -5. The time now is 07:39 AM.

Main Menu
Write for LQ is looking for people interested in writing Editorials, Articles, Reviews, and more. If you'd like to contribute content, let us know.
Main Menu
RSS1  Latest Threads
RSS1  LQ News
Twitter: @linuxquestions
Facebook: linuxquestions Google+: linuxquestions
Open Source Consulting | Domain Registration