Yesterday a customer called because he needed to be able to write into a certain share on his Samba server. I ssh'd right in, made the change to the config file, restarted Samba and shot him off an "All set!" email.
Such confidence had I that immediately after hitting send, I left my house to do some errands and when I realized I had forgotten my phone, I didn't even bother to go back for it: everything is under control, all pigs are fed and ready to fly.
Yeah. When I got home, I found both phone and email messages from my customer. Such a nice guy he is - he was APOLOGIZING to me because it didn't work. "Maybe I'm doing something wrong?", he asked.
I ssh'ed in again and saw my "mistake". I had written "writeable" rather than "writable" in the config file. I quickly fixed that, restarted Samba, snapped off another email explaining my error and took a break for lunch.
Unfortunately the pigs seemed to still be having a little trouble with the flying stuff. I had barely bitten into my sandwich before he called again. Permission denied. Can't do it. Was he doing something wrong?, he begged to know? Of course not, I assured him. The damn pigs were just being stubborn.
I double checked. Yes, he had write permission in the directory. What the heck? Here's part of the config file for your amusement:
[homes]
comment = Home Directories
read only = No
browseable = No
[printers]
comment = All Printers
path = /var/spool/samba
printable = Yes
browseable = No
[Syn75]
comment = syn75
path = /usr/syn75
browseable = yes
read only= Yes
[CPONLINE]
comment = cponline
path = /usr/syn75/00/CPONLINE
browseable = yes
writable = Yes
Those pigs have wings, dammit! So exactly what happens, I asked?
"I choose Save As. I navigate down to CPONLINE..."
Ooops. Magic word. He said "Down", didn't he? The pigs all perked up and started tentatively fluttering their wings. I asked the $64,000 question: "Are you going through the Syn75 share or the CPONLINE share?"
NO, he was not using CPONLINE. He was navigating down through the Syn75 share. THAT share has no write permission - it doesn't matter that CPONLINE is under it, that only is writable if you come to it through the CPONLINE share! I had him map a network drive to CPONLINE and the pigs lifted off into the sky and everybody was happy.
Because he's such a nice guy ("Maybe I'm doing something wrong?) and because I should have paid more attention when he asked that, I'm not even sending him a bill for any of it.
Pigs: to your stations! Fly, you pink porkers, fly!
Have you tried Searching this site?
Unix/Linux/Mac OS X support by phone, email or on-site: Support Rates
This is a Unix/Linux resource website. It contains technical articles about Unix, Linux and general computing related subjects, opinion, news, help files, how-to's, tutorials and more. We appreciate comments and article submissions.
Many of the products and books I review are things I purchased for my own use. Some were given to me specifically for the purpose of reviewing them. I resell or can earn commissions from the sale of some of these items. Links within these pages may be affiliate links that pay me for referring you to them. That's mostly insignificant amounts of money; whenever it is not I have made my relationship plain. I also may own stock in companies mentioned here. If you have any question, please do feel free to contact me.
Specific links that take you to pages that allow you to purchase the item I reviewed are very likely to pay me a commission. Many of the books I review were given to me by the publishers specifically for the purpose of writing a review. These gifts and referral fees do not affect my opinions; I often give bad reviews anyway.
We use Google third-party advertising companies to serve ads when you visit our website. These companies may use information (not including your name, address, email address, or telephone number) about your visits to this and other websites in order to provide advertisements about goods and services of interest to you. If you would like more information about this practice and to know your choices about not having this information used by these companies, click here.
Click here to add your comments
Thu Nov 5 03:54:22 2009: Subject: Samba with MacOSX client Ed
LOL! That's a nice client, though.
I was, sometime in the recent past, bitten by problems with a MacOSX client connecting to Samba shares and messing up permissions. The multitude of Windows users could get along fine with each other, but permissions were being changed for files/folders created by the Mac, in total disregard of settings in smb.conf.
After a lot of fruitless Googling, a colleague found the answer:
http://www.mail-archive.com/samba@lists.samba.org/msg98288.html
Stuck that in, worked fine. Didn't suspect Samba on Linux would give a "frat bro" preferential treatment :-P but now I know...
Cheers
Ed.
Thu Nov 5 08:42:49 2009: Subject: Interesting... NickBarron
It is nice when the penny drops like that....
'Down you say huh?' :)
Previous poster the link you have put up doesn't seem to work incorrect permissions. Though maybe just me as I am using mobile broadband.
Thu Nov 5 11:06:29 2009: Subject: Michiel
It's not your mobile internet - the page gives an error for me too:
Forbidden
You don't have permission to access /samba@lists.samba.org/msg98288.html on this server.
Thu Nov 5 13:12:12 2009: Subject: TonyLawrence
That problem starts at DocRoot.
The original message surely came from lists.samba.org (which has a bad cert), but I don't find any easy way to find a specific message
Thu Nov 5 13:24:10 2009: Subject: TonyLawrence
I was able to get it from Google cache. The issue was
We have an issue using Mac OS 10.5 with our Samba shares connected via cifs://server/Sharename. From what I can tell, when the Mac writes a file the permissions are correct (0660). Then it seems to change the permission to 0644, defeating the whole point of shared files.
The share in smb.conf had
and the posted solution
Setting "unix extension = no" fixed the permissions problem.
Thu Nov 5 16:06:43 2009: Subject: Writable or Writeable BigDumbDinosaur
http://bcstechnology.net
writable and writeable are synonyms in Samba.
BTW, whomever made the CPONLINE share a subshare of syn75 should be forced to slop the hogs for a week for making such a newbie mistake. Oink! Oink!
Thu Nov 5 19:03:03 2009: Subject: Michiel
I didn't even know that you could nest shares.
Thu Nov 5 21:11:30 2009: Subject: URL works for me - weird Ed
Apologies to those of you complaining that the URL is broken... I just tried it again, and it works for me... strange. I wonder what browsers you're using? I'm using Firefox 3.5.3.
Sorry you had to fetch it from Google cache, Tony. Hope the info was new, though.
Cheers,
Ed.
Don't miss responses! Subscribe to Comments by RSS or by Email
Click here to add your comments
If you want a picture to show with your comment, go get a Gravatar