File permission problem (Fedora 8/Samba)

RE: Fedora 8, Samba-3.0.26a-6

I have recently installed the latest Fedora Core 8 operating system but every time I attempt to lock files in the Shares I have created I am unable to write to any of the documents inside the directories. (Access denied. Contact your administrator)

Example command:

chmod -R ug+rwx,o-rwx,g+s,o+t 'TEST'

It seems to be an issue with: o+t

The following command works perfect in previous versions of Fedora/Samba??
LVL 1
the_omnificAsked:
Who is Participating?
I wear a lot of hats...

"The solutions and answers provided on Experts Exchange have been extremely helpful to me over the last few years. I wear a lot of hats - Developer, Database Administrator, Help Desk, etc., so I know a lot of things but not a lot about one thing. Experts Exchange gives me answers from people who do know a lot about one thing, in a easy to use platform." -Todd S.

http:// thevpn.guruCommented:
As what user are you trying to access the samba shares ?
0
the_omnificAuthor Commented:
The Linux machine is part of the domain, so basically every user on the network.

It works perfectly when I don't add 'o+t' part of the command. Any ideas?
0
http:// thevpn.guruCommented:
Well as you propably know +t sets the sticky bit and prevents removing or deleting. But I cant see why it would disallow write access.
0
The Ultimate Tool Kit for Technolgy Solution Provi

Broken down into practical pointers and step-by-step instructions, the IT Service Excellence Tool Kit delivers expert advice for technology solution providers. Get your free copy for valuable how-to assets including sample agreements, checklists, flowcharts, and more!

the_omnificAuthor Commented:
I know neither can I. I have always been able to set that restriction until I installed Fedora 8
0
the_omnificAuthor Commented:
-R option changes permissions for entire directory trees including documents. Is there any way of changing the permissions of directories only and excludes documents etc
0
the_omnificAuthor Commented:
..using the sticky bit?
0
Pétur Ingi EgilssonSoftware Engineer -- ConsultantCommented:
the_omnific
-R option changes permissions for entire directory trees including documents. Is there any way of changing the permissions of directories only and excludes documents etc.

solution:

`find /sambashare/ -type d -exec chmod 777 {} \;`

find /sambashare/ <- tells that find should start searching from the directory sambashare and go recursivly thro all files and directories
-type d <- tells that you want 'find' to pay attention to every object of the type "directory"
-exec <- your about to ask find to execute a command in case it finds a match ( in our situation .. if it finds a directory )
chmod 777 {} <- sets the mode 777 onto the object found ( in our case.. the directory found )
\;  <- end

Try `find /sambashare/ -type d -exec echo {} \;` <- it will "echo" the name of every directory unser /sambashare/

hope this helps..

0
the_omnificAuthor Commented:
Your command doesn't seem to work:

`find /sambashare/ -type d -exec chmod 777 {} \;`

find: missing argument to `-exec'
0
Pétur Ingi EgilssonSoftware Engineer -- ConsultantCommented:
I double checked it and it works on my system

petur@oxygen:~/tmp> mkdir foo
petur@oxygen:~/tmp> mkdir bar
petur@oxygen:~/tmp> ls -lh
total 16K
drwxr-xr-x 2 petur users 4.0K 2008-02-02 14:15 bar
drwxr-xr-x 2 petur users 4.0K 2008-02-02 14:15 foo
petur@oxygen:~/tmp> `find ~/tmp/ -type d -exec chmod 777 {} \;`
petur@oxygen:~/tmp> ls -lh
total 16K
drwxrwxrwx 2 petur users 4.0K 2008-02-02 14:15 bar
drwxrwxrwx 2 petur users 4.0K 2008-02-02 14:15 foo
petur@oxygen:~/tmp>
0
the_omnificAuthor Commented:
Sorry my mistake.

I'm still not able to write to documents when the sticky bit is enabled. Any ideas?
0
Pétur Ingi EgilssonSoftware Engineer -- ConsultantCommented:
Are you sure the sticky bit is enabled?
please show the output of `ls -lah`
0
the_omnificAuthor Commented:

[root@FILESERVER TEST]# ls -lah
total 24K
drwxr-s--T  5 administrator domain 4.0K 2008-02-01 15:03 .
drwxrwx--- 18 administrator domain 4.0K 2008-02-01 15:03 ..
drwxrws--T  2 administrator domain 4.0K 2008-02-02 15:09 1
drwxrws--T  2 administrator domain 4.0K 2008-02-02 14:42 2
drwxrws--T  2 administrator domain 4.0K 2008-02-01 15:04 3

As soon as I take the sticky bit off I can write to the documents in the directories perfectly fine.
#!/bin/bash
cd '/archive'
chown -R administrator:domain 'TEST'
chmod -R ug+rwx,o-rwx,g+s,o+t 'TEST'
chmod ug+rwx,g-w,o-rwx 'TEST'
`find TEST -type d -exec chmod o+t {} \;`

Open in new window

0

Experts Exchange Solution brought to you by

Your issues matter to us.

Facing a tech roadblock? Get the help and guidance you need from experienced professionals who care. Ask your question anytime, anywhere, with no hassle.

Start your 7-day free trial
It's more than this solution.Get answers and train to solve all your tech problems - anytime, anywhere.Try it for free Edge Out The Competitionfor your dream job with proven skills and certifications.Get started today Stand Outas the employee with proven skills.Start learning today for free Move Your Career Forwardwith certification training in the latest technologies.Start your trial today
Linux

From novice to tech pro — start learning today.