LinuxQuestions.org
Help answer threads with 0 replies.
Go Back   LinuxQuestions.org > Forums > Linux Forums > Linux - Security
User Name
Password
Linux - Security This forum is for all security related questions.
Questions, tips, system compromises, firewalls, etc. are all included here.

Notices


Reply
  Search this Thread
Old 06-29-2006, 03:11 PM   #1
Hardip
LQ Newbie
 
Registered: Feb 2006
Posts: 6

Rep: Reputation: 0
Inheriting file permissions


I have just moved our documents folder to a linux box from windows. This folder contains numerous other folders and files for our association. All these folders, subfolders and files are to be accesed by our accounts group. How can I set these permissions. Do I have to set them on individual files or is there a command I can use ??
By the way, I am a newbie on this issue and a recent linux convert
 
Old 06-29-2006, 03:21 PM   #2
pljvaldez
LQ Guru
 
Registered: Dec 2005
Location: Somewhere on the String
Distribution: Debian Wheezy (x86)
Posts: 6,094

Rep: Reputation: 281Reputation: 281Reputation: 281
man chown and man chmod will both help. I think to make them all owned by the accounts group you would do chown -R :accounts /path/to/directory as root. This would change ownership of all files and directories to the accounts group. Then you'll want to set the permissions so that anyone in group account has read write access. So as root, you would do chmod -R g+rw /path/to/directory.
 
Old 06-29-2006, 03:27 PM   #3
nadroj
Senior Member
 
Registered: Jan 2005
Location: Canada
Distribution: ubuntu
Posts: 2,539

Rep: Reputation: 60
use the 'chgrp' command to change file group ownership, with the -R option to change ownership to all subdirectories and their contents. ie:
Code:
chgrp -R accounts /.../Documents/
also use the 'chmod' command to change file access modes. use the '-R' option as well. to give all access to the group and remove access to all other users, a command like this should work:
Code:
chmod -R a-rwx g+rwx
if thats what you want.. otherwise let us know

Last edited by nadroj; 06-29-2006 at 03:30 PM.
 
Old 07-02-2006, 11:48 PM   #4
Hardip
LQ Newbie
 
Registered: Feb 2006
Posts: 6

Original Poster
Rep: Reputation: 0
Inheriting file & folder permissions.

Thanks a pile. The permissions have been set as I need them, however whenever I open any excel or word file from my Documents folder on the Linux box, I always opens as a 'read only' file, altought I have set the permissions of the accounts group as read & write. Why is this ??. Is there a setup problem with my samba service ??
 
Old 07-02-2006, 11:56 PM   #5
nadroj
Senior Member
 
Registered: Jan 2005
Location: Canada
Distribution: ubuntu
Posts: 2,539

Rep: Reputation: 60
i didnt know samba was involved.. is it on a partition that is mounted read only? or on an ntfs partition? in which case you wouldnt want to write to it in linux
 
  


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
file permissions OK, but command permissions? stabu Linux - General 2 10-05-2005 12:00 PM
inheriting permissions steve007 Linux - Security 3 07-05-2005 11:09 PM
locking a usage policy file/ftp file permissions gbow Linux - Newbie 0 02-16-2004 05:35 AM
can't use protected inner class when inheriting the outer Dominik Programming 6 02-02-2004 01:12 AM
Inheriting a network admin’s job wedgeworth Linux - Software 1 10-10-2003 04:08 PM

LinuxQuestions.org > Forums > Linux Forums > Linux - Security

All times are GMT -5. The time now is 06:40 PM.

Main Menu
Advertisement
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
Open Source Consulting | Domain Registration