LinuxQuestions.org
Share your knowledge at the LQ Wiki.
Go Back   LinuxQuestions.org > Forums > Linux Forums > Linux - Newbie
User Name
Password
Linux - Newbie This Linux forum is for members that are new to Linux.
Just starting out and have a question? If it is not in the man pages or the how-to's this is the place!

Notices

Reply
 
Search this Thread
Old 01-07-2013, 06:56 AM   #1
mikhail91
LQ Newbie
 
Registered: Jan 2013
Posts: 1

Rep: Reputation: Disabled
Folder/File permission inheritance.


hello everyone, I'm quite new to Linux and I've been given the following assignment.

I have to recreate a windows like folder structure that looks like this

Documents and Settings
|
My Documents
My pictures

I have to set the permissions for each subfolder to give the user and the group read and write access. but I also want any new folders/files created within this structure to inherit the same permissions as their parent folder. even when I create one as a Sudo user.
I can get it to work when a normal user creates a file within this structure, but not when I do it with Sudo.

I'm pretty sure I've missed something really small and any help on this subject is greatly appreciated.

Thanks in advance,

Mikhail.
 
Old 01-07-2013, 07:07 AM   #2
pan64
Senior Member
 
Registered: Mar 2012
Location: Hungary
Distribution: debian i686 (solaris)
Posts: 4,929

Rep: Reputation: 1306Reputation: 1306Reputation: 1306Reputation: 1306Reputation: 1306Reputation: 1306Reputation: 1306Reputation: 1306Reputation: 1306Reputation: 1306
in unix/linux, all the permissions set by the current/actual environment and user, nothing is inherited. See the man page of umask.
 
  


Reply


Thread Tools Search this Thread
Search this Thread:

Advanced Search

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 Off
HTML code is Off


Similar Threads
Thread Thread Starter Forum Replies Last Post
[SOLVED] Permission inheritance via Samba adol83 Linux - Newbie 7 12-18-2012 03:01 AM
file and folder inheritance doesn't work!! ahmadirad Linux - Newbie 5 09-28-2011 07:50 AM
NFS: folder permission inheritance Swakoo Linux - General 5 06-25-2007 04:29 AM
How exactly does Linux file permission inheritance work HGeneAnthony Linux - Newbie 5 04-14-2006 10:20 AM
File permission inheritance HowTo ? Satriani Linux - Security 4 11-26-2004 05:13 AM


All times are GMT -5. The time now is 03:08 PM.

Main Menu
My LQ
Write for LQ
LinuxQuestions.org is looking for people interested in writing Editorials, Articles, Reviews, and more. If you'd like to contribute content, let us know.
Main Menu
Syndicate
RSS1  Latest Threads
RSS1  LQ News
Twitter: @linuxquestions
identi.ca: @linuxquestions
Facebook: linuxquestions Google+: linuxquestions
Open Source Consulting | Domain Registration