Operating System - Linux
1828977 Members
2177 Online
109986 Solutions
New Discussion

Re: trouble granting permissions, please help asap

 
Sharfuddin
Frequent Advisor

trouble granting permissions, please help asap

Actually i have trouble in granting rights/permissions over a resource(file/directory), on per user and or per group basis, as we normally and easily used to do in Microsoft(server/professional). Following is the condition/scenario:

1, user 'a' who belongs to a group 'a', creates a file, named 'a-file'.

2, 'a' wants to give 'read' permission, over 'a-file', to 'accounts' group, but there is a user in 'accounts', named 'super-user', only to whome 'a' wants to give 'read' and 'write' both.

3, 'a' wants to give 'read' permission, over 'a-file', to 'sales' group.

4, 'a' wants to give 'read' and 'write' permissions, over 'a-file', to 'managers' group.

Now please let me know what is the solution, of above mentioned condition. Please let me know the steps(command/actions), and procedures. I know abt 'chmod' and and the numbers and various combinations used for granting permissions(ro = 4, w = 2, e = 1, and rwe = 7).

Note: I m using Red Hat Linux, 7.2, and 8.0.

Thanks
3 REPLIES 3
Martin P.J. Zinser
Honored Contributor

Re: trouble granting permissions, please help asap

Hello,

what you want to do is at least extremely hard if not impossible with basic Linux file protections. You do need to look into ACLs for this. Documentation on this topic can be found e.g. at


http://www.suse.de/~agruen/acl/chapter/fs_acl-en.pdf

Greetings, Martin
Steven E. Protter
Exalted Contributor

Re: trouble granting permissions, please help asap

check the umask command for user a

It is possible to set things so that evey file he creates is readable by all groups.

If that doesn't work, you can do this.

After file creation:

chmod o+r filename

Then all groups can read it.

The only practical concern at that point is do all groups have access to the folder the file is sitting in.

Sorry about the delay, I left this message half posted for well over an hour.

SEP
Steven E Protter
Owner of ISN Corporation
http://isnamerica.com
http://hpuxconsulting.com
Sponsor: http://hpux.ws
Twitter: http://twitter.com/hpuxlinux
Founder http://newdatacloud.com
T G Manikandan
Honored Contributor

Re: trouble granting permissions, please help asap

You will have to check acl's to resolve this.