changing file permissions

Jeremy C. Reed plug-discuss@lists.plug.phoenix.az.us
Thu, 22 May 2003 15:23:41 -0700 (PDT)


On Thu, 22 May 2003, Rob Wultsch wrote:

> /stuff is vfat.I have it automaticly mounted with a line in my
> /etc/fstab that reads:
> /dev/hda2 /stuff vfat auto,user,umask=000 0 0
>
> I am discouraged by:
> root@fearlessrogue:/home/rob# chown rob:rob /stuff
> chown: changing ownership of `/stuff': Operation not permitted
>
>
> Any suggestions???

Yes, see my previous email:

> > I assume that /stuff is not a Unix-type filesystem.

It's vfat. It is not a Unix-type filesystem that supports different users
and groups.

> > Maybe, use your mount options to choose which uid (and gid) should be used
> > when it is mounted in the first place.

Look at your mount manual page; read about "vfat":
       uid=value and gid=value
              Set the owner and group of all files. (Default: the
              uid and gid of the current process.)


For example (where 101 is your music user and 101 is your music group):

/dev/hda2 /stuff vfat auto,user,umask=000,uid=101,gid=101 0 0

Have fun!

   Jeremy C. Reed
   http://bsd.reedmedia.net/