LinuxQuestions.org

LinuxQuestions.org (/questions/)
-   Linux - Server (https://www.linuxquestions.org/questions/linux-server-73/)
-   -   Samba sharing, linux permissions and best practice (https://www.linuxquestions.org/questions/linux-server-73/samba-sharing-linux-permissions-and-best-practice-651762/)

batfastad 06-26-2008 03:41 AM

Samba sharing, linux permissions and best practice
 
Hi everyone

I've got a RAID 6 array successfully formatted and mounted in Ubuntu Server 8.04. I'm now looking to share this device out to the network as a series of Samba shares. I'm not worrying about printers yet, I'll wait until I've got basic shares working until I get my printers on there.

I'm using a rather good 3ware hardware RAID controller which is automatically picked up by Ubuntu.
There's a few things I need some advice on though:



The RAID device is mounted at /media/raid so within that device I've created a few folders which will be the root of some shares.

I want all of these shares to be complete anonymous access - anyone on our local network can read/write to the files on these shares (once I've got our mail transferred to Zimbra I'll set up LDAP auth)



1) Do the Linux permissions of the root share folders within /mount/raid matter to Windows/Mac clients?

Or is that all down to the Samba/Netatalk conf files?



2) Should I set the permissions of /mount/raid to that of my main user account on this server box?



3) Do the Linux permissions of any files/folders created on this device through Samba, get inherited from the partitions of the /mount/raid mountpoint or anywhere else?

Or will I have to run a shell script every so often to reset all the file permissions on the NAS to ensure my server admin account retains ownership?

Does my server admin user account need to retain ownership of the files/folders?


4) Here's my smb.conf so far (modified the default but have stripped most of the cruft/comments out)


Code:

[global]
workgroup = domain.com
netbios name = files
server string = %h server (Samba, Ubuntu Server 8.04)
encrypt passwords = yes

dns proxy = no
;name resolve order = lmhosts host wins bcast
interfaces = eth0
bind interfaces only = true

log file = /var/log/samba/log.%m
max log size = 10000
syslog = 0
panic action = /usr/share/samba/panic-action %d
security = share

;map to guest = bad user

# Most people will find that this option gives better performance.
# See smb.conf(5) and /usr/share/doc/samba-doc/htmldocs/Samba3-HOWTO/speed.html
# for details
# You may want to add the following on a Linux system:
#        SO_RCVBUF=8192 SO_SNDBUF=8192
  socket options = TCP_NODELAY

[testshare1]
path = /media/raid/shared
comment = comment
browseable = yes
public = yes
writeable = yes
read only = no
guest only = yes
guest ok = yes
create mask = 0777
directory mask = 0777


The last thing I want with these anonymous/guest shares is for people to be getting permission errors on certain files/folders



Any comments/suggestions/answers are most appreciated ;)



Thanks, B


All times are GMT -5. The time now is 09:33 PM.