[Okta Webinar] Learn how to a build a cloud-first strategyRegister Now

x
?
Solved

Linux

Posted on 2014-08-14
17
Medium Priority
?
413 Views
Last Modified: 2014-08-14
How do I give read write access for a folder to a second group?
0
Comment
Question by:Jack_son_
  • 8
  • 8
17 Comments
 
LVL 12

Expert Comment

by:Kent W
ID: 40261491
Add the second group to your first, or create a new group that contains both.
0
 

Author Comment

by:Jack_son_
ID: 40261541
okay, so there is no way I guess to give a second group just those 2 permissions?
0
 

Author Comment

by:Jack_son_
ID: 40261543
I meant to add, the first group has more permissions than this second one will have
0
A Cyber Security RX to Protect Your Organization

Join us on December 13th for a webinar to learn how medical providers can defend against malware with a cyber security "Rx" that supports a healthy technology adoption plan for every healthcare organization.

 
LVL 25

Expert Comment

by:Zephyr ICT
ID: 40261550
There is, using setfacl

Set the first group default like normal then use setfacl to give the second group the necessary rights.
Take a look at the examples, let me know if something is not clear.
0
 

Author Comment

by:Jack_son_
ID: 40261563
okay thanks, can you post the format?
0
 

Author Comment

by:Jack_son_
ID: 40261568
sorry I see the example, for group 2 would it be

setfacl -r groupname foldername
0
 
LVL 25

Expert Comment

by:Zephyr ICT
ID: 40261575
It would be something like this:

setfacl -m g:groupname:rwx foldername
0
 
LVL 25

Expert Comment

by:Zephyr ICT
ID: 40261578
You can add -R to apply it recursive ...

Check your changes with "getfacl foldername"
0
 

Author Comment

by:Jack_son_
ID: 40261580
thanks, i am getting the error unrecognized char found in the mode field
0
 
LVL 25

Expert Comment

by:Zephyr ICT
ID: 40261585
Can you post your command?
0
 

Author Comment

by:Jack_son_
ID: 40261600
here is the command, typed it incorrect before:

setfacl -m g:groupname:r foldername
0
 
LVL 25

Expert Comment

by:Zephyr ICT
ID: 40261601
is that a folder or a file?
So did your setfacl command work or is that where you go the error?

Post your setfacl if that is where the error is happening.
0
 
LVL 25

Expert Comment

by:Zephyr ICT
ID: 40261604
ah ok .. Try

setfacl -m g:groupname:r-- foldername
0
 

Author Comment

by:Jack_son_
ID: 40261605
setfacl -m g:groupname:r foldername

here is where I got that error
0
 
LVL 25

Expert Comment

by:Zephyr ICT
ID: 40261611
If you want this setting to be default put a d in front of it like this

setfacl -m d:g:groupname:r foldername
0
 

Author Comment

by:Jack_son_
ID: 40261644
no dont necessarily need it as default; i think the issue is with the :r, should I use a number?
0
 
LVL 25

Accepted Solution

by:
Zephyr ICT earned 2000 total points
ID: 40261650
Did you try with the dashes like I showed?

setfacl -m g:groupname:r-- foldername

or with numbers should work I think

setfacl -m g:groupname:600 foldername
0

Featured Post

Industry Leaders: We Want Your Opinion!

We value your feedback.

Take our survey and automatically be enter to win anyone of the following:
Yeti Cooler, Amazon eGift Card, and Movie eGift Card!

Question has a verified solution.

If you are experiencing a similar issue, please ask a related question

The purpose of this article is to fix the unknown display problem in Linux Mint operating system. After installing the OS if you see Display monitor is not recognized then we can install "MESA" utilities to fix this problem or we can install additio…
Join Greg Farro and Ethan Banks from Packet Pushers (http://packetpushers.net/podcast/podcasts/pq-show-93-smart-network-monitoring-paessler-sponsored/) and Greg Ross from Paessler (https://www.paessler.com/prtg) for a discussion about smart network …
Learn how to navigate the file tree with the shell. Use pwd to print the current working directory: Use ls to list a directory's contents: Use cd to change to a new directory: Use wildcards instead of typing out long directory names: Use ../ to move…
Get a first impression of how PRTG looks and learn how it works.   This video is a short introduction to PRTG, as an initial overview or as a quick start for new PRTG users.
Suggested Courses
Course of the Month19 days, 9 hours left to enroll

873 members asked questions and received personalized solutions in the past 7 days.

Join the community of 500,000 technology professionals and ask your questions.

Join & Ask a Question