Solved

Linux - Set folder & File permission inheritance on sub-folders and files

Posted on 2014-09-19
11
610 Views
Last Modified: 2014-09-30
We are a Linux file server.
I have created a new folder and get a group ownership to that folder. I have given the specific user access to that group.
When a use creates a file or folder it make it read only for all other users.
How can I set it so that any file and sub folder will still retain the same permissions as the parent folder?
I will then also need to run a command that will change all permissions on the all curenly folders already created.
0
Comment
Question by:bax2000
[X]
Welcome to Experts Exchange

Add your voice to the tech community where 5M+ people just like you are talking about what matters.

  • Help others & share knowledge
  • Earn cash & points
  • Learn & ask questions
  • 4
  • 4
  • 3
11 Comments
 
LVL 15

Expert Comment

by:Haris Djulic
ID: 40332306
0
 
LVL 6

Assisted Solution

by:xeroxzerox
xeroxzerox earned 250 total points
ID: 40332358
Hi,

you should use chmod command for set permission on sub-folders and files....for example

chmod -R 770 foldername
(-R is use for recursive )

and
(for set default permission)
Now, use the following command to set the default ACL:
#setfacl -dm u::rwx,g::rwx,o::r /directoryname
0
 

Author Comment

by:bax2000
ID: 40332372
Hi xeroxzerox

What is the full path for the setfacl command as I get the following when trying to run it.
-bash: setfacl: command not found
0
Is Your Team Achieving Their Full Potential?

74% of employees feel they are not achieving their full potential. With Linux Academy, not only will you strengthen your team's core competencies but also their knowledge of of the newest IT topics.

With new material every week, we'll make sure that you stay ahead of the game.

 
LVL 6

Expert Comment

by:xeroxzerox
ID: 40332378
Full path of setfacl
/usr/bin/setfacl

If you want any full path of command then just run below command.
#whereis setfacl
if it installed then it gives you full path....
0
 

Author Comment

by:bax2000
ID: 40332387
Seems as though setfacl is not installed on the server we have.
Any alternative?
0
 
LVL 15

Expert Comment

by:Haris Djulic
ID: 40332396
which server it is? it will help with the solutions
0
 
LVL 6

Expert Comment

by:xeroxzerox
ID: 40332397
Which Linux Distribution You Are Using?
0
 

Author Comment

by:bax2000
ID: 40332411
Running   openSUSE 12.2
0
 
LVL 15

Expert Comment

by:Haris Djulic
ID: 40332523
0
 

Author Comment

by:bax2000
ID: 40332556
Where can I download it from?
0
 
LVL 15

Accepted Solution

by:
Haris Djulic earned 250 total points
ID: 40332619
0

Featured Post

Free Tool: Port Scanner

Check which ports are open to the outside world. Helps make sure that your firewall rules are working as intended.

One of a set of tools we are providing to everyone as a way of saying thank you for being a part of the community.

Question has a verified solution.

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

The purpose of this article is to demonstrate how we can use conditional statements using Python.
In the first part of this tutorial we will cover the prerequisites for installing SQL Server vNext on Linux.
Learn several ways to interact with files and get file information from the bash shell. ls lists the contents of a directory: Using the -a flag displays hidden files: Using the -l flag formats the output in a long list: The file command gives us mor…
How to Install VMware Tools in Red Hat Enterprise Linux 6.4 (RHEL 6.4) Step-by-Step Tutorial

726 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