LinuxQuestions.org
Visit Jeremy's Blog.
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 09-11-2008, 12:42 AM   #1
sumanthls
LQ Newbie
 
Registered: Sep 2008
Posts: 1

Rep: Reputation: 0
File/Folder Sharing in unix for different users


Hi,

I am new to the forum and even new to the Linux.

I have a question regarding file/folder sharing with different permissions for different users.

Consider i have a folder, i want to share it to 3 people with different permissions.

to one user i have given the permission as read only

to other two users i have given the permission as read write.

How can it be implemented at the linux file system side.

One more question how can i share a file/folder to other users in linux by using commands (i mean to say at the file system side?)

Please put some light on the same...
 
Old 09-11-2008, 12:57 AM   #2
chrism01
Guru
 
Registered: Aug 2004
Location: Sydney
Distribution: Centos 6.6, Centos 5.10
Posts: 16,324

Rep: Reputation: 2041Reputation: 2041Reputation: 2041Reputation: 2041Reputation: 2041Reputation: 2041Reputation: 2041Reputation: 2041Reputation: 2041Reputation: 2041Reputation: 2041
Well, if you use the cmd

ls -l

you'll see something like

-rw-rw-r-- 1 chris chris 655 2008-09-11 12:29 t.t

the permissions are

- type, defaults to file, d=dir etc

rw- read/write,noexe for user (owner)
rw- read/write,noexe for group
r-- read,nowrite,noexe for others (world)

For you situation you could use those, adding the r/w user into the relevant group and ensure the read only user not in that group.

The relevant cmd is
chmod

which you can read about in the man pages

man chmod

but basically, its

eg

chmod ugo=rw,rw,r filename

would set the above perms

To add a perm:
add exe to user's perms
chmod u+x filename

remove exe from user's perms

chmod u-x filename


Here's a good Linux tutorial: http://rute.2038bug.com/index.html.gz
See Chap 14 for Permissions

Last edited by chrism01; 09-11-2008 at 12:58 AM.
 
  


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
create a home network file sharing folder driftboy Linux - Newbie 1 11-19-2007 11:34 AM
Folder/File sharing and read/write access? JET-33 Linux - Server 2 04-05-2007 12:13 AM
Can someone help me get started uisng Unix file sharing? enigma_0Z Linux - Networking 3 05-31-2005 12:05 PM
howto folder/file sharing with specific groups kmhui Linux - Newbie 5 09-18-2004 08:05 PM
Win2k - Mandrake9.1 -file(folder) sharing? al3s Linux - Networking 3 04-19-2004 03:59 PM


All times are GMT -5. The time now is 06:48 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
identi.ca: @linuxquestions
Facebook: linuxquestions Google+: linuxquestions
Open Source Consulting | Domain Registration