Go Back   HowtoForge Forums | HowtoForge - Linux Howtos and Tutorials > Linux Forums > Server Operation

Do you like HowtoForge? Please consider supporting us by becoming a subscriber.
Thread Tools Display Modes
Old 27th April 2012, 22:10
Tray2 Tray2 is offline
Junior Member
Join Date: Apr 2012
Posts: 3
Thanks: 0
Thanked 1 Time in 1 Post
Default Samba folder access problem [Solved]

Hey guys,

Ubuntu 12.04 is out and i want to update my server and in the process making my media and fileserver a bit more customized. Unfortunatly i ran in to some trouble with Samba and i hope you guys can help me out.

This is what i'm trying to acheive.

I have three users that i want to be able to access certain areas on my shares.

Lets say that the users are users are myself, mywife and mediaplayer.

I want each of this users to connect to their home on the server. There i have a symlink that points to my raid. This part works fine.

When you follow the link you'll see a list of folders like this

and so on. So onto the problem. I want myself to have full access to everything and mywife shall have full access to the MyWife folder and rx to Movies and Music. Lastly i want mediaplayer to have rx to Movies and Music.

Restricting the access is not a problem it's gettiong access for myself to the Mywife folder. I Put both of us into a group marrige and set mywife as owner to the folder and the group to marrige. Since i don't want anyone except mywife or a user belonging to marrige (me) to be able to rwx in this folder i put permission 770 on it. This works fine from the shell. My admin user can't access the folder since he doesn't belong to marriage and myself can access the folder.

So everything is peachy.... no it ain't when i try to access it from my windows machine it says permission denied. Permission 775 works but then mediaplayer can access it to and i don't want that.

It seems that samba isn't checking group permissions.

Is there anyway around this without creating symlinks to the folders i want on each user ?

The main reason i want to do it this way is that i can add folder and just set the permission and group on them to handle who gets to see and access what.

Hopefully some of you can help me solve this issue.

Cheers Tray2

Last edited by Tray2; 29th April 2012 at 09:36.
Reply With Quote
Sponsored Links
Old 28th April 2012, 09:44
Tray2 Tray2 is offline
Junior Member
Join Date: Apr 2012
Posts: 3
Thanks: 0
Thanked 1 Time in 1 Post


So i now managed to get access for myself to the mywife folder and preventing mywife to access myself. the problem now is that media still has access to mywife and it shouldn't.

The permissions is set add follows.
myself 700 (myself is owner and group)
mywife 770 (mywife is owner and marrige is group)
Movies 775 (myself is owner and marrige is group)

If i log in as mywife i don't se myself like it should and if i log in as myself i see everything. Yea But if i log in ad media i see and can access mywife which shouldn't be possible since media doesn't belong to marrige.

i have hide unreadable = yes set in the global section to prevent samba from showing folders that you don't have permission to read.

Any ideas how to get this to work ?

Cheers Tray2
Reply With Quote
The Following User Says Thank You to Tray2 For This Useful Post:
aangelatexaxda9431 (2nd February 2013)
Old 29th April 2012, 09:35
Tray2 Tray2 is offline
Junior Member
Join Date: Apr 2012
Posts: 3
Thanks: 0
Thanked 1 Time in 1 Post

Update 2.

I think i solved the issue.

This is what i did.

I put permission 700 on myself, 770 on mywife and 755 on movies.
Left the root as owner and group on the shared folder (/media/raid).
And instead of using mask 777 in samba i used 770 and it seems to be working like a charm. Next step is to see if myself can delete files created by mywife

Cheers Tray2
Reply With Quote


Thread Tools
Display Modes

Posting Rules
You may not post new threads
You may not post replies
You may not post attachments
You may not edit your posts

BB code is On
Smilies are On
[IMG] code is On
HTML code is Off

Forum Jump

Similar Threads
Thread Thread Starter Forum Replies Last Post
Major recovery Toucan Installation/Configuration 18 9th August 2011 12:45
Sending email issue lezelf Installation/Configuration 15 9th August 2011 12:20
Email problem 'Cannot set my user or group id.' (using ISPConfig 3 + OpenSuSE 11.2) urosm Installation/Configuration 5 19th June 2010 23:41
Can't access to my website - after install problem pallermo Installation/Configuration 18 4th June 2010 14:29
Installations Problem @ PHP thryb Installation/Configuration 1 7th November 2007 14:41

All times are GMT +2. The time now is 01:29.

Powered by vBulletin® Version 3.8.7
Copyright ©2000 - 2014, vBulletin Solutions, Inc.