just a followup to the previous post about mounting filesystems
by label, rather than by actual /dev/hda? name.  assuming that
/dev/hda7 == /home (which it does on my box), first you label
that partition:

# e2label /dev/hda7 home  (or whatever you want to call it)
# e2label /dev/hda7
home                      (to verify)


  next, edit /etc/fstab and change the line:

        /dev/hda7 ...

  to read

        LABEL=home ...    (or whatever you labelled it)

  
  having said all that, a couple of issues of which i am
unsure.

  first, i'm not sure how far you can push this idea.
mounting by label is great if you want to restructure
partitions and don't want to deal with the partitions
being renumbered automatically (something i have some
terrifically painful memories of, thanks).

  but i haven't tried this with mounting things like
/ or /boot or /usr by label (not like it would make
much sense anyway, since the root filesystem is specified
in /etc/lilo.conf -- not sure you can use labelling in 
there, but i'm not keen on testing it.)

  second, when i tested this by mounting /home by label,
during boot, i got a new message saying that /dev/hda7
was already mounted, and i thought, hmmmmmmm, why would
mounting it by label suddenly force it to be mounted
twice?

  tracked it down to /etc/rc.d/rc3.d/S25netfs, the
start code:

case "$1" in
  start)
        [ -n "$NFSFSTAB" ] && action "Mounting NFS filesystems" mount -a -t nfs
        [ -n "$SMBFSTAB" ] && action "Mounting SMB filesystems" mount -a -t smbfs
        [ -n "$NCPFSTAB" ] && action "Mounting NCP filesystems" mount -a -t ncpfs
        touch /var/lock/subsys/netfs
        action "Mounting other filesystems" mount -a -t nonfs,smbfs,ncpfs
        ;;

  apparently, that last mount tried to once again mount the 
labelled filesystem (you can see that just by typing the above
mount command).  i suspect that what's happening here is that
the mount table (in /etc/mtab) shows /dev/hda7 being mounted,
but /etc/fstab shows LABEL=home, they don't match exactly so
the mount command tries to mount it yet again.  no harm, just
wasted cycles.  at least, this is my best guess.  any other
comments?

rday



-- 
To unsubscribe: mail [EMAIL PROTECTED] with "unsubscribe"
as the Subject.

Reply via email to