The default permissions for newly created (/copied) items allow read and write access only to the owner (whoever created it), read-only access to everyone else. The best way around this is to create an access control entry on the folder, and set it to be inherited to items created in (/copied into) it. 'Course, the Finder doesn't give you access to the inheritance controls, so you have to go to the command line:
chmod +a "group:staff allow list,add_file,search,delete,add_subdirectory,delete_child,readattr,writeattr,readextattr,writeextattr,readsecurity,writesecurity,chown,file_inherit,directory_inherit" ~/Public
Note that this gives read & write access to all accounts in the staff group (which basically means all user accounts); if you want a bit more control, create a group in System Preferences > Users & Groups, and add just yourself and your friend's account to it, then use "group:yourgroupname" in the above command. Also, the inheritance only applies to items as they're created, so it won't apply to files and folders already in your Public folder; if you want it to apply to existing items, add chmod's -R
option (chmod -R +a ...
)
regarding getting your SMB sharing connection from linux working...
Samba no more, mount.cifs needs extra options, "nounix,sec=ntlmssp"
Don't use the linux gui to connect, have bro open a terminal and try these commands
(and dig my ascii art!)
=^..^= `·.¸¸ ><((((º>.·´¯`·><((((º>
amitsbrother@linux:~$
amitsbrother@linux:~$ sudo apt-get install cifs-utils
...
amitsbrother@linux:~$ mkdir /mnt/mavericks_smb
amitsbrother@linux:~$ mount.cifs //172.17.8.212/smb_share /mnt/mavericks_smb/ -o user=amitsbrother,password=trustno1,nounix,sec=ntlmssp
amitsbrother@linux:~$
amitsbrother@linux:~$ mkdir /mnt/mavericks_smb_dup
amitsbrother@linux:~$ mount -t cifs //172.17.8.212/smb_share /mnt/mavericks_smb-dup -o username=amitsbrother,password=trustno1,nounix,sec=ntlmssp
Once this is working, you can create a script for your brother to automatically mount when it is executed from the gui. Basically, the script is just the mount point creation, and the cifs connection to the smb server... so 2 or 3 lines including the shebang.
Make sharing work now with no passwords
To make it super simple, I'd enable web sharing on the Mac, and put the files you want to share to the Linux box in a folder in ~/Sites/a_folder/
. Then give your brother the address that it tells is your personal web sharing address in the Sharing Preferences pane when you enabled Web Sharing. Tell your brother to open a browser and put in that address; it will give him a directory listing as long as there is no index.html file in there. He can download files with his browser. This is one way sharing, from the Mac to the linux box, and will work fine as long as there are no files over 4GB (unless apache fixed that issue and didn't tell me about it). I believe directory listing is enabled by default on the Mac apache2 server.
To share in the other direction, from linux to Mac, you could do the same from the Linux box:
sudo apt-get install apache2
You can enable directory listings on the Linux apache2 server with instructions here. Those instructions inadvertantly also cover how to get the apache2 server up and running. Then you need the ip address of the Linux box, and the relative location from the apache root to see the files in your Mac's browser.
This shouldn't take 5 minutes to set up 2 x 1-way sharing through browsers on both boxes, and relieves you from hacing to trouble-shoot the slightly more complex task of installing and configuring netatalk or running SMB sharing from the mac and getting the linux client to mount it, which isn't always a "it just works" situation, like running 2 apache2 servers is.
Best Answer
Emphasis Mine
This one paragraph sums up the issue you are having; you do not have this setup correctly at all. What this sounds like is that even though everyone has read/right priviliges, the file gets locked so that only one SMB client can access it at a time. When two clients access it - even with the same credentials, which client has the correct changes? SMB solves this for you - the one that got there first.
What you should have is a unique user account for each person that needs to access the file share/server. If you want to maintain a single login for your users across all servers, look at implementing a directory server of some sort. I prefer Active Directory as I work in mixed environments; second in line is LDAP.