External drive is being mounted as read-only

Sudhir Khanger sudhir at sudhirkhanger.com
Mon Sep 1 14:04:14 UTC 2014


On Mon, Sep 1, 2014 at 7:01 PM, Ed Greshko <ed.greshko at greshko.com> wrote:
> On 09/01/14 16:25, Sudhir Khanger wrote:
>> The only way to tell if this is a mountain or a molehill is to try
>> some other distribution.
>
> I guess you'll find no joy in Ubuntu.....   Installed a test system and plugged in my drive and allowed it to be automounted....
>
> egreshko at ubuntu:~$ mount | grep sdb1
> /dev/sdb1 on /media/egreshko/ext type ext4 (rw,nosuid,nodev,uhelper=udisks2)
>
> egreshko at ubuntu:~$ df -T /dev/sdb1
> Filesystem     Type 1K-blocks  Used Available Use% Mounted on
> /dev/sdb1      ext4 115246568 61044 109308228   1% /media/egreshko/ext
>
> egreshko at ubuntu:~$ ll -d /media/egreshko/ext
> drwxr-xr-x. 3 1029 65539 4096  9月  1 16:34 /media/egreshko/ext/
>
> egreshko at ubuntu:~$ touch /media/egreshko/ext/x
> touch: cannot touch ‘/media/egreshko/ext/x’: Permission denied
>
> Which is exactly what I would expect since my UID/GID on my Fedora systems is 1029/65539 and on the new Ubuntu system....
>
> egreshko:x:1000:1000:Ed Greshko,,,:/home/egreshko:/bin/bash
>

I haven't had time to look into it myself but more I read about ext4
your tryst explaining me earlier becomes more clear that permissions
persist with the filesystem. Now that I think more about it one
possibility is that I use same username across systems which might
have made it possible to mount with RW without superuser privileges.

I also did following to the ext4 drive.

chown $USER:$USER /run/media/$USER/storjet

That is all I had to do and the drive seems to not give heartache
anymore. Home user has all the privileges I need.

Now time to run that attic-backup.

Thanks again Ed.

-- 
Regards,
Sudhir Khanger.
sudhirkhanger.com
https://github.com/donniezazen


More information about the users mailing list