LinuxQuestions.org
Share your knowledge at the LQ Wiki.
Home Forums Tutorials Articles Register
Go Back   LinuxQuestions.org > Forums > Linux Forums > Linux - Distributions > Slackware
User Name
Password
Slackware This Forum is for the discussion of Slackware Linux.

Notices


Reply
  Search this Thread
Old 12-07-2003, 06:50 AM   #1
garlam
LQ Newbie
 
Registered: Aug 2003
Location: Pavia, Italy
Distribution: Slackware 9.0
Posts: 20

Rep: Reputation: 0
directoty permissions


Hello,

I have a Windows partition (FAT32) that I mount in the winG directory :

Quote:
(view of /etc/fstab) :
.....
/dev/hdb2 /mnt/winH ntfs iocharset=iso8859-1,ro,umask=0,defaults 0 0
/dev/hdb3 /mnt/winG vfat defaults 0 0
.....
The problem is :

when this partition is unmounted the winG drectory have all permissions :

drwxr-xr-x 2 root root 4096 Mar 16 2002 cdrom
drwxr-xr-x 2 root root 4096 Jul 31 21:44 cdrom2
drwxr-xr-x 2 root root 4096 Mar 16 2002 floppy
dr-xr-xr-x 1 root root 12288 Dec 2 16:16 winC
dr-xr-xr-x 1 root root 4096 Dec 6 20:21 winF
drwxr-xr-x 2 root root 4096 Dec 7 13:33 winG
dr-xr-xr-x 1 root root 4096 Dec 2 16:15 winH

so, as a normal user ( not root ) I'm able to enter on it.

when the partition is mounted the permissions change:

drwxr-xr-x 2 root root 4096 Mar 16 2002 cdrom
drwxr-xr-x 2 root root 4096 Jul 31 21:44 cdrom2
drwxr-xr-x 2 root root 4096 Mar 16 2002 floppy
dr-xr-xr-x 1 root root 12288 Dec 2 16:16 winC
dr-xr-xr-x 1 root root 4096 Dec 6 20:21 winF
drwxr--r-- 5 root root 16384 Jan 1 1970 winG
dr-xr-xr-x 1 root root 4096 Dec 2 16:15 winH

in this case only root is able to get into the directory !!!!!

I tried to change the permissions with :

chmod -v 777 /mnt/winG

The system tell me the permissions are changed but wen I type ls -l i see that
nothing is changed.

I cannot see why ?????

Should anyone help me ???

Tanks in advance.
 
Old 12-07-2003, 12:04 PM   #2
lyle_s
Member
 
Registered: Jul 2003
Distribution: Slackware
Posts: 392

Rep: Reputation: 55
I think you want:

/dev/hdb3 /mnt/winG vfat defaults,umask=022 0 0

in your /etc/fstab.

I think the explanation is since FAT filesystems have no concept of different users Linux has to work out some way of resolving ownership and permissions. This happens at mount time, explaining why your attempts to change permissions after mount time had no effect.

By using the umask option you set this up at mount time.

If anyone has a better explanation please offer it!

You can also set the user id and group id of the files on fat, vfat, and msdos filesystems; see man mount and look for "Mount options for fat". I use the uid and gid options on my windows partition to make the files belong to me, and I mount it inside my own home directory; they're my files after all.

Lyle
 
  


Reply



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
permission ... permissions .... permissions alaios Linux - General 1 05-31-2005 04:16 AM
Permissions jymmi Linux - Newbie 3 04-14-2005 11:43 PM
Permissions kushboy Linux - General 8 09-02-2004 06:05 PM
getting a directory's permissions and creating a new one with the same permissions newbie1000101 Programming 1 04-10-2004 12:52 PM

LinuxQuestions.org > Forums > Linux Forums > Linux - Distributions > Slackware

All times are GMT -5. The time now is 04:03 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