Subject: Re: vfat mount uid/gid not working

From: Andrew Konstantinov <[email-masked]>
Date: Sun, 22 Dec 2019 19:28:38 -0800

Christian,

Thanks for the reply. Actually, rebooting the box fixed the issue! Saw on
some random forum that it helped someone and tried. Always thought reboots
were windows specific!

On Sun, Dec 22, 2019 at 7:23 PM Christian Kujau <[email-masked]>
wrote:

> On Sun, 22 Dec 2019, Andrew Konstantinov wrote:
> > $ sudo mount -t /dev/sda1 /mnt/content -o rw,uid=1000,gid=1000
> > $ sudo mount -v G content
> > /dev/sda1 on /mnt/content type vfat
> >
> (rw,relatime,fmask=0022,dmask=0022,codepage=437,iocharset=utf8,shortname=mixed,errors=remount-ro)
>
> Cannot reproduce on 5.4.5-0-virt (Alpine 3.12_alpha20191219), but
> something is curious about your mount commands: why specify "-t" but not
> fstype? What is "mount -v G..." supposed to do? Did you mean "... | grep
> conent"?
>

Yeah, "-t" is a typo, worked because it was already in my /etc/fstab. "G"
is the oh-my-zsh alias for "| grep".

> ==============================================================
> $ mkfs.vfat /dev/loop0
> $ mount -t vfat -o uid=1000,gid=1000 /dev/loop0 /mnt/
> $ mount | grep /mnt
> /dev/loop0 on /mnt type vfat
> (rw,relatime,uid=1000,gid=1000,fmask=0066,dmask=0066,codepage=437,iocharset=utf8,shortname=mixed,errors=remount-ro)
> $ ls -ld /mnt/
>
>
> drwx--x--x    2 dummy    dummy          512 Dec 31  1969 /mnt/
> ==============================================================
>
> Anything interesting in dmesg? Also, out of curiosity: why do you want to
> set uid/gid on a FAT filesystem?
>

dmesg did not have anything interesting. Want to set uid/gid so that these
volumes mapped inside docker containers correspond to same users and not
root (just for convenience).

> C.
> --
> BOFH excuse #67:
>
> descramble code needed from software company
>