Re: [Hampshire] fstab question

Top Page

Reply to this message
Author: Mark Johnson
Date:  
To: Hampshire LUG Discussion List
Subject: Re: [Hampshire] fstab question
> I wonder if anyone could help me, as it's not clear to me from the man
> page what I've got wrong.
>
> I have this line in /etc/fstab:-
>
> /dev/hdb1  /windows/e  ntfs  ro,users    0    0

>
> The intention is that I can read files in this partition as an ordinary
> user - I'm not interested in writing to it as I haven't investigated the
> current state of play with writing to NTFS. But when I try to open the
> directory to read I get a permission denied message, with access as
> read-only for root and none for anyone else. What have I got wrong?
>
> Thanks
>
> Owain
>

Hi Owain,
The problem is that Windows filesystems don't deal with file permissions
very well, so by default the whole partition is owned by root.

You can fix this problem by setting the group ID the partition is mounted
with to one your user is a member of, like this:

/dev/hdb1  /windows/e  ntfs  ro,users,gid=1000    0    0


Where 1000 is the group ID. You can also add other users to this group to
give them read access.

Hope that helps,
Mark