mount options not clear - Linux

This is a discussion on mount options not clear - Linux ; (For info I am using debian/etch) Here what I have in /etc/fstab /dev/sdb9 /mnt/sdb9 ext3 rw,users,noauto 0 0 If sdb9 is not mounted this is what I see in /mnt drwxr-xr-x 2 root root 4096 2007-04-22 15:43 sdb9 When sdb9 ...

+ Reply to Thread
Results 1 to 3 of 3

Thread: mount options not clear

  1. mount options not clear

    (For info I am using debian/etch)

    Here what I have in /etc/fstab
    /dev/sdb9 /mnt/sdb9 ext3 rw,users,noauto 0 0

    If sdb9 is not mounted this is what I see in /mnt
    drwxr-xr-x 2 root root 4096 2007-04-22 15:43 sdb9

    When sdb9 is mounted by user carex:
    carex@triac:/mnt$ mount -v /dev/sdb9
    /dev/sdb9 on /mnt/sdb9 type ext3 (rw,noexec,nosuid,nodev)
    carex@triac:/mnt$
    I get this in /mnt
    drwxr-xr-x 3 carex carex 4096 2007-04-22 15:26 sdb9

    Until here no problem.
    Everything seems to go as planned by the manual.

    But when sdb9 is mounted by user test00
    test00@triac:/mnt$ mount -v /dev/sdb9
    /dev/sdb9 on /mnt/sdb9 type ext3 (rw,noexec,nosuid,nodev)
    I get this in /mnt
    test00@triac:/mnt$ ls -al
    drwxr-xr-x 3 carex carex 4096 2007-04-22 15:26 sdb9
    test00@triac:/mnt$

    And when user test00 does umount the device
    test00@triac:/mnt$ umount /dev/sdb9
    test00@triac:/mnt$ ls -al
    drwxr-xr-x 2 root root 4096 2007-04-22 15:43 sdb9
    test00@triac:/mnt$

    My questions:

    a)when sdb9 is mounted by test00 why is the device sdb9 still owned
    by the user carex ??
    I think the device sdb9 should be owned by user test00 ???
    (by the user who actually does mount the device)

    b)how can user test00 use sdb9 in rw mode ??? (and other regular users)


    Many thanks,

    carex

  2. Re: mount options not clear

    I note that the time stamp for the mounted directory is the same in both
    your carex and test00 mounts. This would indicate that you have either
    not umounted the partition or that the mount information has been cached.

    The other issue however is that the permissions come from the files on
    the device you've mounted. You can override this with special options in
    the mount command in some cases.


    carex wrote:
    > (For info I am using debian/etch)
    >
    > Here what I have in /etc/fstab
    > /dev/sdb9 /mnt/sdb9 ext3 rw,users,noauto 0 0
    >
    > If sdb9 is not mounted this is what I see in /mnt
    > drwxr-xr-x 2 root root 4096 2007-04-22 15:43 sdb9
    >
    > When sdb9 is mounted by user carex:
    > carex@triac:/mnt$ mount -v /dev/sdb9
    > /dev/sdb9 on /mnt/sdb9 type ext3 (rw,noexec,nosuid,nodev)
    > carex@triac:/mnt$
    > I get this in /mnt
    > drwxr-xr-x 3 carex carex 4096 2007-04-22 15:26 sdb9
    >
    > Until here no problem.
    > Everything seems to go as planned by the manual.
    >
    > But when sdb9 is mounted by user test00
    > test00@triac:/mnt$ mount -v /dev/sdb9
    > /dev/sdb9 on /mnt/sdb9 type ext3 (rw,noexec,nosuid,nodev)
    > I get this in /mnt
    > test00@triac:/mnt$ ls -al
    > drwxr-xr-x 3 carex carex 4096 2007-04-22 15:26 sdb9
    > test00@triac:/mnt$
    >
    > And when user test00 does umount the device
    > test00@triac:/mnt$ umount /dev/sdb9
    > test00@triac:/mnt$ ls -al
    > drwxr-xr-x 2 root root 4096 2007-04-22 15:43 sdb9
    > test00@triac:/mnt$
    >
    > My questions:
    >
    > a)when sdb9 is mounted by test00 why is the device sdb9 still owned
    > by the user carex ??
    > I think the device sdb9 should be owned by user test00 ???
    > (by the user who actually does mount the device)
    >
    > b)how can user test00 use sdb9 in rw mode ??? (and other regular users)
    >
    >
    > Many thanks,
    >
    > carex


  3. Re: mount options not clear

    carex wrote:
    > (For info I am using debian/etch)
    >
    > Here what I have in /etc/fstab
    > /dev/sdb9 /mnt/sdb9 ext3 rw,users,noauto 0 0
    >
    > If sdb9 is not mounted this is what I see in /mnt
    > drwxr-xr-x 2 root root 4096 2007-04-22 15:43 sdb9
    >
    > When sdb9 is mounted by user carex:
    > carex@triac:/mnt$ mount -v /dev/sdb9
    > /dev/sdb9 on /mnt/sdb9 type ext3 (rw,noexec,nosuid,nodev)
    > carex@triac:/mnt$
    > I get this in /mnt
    > drwxr-xr-x 3 carex carex 4096 2007-04-22 15:26 sdb9
    >
    > Until here no problem.
    > Everything seems to go as planned by the manual.
    >
    > But when sdb9 is mounted by user test00
    > test00@triac:/mnt$ mount -v /dev/sdb9
    > /dev/sdb9 on /mnt/sdb9 type ext3 (rw,noexec,nosuid,nodev)
    > I get this in /mnt
    > test00@triac:/mnt$ ls -al
    > drwxr-xr-x 3 carex carex 4096 2007-04-22 15:26 sdb9
    > test00@triac:/mnt$
    >
    > And when user test00 does umount the device
    > test00@triac:/mnt$ umount /dev/sdb9
    > test00@triac:/mnt$ ls -al
    > drwxr-xr-x 2 root root 4096 2007-04-22 15:43 sdb9
    > test00@triac:/mnt$
    >
    > My questions:
    >
    > a)when sdb9 is mounted by test00 why is the device sdb9 still owned
    > by the user carex ??
    > I think the device sdb9 should be owned by user test00 ???
    > (by the user who actually does mount the device)
    >
    > b)how can user test00 use sdb9 in rw mode ??? (and other regular users)
    >
    >
    > Many thanks,
    >
    > carex


    Hi Carex,

    There is a lot of cool information about your mounted drives in
    /etc/mtab

    cat /etc/mtab | grep -i sdb9

    If you mount sdb9 manually it has to either be in fstab or
    be mounted by root (or sudo). If you mount as root (not is fstab)
    you have to use the gid and uid mount options (man mount) for the
    user(s) to be able to use it.

    HTH,
    -T

+ Reply to Thread