LinuxQuestions.org
Help answer threads with 0 replies.
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-13-2006, 04:38 AM   #1
somae
Member
 
Registered: Nov 2006
Posts: 56

Rep: Reputation: 15
setting permissions for a dos/windows drive


I have a dos/windows hard drive mounted under "/" (slackware 10.2.0). I'm not able to fully access it unless I'm running kde (v3.4) as root. I tried to change permissions and ownership but it seems the system won't allow that.

Any way to do that?

Thanks.
 
Old 12-13-2006, 04:51 AM   #2
kilgoretrout
Senior Member
 
Registered: Oct 2003
Posts: 2,675

Rep: Reputation: 239Reputation: 239Reputation: 239
Post your /etc/fstab file. You need to edit that to give all users read/write access to a FAT or FAT32 partition.
 
Old 12-13-2006, 05:31 AM   #3
PJBrs
Member
 
Registered: Oct 2006
Distribution: Slackware 14.1 / 14.2
Posts: 41

Rep: Reputation: 16
It also helps to read this:

http://slackwiki.org/Windows_Partitions

In short, it means you have to set correct dmask and fmask values in your mount-options.

Also, but I'm not entirely sure of this, if I'm correct dmask and fmask mount options only work with 2.6 kernels, and 2.4 kernels use umask instead, which sets the same mask for directories and files alike. However, this also means that either all your files will be set executable, or you won't be able to open directories.

Anyways, I could be entirely wrong about this dmask, fmask, umask info, so please correct me if I'm wrong. In fact, I'm curious as to what the fmask, dmask, umask story actually is
 
Old 12-13-2006, 02:04 PM   #4
kilgoretrout
Senior Member
 
Registered: Oct 2003
Posts: 2,675

Rep: Reputation: 239Reputation: 239Reputation: 239
dmask = directory umask

fmask = file umask

dmask and fmask are typically used when mounting samba shares and are really overkill for the simple task of mounting a local windows partition IMHO and unduly complicate the task at hand.

umask refers to the default permissions that a file or directory will be given when initialy created in linux.

Every file or directory in linux has rwx permissions set for the owner, the group members and the world at large. The problem is that the FAT and FAT32 filesystems have no permission structure to speak of. To remedy this problem, linux grafts on a 'nix permission structure to FAT and FAT32 partitions which is set for all files and directories on the mounted partition through the umask parameter in the fstab entry. If no umask parameter is given, the default umask will be used which is normally set to only allow root to read/write and others to read only. Typically, you just need to add "umask=0" to the fstab entry for the windows FAT or FAT32 partition to give all users read/write access.
Because of the limitations of the FAT and FAT32 filesystems, you can only change access permissions on these partitions through the fstab umask setting. Attepts to change the permissions with chmod like you would on a normal linux filesystem partition will be rejected. Since there is no native permission structure on FAT and FAT32 filesystems, there is nothing for chmod to reset.
 
Old 12-14-2006, 04:27 AM   #5
PJBrs
Member
 
Registered: Oct 2006
Distribution: Slackware 14.1 / 14.2
Posts: 41

Rep: Reputation: 16
Ah cheers

Now I'm still curious about one thing - Is it so that the 2.4 kernel, in contrast to the 2.6 kernel, does _not_ accept dmask and fmask values for mounting fat32-partitions, but only umask?

I just checked the man-pages for mount, and it didn't show any information about this, but I seem to recall that there was this small difference between 2.4 and 2.6...
 
Old 12-15-2006, 05:00 AM   #6
somae
Member
 
Registered: Nov 2006
Posts: 56

Original Poster
Rep: Reputation: 15
I set the fstab listing for the drive to umask=0007. This resulted in rwx rwx ___ permissions. I assume that the umask numbers are the opposite of chmod? Someone suggested using "user,noauto" there instead. I wanted to limit the access to owner and group since I thought that if others have rwx that anyone on the internet could access it. --Is that correct?

Thanks for the help.
 
  


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
Setting permissions on an external USB hard drive so that all users can read from it? Pi Man Linux - Hardware 2 09-07-2004 10:50 PM
Setting Drive Permissions StarSage Fedora 1 06-10-2004 01:14 AM
Setting Apache permissions in windows... King Linux - Newbie 0 08-05-2003 08:52 PM
Changing Permissions of windows drive sub_bastard Linux - Newbie 2 08-03-2003 10:15 PM
Permissions on a windows drive Vlackmar Linux - General 3 03-06-2002 09:38 AM

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

All times are GMT -5. The time now is 09:27 AM.

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
Facebook: linuxquestions Google+: linuxquestions
Open Source Consulting | Domain Registration