permissions
hi, im new in Linux
i have 5 groups, i want to set 3 of them to have full permissions to a folder and set 2 others with read only to same folder, please help me to solve this problem. in other words i want to set this 5 groups diffrent permissions to a folder. tanx |
Hello Ardaneh,
I am also a newby. Maybe you should mention the distribution that you are using. I have recently started with Arch Linux. For Arch Linux there is an excellent Beginners' Guidehttps://wiki.archlinux.org/index.php/Beginners'_Guide. Maybe also helpful for other distro's. Good luck! |
Hello Ardaneh,
I am also a newby. Maybe you should mention the distribution that you are using. I have recently started with Arch Linux. For Arch Linux there is an excellent Beginners' Guidehttps://wiki.archlinux.org/index.php/Beginners'_Guide. Maybe also helpful for other distro's. Good luck! |
Hi ardaneh,
you could create a new group for all users that have full permissions on this folder. (adding a group to a group is not possible) Code:
groupadd admins Code:
chgrp admins /home/xyz/folder1 Code:
chmod g+rwx /home/xyz/folder1 Code:
chmod o-wx+r /home/xyz/folder1 Code:
setfacl -m group:admins:rwx,group:dbadmins:r /home/xyz/folder1 Linux permissions easy hope this helps |
Tanx
tanx for reply, but i dont get my answer, maybe i said it wrong,let me say it in another way:
i have 3 groups, A, B and C, that i want to set full permissions for group A to a folder and i want to set read only permission for group B to same folder and set write permission for group C to same folder, how i can do it, set different permissions for different groups to one folder. |
With 3 groups it would look like this:
Code:
setfacl -m group:admins1:rwx,group:admins2:r,group:admins3:w /home/xyz/folder1 |
if you want to check the acl , use command getfacl /folder , it will shows all the access control list permission details of the particular folder.
|
If these users are not local users (with UNIX accounts on the machine), and you want to do this for say, a network sharepoint, you can also achieve the same granularity level w/smb.conf (running SAMBA).
For example, your users are all wyndoze users, and have wyndoze boxes they are accessing these folders from their workstations (a very common use for UNIX servers, as is NFS). So you install SAMBA, configure it for these groups w/access levels appropriate to their jobs, and all is good. One scenario I typically use is to create a domain, use kixtart for the logon scripts and to map out their home (H:\) and public (P:\) sharepoints and no one even has to know that UNIX isn't a reference to someone living in times of Tiberius. A good reference for setting up a SAMBA domain, ironically, is located HERE And there's a plethora of wealth on Login scripts, including many examples which you can freely download HERE Otherwise, ACLs are the way to go in your case, as eloquently demonstrated to you above in an earlier post :) Hope that helps! |
tanx everyone
i solve my problem with your helps, thank you. good luck every one |
I dont even know if im posting right..I have debian linux and I cant edit the clamav.conf /etc/clamav
I tried several editors like leafpad and gedit but the trash and delete buttons are greyed out and i edit the clam file but when i try to save ..no permmissions am not allowed to edit readonly file , I did the ls -l deal and the clam is listed as my property rw -r -r how come? |
albertgonzo, please execute the following two commands. And if it is still not obvious why you can't modify the file post the output.
Code:
id |
Quote:
Code:
# apt-get clamav On Slackware, you would start HERE Hope that helps :) |
i tried these things ..first ls -lh /etc/clamav/clamav.conf = no such file or directory
then tried apt-get install clamav -message "E:could not open lock file /var/lib/dpkg/lock - open (13 permission denied)" "E: unable to lock administration directory (/var/lib/dpkg/) are you root? |
Quote:
|
I chmod 777 /etc/sudoers and operation not permitted..i dont know very much linux...but i do know this is my computer and i aint gonna let no machine tell me how to run my machine....LOL
|
All times are GMT -5. The time now is 12:14 PM. |