/etc/fstab LABEL=/ stuff 

Newsgroups: comp.os.linux.misc
Date: 2002-11-12 12:46:23 PST
> What exactly is the purpose of the LABEL= phrase in /etc/fstab ?
> Surely mount tells one what is mounted where if one wants to know ?
>
> I think the LABEL= idea was a really bad one.
> It just causes confusion without adding to knowledge.

I don't think it was a bad idea - and after all you don't *have* to use it. If you type "man fstab" then you will find:

Instead  of giving the device explicitly, one may indicate the (ext2 or
XFS) filesystem that is to be mounted by its UUID or volume label (cf.
        e2label(8) or xfs_admin(8)), writing LABEL=<label> or
UUID=<uuid>, e.g., `LABEL=Boot'  or
`UUID=3e6be9de-8139-11d1-9106-a43f08d823a6'.   This
        will make the system more robust: adding or removing a SCSI disk
changes the disk device name but not the filesystem volume label.

I think that says it all. You can view and change labels with e2label, mount obviously enumerates all labels present in all ext2/3 filesystems and mounts the appropriate one.

I think this is quite useful, especially if you are cloning partitions since it won't matter what partition order the destination computer has.

But I admit, it can be confusing if you don't know what it does …

Ingmar

/etc/fstab LABEL=/ stuff 

> Could someone explain to me how this LABEL=/ stuff in newer
> (Redhat) /etc/fstab works?

Well the label shouldn't really have anything to do with your problems … it's just a way of avoiding to hardcode the partition numbers into an fstab file, instead you use "labels" that can be created / viewed with "e2label"

> I had a root dump of a Redhat 8.0 ext3 FS which I restored to a
> partition with an ext2 FS and I'm getting a kernel panic because
> the kernel loads an ext3 module while the FS now is a
> ext2 FS.

I don't think that I understand this correctly, but something on the side. ext3 is really just ext2 + journal. E.g. to convert an ext2 filesystem to ext3 you just run one command ('tune2fs -j /dev/hdaX') to create the journal.

You can also always force mount to a certain filesystem type in fstab

Ingmar