How to automount as a specific user
I'm trying to convert my Mom to using Debian over Win95, but until I can
get her a non-Win-printer, she'll probably bounce back and forth between
the two.
Accordingly, I've set her up to use Mozilla/Mozilla Mail in both
environments. I've set up the Linux side to point to the Mozilla data
directory on the Windows partition so that the mailboxes, etc will be
the same in both environments. However, in order to make this work, the
Windows partition needs to be mounted. I can automatically mount it
during bootup by putting an entry in the fstab
/dev/hda1 /home/novie/Win95 vfat defaults,rw,user,auto 0 0
but that causes the resulting mount point to be owned by root.root, and
then her Mozilla can't have write access to the partition.
If I change the fstab entry to use "noauto", and then in her .bashrc
script put a "mount Win95", that works fine, as long as she opens an
eterm window prior to starting Mozilla. She's logging into Linux/X via
WDM, and apparently that bypasses the .bashrc script, so the partition
doesn't get mounted when she logs in. But when she runs an Eterm, that
runs the script. However, there's no reason at this point to have her
start an eterm, just to close it again (or leave it open on the screen,
confusing her).
I suspect there's some way of running a script when she logs in via wdm,
but I'd rather do it via fstab on bootup, but with her as the owner of
the resulting mount point. I've checked man (and info - but as another
recent thread indicates, neither tool provides the examples that would
be SO helpful), and I haven't been able to find a solution. I found that
there's a UUID option, but the explanation is greek to me:
Mount the partition that has the specified uuid.
These two options require the file /proc/partitions
(present since Linux 2.1.116) to exist.
and there's an UID option for the adfs file system, but this is a FAT
file system.
Anyone have any clues?
Thanks!
Kent
Reply to: