Linux - SoftwareThis forum is for Software issues.
Having a problem installing a new program? Want to know which application is best for the job? Post your question in this forum.
Notices
Welcome to LinuxQuestions.org, a friendly and active Linux Community.
You are currently viewing LQ as a guest. By joining our community you will have the ability to post topics, receive our newsletter, use the advanced search, subscribe to threads and access many other special features. Registration is quick, simple and absolutely free. Join our community today!
Note that registered members see fewer ads, and ContentLink is completely disabled once you log in.
Ok i want to be able to write as a user to my windows drive which is /mnt/windows/ or /dev/hda1.
This is what the permissions are:
----------------------------------------------
ls -l /mnt/
total 44
drwxr-xr-x 2 root root 4096 Feb 27 17:25 cdrom
drwxr-xr-x 2 root root 4096 Feb 27 17:25 cdrom1
drwxr-xr-x 2 root root 4096 Feb 27 17:25 floppy
drwxr-xr-x 69 root root 32768 Dec 31 1969 windows
------------------------------------------------
This is what I've tried so far.
-------------------------------------------------
[root@cacole windows]#chown chase /mnt/windows
chown: changing ownership of `/mnt/windows': Operation not permitted
[root@cacole windows]# chgrp chase /mnt/windows
chgrp: changing group of `/mnt/windows': Operation not permitted
[root@cacole /]# chmod 777 /mnt/windows
chmod: changing permissions of `/mnt/windows' (requested: 0777, actual: 0755): Operation not permitted
---------------------------------------------------
i've tried all these commands as root to the /dev/hda1 as well with no success. Again this is my whole windows drive i'd like to set user access to read, write and execute, instead of just root. Thanks for your time. I'm running RH9 with kde if that matters.
Windows (NTFS/FAT32) drives don't have permission bits like *NIX systems do. Because Linux needs some permissions, it assumes the ones you listed. To change that, you need the following options in your mount/fstab:
gid=staff,umask=0002
where gid can be whatever you like, and umask is kind of a reverse chmod - it's subtractive rather than additive. So 0002 corresponds to 776 permissions (I think - basically, rwxrwxr-x).
Note, also, that WRITING TO NTFS IS NOT STABLE AND SHOULD NOT BE USED UNLESS YOU KNOW WHAT YOU'RE DOING. If you're running a stock kernel, you won't be able to do it, period.
FAT32, you're OK.
You will need to change the permissions at mount time because the files system you are using does not support unix file permissions. You will need to add a "umask=0000" option to your fstab file or the mount command line. Please note that NTFS write support isn't considered stable yet.
ok thanks for the explanation... so your'e saying that this is what should be in the /etc/fstab file?
-------------------
/dev/hda1 /mnt/windows vfat gid=chase,umask=0002 0 0
--------------------
You might want to change the 2 to a 3 or a 7 in the umask. This will be more restrictive for 'others'. If this is a shared drive, consider using 0113 or 0117. This way you can't accidently execute a program someone dropped in that has the same name as a program in /bin.
LinuxQuestions.org is looking for people interested in writing
Editorials, Articles, Reviews, and more. If you'd like to contribute
content, let us know.