LinuxQuestions.org

LinuxQuestions.org (/questions/)
-   Linux - Newbie (https://www.linuxquestions.org/questions/linux-newbie-8/)
-   -   Linux/Samba Share Permissions Problem (https://www.linuxquestions.org/questions/linux-newbie-8/linux-samba-share-permissions-problem-4175464023/)

Cloudthumper 05-29-2013 09:57 AM

Linux/Samba Share Permissions Problem
 
Linux: Centos 4.3
Samba: ??
No Windows server. Straight from the Linux file server to office PCs (Win7).

I found a permissions problem with a share on our Linux file server. I scoured the Internet for a solution and it kept circling around to the beginning. I guess that I don’t know how to ask the question.

Originally the share was created to give both myself and one other full drwx permissions to that share. The intent was for both of us to be able to create folders, files, etc. with each of us able to edit each other’s folders and files. When I set this person up about 2 weeks ago I found that not to be the case. While we can both create folders and files neither of us have permission to edit each other’s folders and files. I can’t edit hers and she can’t edit mine. We need to be able to edit each other’s.

I looked at the share and accounts but couldn’t see where to change the permissions or edit a file and, as I said, the Internet couldn’t answer my question because I guess that I don’t know how to ask it.

Any help would be gratefully appreciated.

rmugunthan 05-30-2013 03:00 AM

Post your share config for better understanding. Also post linux directory permission for that share.

If permission is the only problem means, try with "create mask" and "directory mask".

create mask: setting permissions for files.
directory mask: setting permissions for directory. Default value is 0755

Cloudthumper 05-31-2013 11:22 AM

Greetings rmugunthan --

Thanks very much for your reply.

I have included what I hope is the information you need. If not please let me know. I deleted a lot of entries to shorten the reply and I changed the names to protect the innocent. Thanks again for your help. - Cloudthumper

[root@charger samba]# cat smb.conf
[global]
workgroup = MARSHAL
server string = Marshal File Server
hosts allow = 192.168.1. 192.168.2. 127. 192.168.77.
printcap name = /etc/printcap
load printers = yes
printing = cups
cups options = raw
log file = /var/log/samba/%m.log
max log size = 50
security = user
encrypt passwords = yes
smb passwd file = /etc/samba/smbpasswd
unix password sync = Yes
passwd program = /usr/bin/passwd %u
passwd chat = *New*UNIX*password* %n\n *ReType*new*UNIX*password*
%n\n *passwd:*all*authentication*tokens*updated*successfully*
socket options = TCP_NODELAY SO_RCVBUF=8192 SO_SNDBUF=8192
domain master = yes
oplocks = no
kernel oplocks = no

[homes]
comment = Home Directories
browseable = no
writable = yes
create mode = 0664
directory mode = 0775
valid users = %S

[printers]
comment = All Printers
path = /var/spool/samba
browseable = no
guest ok = no
writable = no
printable = yes

[common]
comment = Public Documents
path = /home/shares/common
public = yes
writable = yes
printable = no
write list = @harry

[eawdb_websites]
comment = EAWDB
path = /home/shares/eawdb_websites
public = no (changed to yes)
writable = yes
printable = no
write list = @eawdb
[root@charger samba]#
- - - - - - - - - - - - - - - -
[root@charger etc]# cat passwd
(Lots of other stuff)...
thomas:x:505:506::/home/thomas:/bin/bash
smith:x:513:514::/home/smith:/bin/bash
[root@charger etc]#
- - - - - - - - - - - - - - - -
[root@charger home]# ls -la
total 100
drwxr-xr-x 19 root root 4096 Aug 30 2012 .
drwxr-xr-x 25 root root 4096 Nov 10 2012 ..
drwx------ 3 root root 4096 Feb 27 2006 backup
(Others)...
drwx------ 9 thomas thomas 4096 Sep 11 2012 thomas
drwx------ 2 smith smith 4096 Dec 26 10:55 smith
[root@charger home]#
- - - - - - - - - - - - - - - -
[root@charger shares]# ls -la
total 16
drwxr-xr-x 4 root technet 4096 Sep 11 2012 .
drwxr-xr-x 19 root root 4096 Aug 30 2012 ..
drwxrwxr-x 87 root technet 4096 Oct 3 2012 common
drwxrwxr-x 16 root eawdb 4096 May 24 08:23 eawdb_websites
[root@charger shares]#
- - - - - - - - - - - - - - - -
[root@charger eawdb_websites]# ls -la
total 2612
drwxrwxr-x 16 root eawdb 4096 May 24 08:23 .
drwxr-xr-x 4 root technet 4096 Sep 11 2012 ..
drwxrwxr-x 5 thomas smith 4096 May 29 10:04 eawdb
drwxr-xr-x 12 thomas thomas 4096 May 28 13:51 _files-web-working
drwxr-xr-x 5 thomas thomas 4096 Apr 29 16:28 nmwcc
drwxrwxr-x 2 root eawdb 4096 May 15 14:09 Smiths
[root@charger eawdb_websites]#
- - - - - - - - - - - - - - - -
[root@charger eawdb_websites]# ls -la
total 2612
drwxrwxr-x 16 root eawdb 4096 May 24 08:23 .
drwxr-xr-x 4 root technet 4096 Sep 11 2012 ..
-rwxr--r-- 1 thomas thomas 200 Apr 9 16:18 css-list.txt
drwxr-xr-x 2 thomas thomas 4096 Feb 25 15:47 services-logos
drwxrwxr-x 5 thomas smith 4096 May 29 10:04 eawdb
drwxr-xr-x 5 thomas thomas 4096 Apr 29 16:28 nmwcc
-rwxr--r-- 1 thomas thomas 2597 Apr 30 16:23 point-pixel-ems-percent.html
drwxrwxr-x 2 root eawdb 4096 May 15 14:09 Smiths
[root@charger eawdb_websites]#
- - - - - - - - - - - - - - - -
[root@charger eawdb]# ls -la
total 20
drwxrwxr-x 5 thomas smith 4096 May 29 10:04 .
drwxrwxr-x 16 root eawdb 4096 May 24 08:23 ..
drwxr-xr-x 3 thomas thomas 4096 Mar 13 11:13 cgi-bin
drwxr-xr-x 2 thomas thomas 4096 May 3 08:59 _notes
drwxr-xr-x 15 thomas thomas 4096 May 30 15:33 web
[root@charger eawdb]#
- - - - - - - - - - - - - - - -
[root@charger web]# ls -la
total 312
drwxr-xr-x 15 thomas thomas 4096 May 30 15:33 .
drwxrwxr-x 5 thomas smith 4096 May 29 10:04 ..
-rwxr--r-- 1 thomas thomas 40195 May 30 09:51 board.html
-rwxr--r-- 1 thomas thomas 12341 May 30 15:08 by-laws.html
drwxr-xr-x 3 thomas thomas 4096 May 14 15:06 css
drwxr-xr-x 4 thomas thomas 4096 May 30 12:28 docs
-rwxr--r-- 1 thomas thomas 15559 May 30 15:33 index.html
drwxr-xr-x 3 thomas thomas 4096 May 14 15:06 js
-rwxr--r-- 1 thomas thomas 11838 May 30 09:51 local-plan.html
-rwxr--r-- 1 thomas thomas 12643 May 30 12:34 minutes.html
[root@charger web]#
- - - - - - - - - - - - - - - -
[root@charger nmwcc]# ls -la
total 24
drwxr-xr-x 5 thomas thomas 4096 Apr 29 16:28 .
drwxrwxr-x 16 root eawdb 4096 May 24 08:23 ..
drwxr-xr-x 3 thomas thomas 4096 Apr 29 16:08 cgi-bin
drwxr-xr-x 2 thomas thomas 4096 Apr 24 09:37 _notes
-rwxr--r-- 1 thomas thomas 382 Apr 29 16:28 reCAPTCHA.txt
drwxr-xr-x 14 thomas thomas 4096 May 30 17:50 web
[root@charger nmwcc]#
- - - - - - - - - - - - - - - -
[root@charger web]# ls -la
total 768
drwxr-xr-x 14 thomas thomas 4096 May 30 17:50 .
drwxr-xr-x 5 thomas thomas 4096 Apr 29 16:28 ..
-rwxr--r-- 1 thomas thomas 16271 May 28 10:47 about.html
drwxr-xr-x 3 thomas thomas 4096 May 8 15:23 css
drwxr-xr-x 5 thomas thomas 4096 May 28 10:30 images
-rwxr--r-- 1 thomas thomas 16403 May 30 17:29 site-map.html
[root@charger web]#

rmugunthan 06-03-2013 07:41 AM

only file owner is having write access. If you don't have problem with file permissions then add the below two entries in your configuration.

directory mask = 0777
create mask = 0777

The above parameters used to create all the files and directories with full permission.

[eawdb_websites]
comment = EAWDB
path = /home/shares/eawdb_websites
public = no
writable = yes
printable = no
directory mask = 0777
create mask = 0777
write list = @eawdb


All times are GMT -5. The time now is 11:38 PM.