LinuxQuestions.org
Support LQ: Use code LQ3 and save $3 on Domain Registration
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 06-08-2004, 03:32 AM   #1
Stevetgn
Member
 
Registered: Jun 2003
Distribution: SuSE10, Mepis,
Posts: 230

Rep: Reputation: 30
How do I Change directory permissions?


Sorry guys and gals I've asked this before, forgotten the answer and can't find it in the forum again!

I have a directory on a Windows FAT32 partition where I keep all my music files.
I want to use this directory in both windows and linux and have full r w permissions for the directory (and all its sub directories!) I think the old chmod is involved somewhere but I can't remember!?!?

Thanks in advance for your help

Steve

PS - I'm fed up with being a Linux newbie. Is there one definitive place I can learn all the chmod, grep, -r -a command, command command, etc, etc, etc!!!!
 
Old 06-08-2004, 03:37 AM   #2
overlord73
Member
 
Registered: Apr 2004
Location: ..where no life dwells..
Distribution: RH,FC/SuSE/Debian/HPUX/OSX
Posts: 511

Rep: Reputation: 30
to change dir-permissions (-R = recursive) use:

chmod -R permissions /dirname

example:
chmod -R 777 /dirname
or
chmod -R u+rw /dirname
 
Old 06-08-2004, 03:42 AM   #3
overlord73
Member
 
Registered: Apr 2004
Location: ..where no life dwells..
Distribution: RH,FC/SuSE/Debian/HPUX/OSX
Posts: 511

Rep: Reputation: 30
not to mention,

the mountpoint must be set correctly in /etc/fstab:

for example:
/dev/hdc /windowsshare vfat uid=500,gid=500, rw 0 0


--> read/write permissions for user (uid=500) on share !
 
Old 06-08-2004, 03:52 AM   #4
Stevetgn
Member
 
Registered: Jun 2003
Distribution: SuSE10, Mepis,
Posts: 230

Original Poster
Rep: Reputation: 30
Quote:
Originally posted by overlord73
not to mention,

the mountpoint must be set correctly in /etc/fstab:

for example:
/dev/hdc /windowsshare vfat uid=500,gid=500, rw 0 0


--> read/write permissions for user (uid=500) on share !
Quick reply, thanks my friend.

Do you see what I mean though? where or how do you learn about all the advice you've just given me???
 
Old 06-08-2004, 03:56 AM   #5
Stevetgn
Member
 
Registered: Jun 2003
Distribution: SuSE10, Mepis,
Posts: 230

Original Poster
Rep: Reputation: 30
Quote:
Originally posted by overlord73
to change dir-permissions (-R = recursive) use:

chmod -R permissions /dirname

example:
chmod -R 777 /dirname
or
chmod -R u+rw /dirname
Sorry for my ignorence: does the "-R" change all sub directoies then and should it be an upper or lower case R(r)?

 
Old 06-08-2004, 04:05 AM   #6
overlord73
Member
 
Registered: Apr 2004
Location: ..where no life dwells..
Distribution: RH,FC/SuSE/Debian/HPUX/OSX
Posts: 511

Rep: Reputation: 30
"-R" change all subs and it should be in uppercase!

unlike many other switches which are in lower case, the recursive-switch of CHOWN and CHMOD is in upper case.

learning and experiencing linux and especially the different distris is a very hard and nightly work! :-(
 
Old 06-08-2004, 04:27 AM   #7
Qucho
Member
 
Registered: Mar 2004
Location: Colorado, US
Distribution: Debian "Sarge"
Posts: 228

Rep: Reputation: 30
Quote:
Do you see what I mean though? where or how do you learn about all the advice you've just given me???
Here is one place :P
http://www.linuxquestions.org/questi...ticle&artid=20

VERY nice explanation/article.
 
Old 06-08-2004, 10:14 AM   #8
slackist
Member
 
Registered: Feb 2004
Location: Phuket, Thailand
Distribution: Slackware 14.1
Posts: 435

Rep: Reputation: Disabled
Re: How do I Change directory permissions?

Quote:
Originally posted by Stevetgn


PS - I'm fed up with being a Linux newbie. Is there one definitive place I can learn all the chmod, grep, -r -a command, command command, etc, etc, etc!!!!
I found this site very helpful for doing CLI stuff:

http://linux-newbie.sunsite.dk/


HTH,

mark
 
Old 06-09-2004, 12:09 AM   #9
Cerbere
Member
 
Registered: Dec 2002
Location: California
Distribution: Slackware & LFS
Posts: 799

Rep: Reputation: 33
You can't use chmod to set permissions for a FAT partition. As overlord indicated, the key to having full read/write access (for ordinary users) is in the mounting options. If you automatically mount the partition with a /etc/fstab entry, it should look like the following:
Code:
/dev/hda4    /w98          vfat     umask=0000,users     0   0
Of course, you'll need to use your own partition and mount point. The key elements here are the 'umask=0000, users' options.

To answer your second question, the single best source of information that I've found is the Rute User's Tutorial and Exposition.

Enjoy!
--- Cerbere

[edit] Here's another thread that explains this really well [/edit]

Last edited by Cerbere; 06-09-2004 at 12:18 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
How do I change directory permissions ? cwolf78 Linux - Software 3 05-05-2005 12:15 PM
FTP Change Directory Permissions rubbercash Linux - Networking 5 07-29-2004 04:54 PM
can't change directory permissions walterbyrd Debian 7 07-24-2004 01:20 PM
Does anyone know why mounting NFS shares causes the directory permissions to change? gkneller Linux - Networking 4 01-29-2004 08:21 AM
How do I change read/write permissions for a whole directory? Stevetgn Linux - Newbie 8 12-31-2003 07:41 AM


All times are GMT -5. The time now is 03:00 AM.

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