[Date Prev][Date Next] [Thread Prev][Thread Next] [Date Index] [Thread Index]

Bug#249041: Please support disk labels (LABEL=)



Package: partman
Severity: wishlist

Please add an option to specify a disk label (max 16 characters), and
use that in fstab if it's available.


----- Forwarded message from Andrew Pollock <apollock@debian.org> -----

From: Andrew Pollock <apollock@debian.org>
Subject: Re: Bug#248902: installation-report debian-installer beta4, arch i386
Date: Fri, 14 May 2004 11:39:06 +1000
To: Martin Michlmayr <tbm@cyrius.com>
Cc: debian-boot@lists.debian.org
User-Agent: Mutt/1.5.4i

On Thu, May 13, 2004 at 11:13:01PM +0100, Martin Michlmayr wrote:
> * tbm <tbm@cyrius.com> [2004-05-13 21:02]:
> > * Nico Dietrich <nicodietrich@web.de> [2004-05-13 20:22]:
> > > LABEL=/                 /                   ext3    defaults        1 1
> > > LABEL=/home             /home               ext3    defaults        1 2
> > 
> > How did you get those LABELs?  Did you do that by hand after d-i?
> 
> Someone suggested a while ago to use LABEL= in d-i.  Can someone who
> uses this feature explain exactly how it works?  If I put LABEL=/home
> in a /etc/fstab, how does Linux know which partition is associated
> with this label?

Basically, at filesystem creation time (or afterwards) labels are added to
the filesystems. AFAIK, this is an ext2/3 and xfs feature, I'm not aware of
other filesystems that have it, someone may correct me.

This can be done with the mke2fs/tune2fs/mkfs.xfs -L option, or the
e2label/xfs_admin programs.

>From fstab(5):

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.

So, it would actually be probably more desirable to mount using the UUID
than the label (however the label is more memorable), as most filesystems
have a UUID, whereas only a few support a label.

I would suggest that in the case of ext2/3 and XFS, when a filesystem is
created, it automatically gets labelled with a name relevant to what the
filesystem mount point should be, but perhaps in all cases the /etc/fstab
entry uses the filesystem's UUID.

The administrator can, if need be in a recovery situation, mount /usr by
going "mount LABEL=/usr /usr", but the system would normally mount /usr by
it's UUID.

Hope this helps.

Andrew



----- End forwarded message -----
----- Forwarded message from Colin Watson <cjwatson@debian.org> -----

From: Colin Watson <cjwatson@debian.org>
Subject: Re: Bug#248902: installation-report debian-installer beta4, arch i386
Date: Fri, 14 May 2004 03:24:47 +0100
To: debian-boot@lists.debian.org
Cc: Martin Michlmayr <tbm@cyrius.com>
User-Agent: Mutt/1.3.28i

On Fri, May 14, 2004 at 11:39:06AM +1000, Andrew Pollock wrote:
> On Thu, May 13, 2004 at 11:13:01PM +0100, Martin Michlmayr wrote:
> > Someone suggested a while ago to use LABEL= in d-i.  Can someone who
> > uses this feature explain exactly how it works?  If I put LABEL=/home
> > in a /etc/fstab, how does Linux know which partition is associated
> > with this label?
> 
> Basically, at filesystem creation time (or afterwards) labels are added to
> the filesystems. AFAIK, this is an ext2/3 and xfs feature, I'm not aware of
> other filesystems that have it, someone may correct me.

JFS does, according to mkfs.jfs(8); although mount(8) doesn't mention it
so maybe it wouldn't work for this purpose, I'm not sure.

-- 
Colin Watson                                  [cjwatson@flatline.org.uk]


-- 
To UNSUBSCRIBE, email to debian-boot-REQUEST@lists.debian.org
with a subject of "unsubscribe". Trouble? Contact listmaster@lists.debian.org

----- End forwarded message -----
----- Forwarded message from Martin Michlmayr <tbm@cyrius.com> -----

From: Martin Michlmayr <tbm@cyrius.com>
Subject: Re: Bug#248902: installation-report debian-installer beta4, arch i386
Date: Fri, 14 May 2004 16:51:23 +0100
To: debian-boot@lists.debian.org
User-Agent: Mutt/1.5.6i

* Colin Watson <cjwatson@debian.org> [2004-05-14 03:24]:
> JFS does, according to mkfs.jfs(8); although mount(8) doesn't mention it
> so maybe it wouldn't work for this purpose, I'm not sure.

reiserfs supports labels too, but I cannot currently test this at all
(ext3 doesn't work either).

deprecation:/home/tbm/tmp# mount -L swap /mnt
Segmentation fault

(yeah, I formated my unused swap partition as ext3/reiserfs)
-- 
Martin Michlmayr
tbm@cyrius.com


-- 
To UNSUBSCRIBE, email to debian-boot-REQUEST@lists.debian.org
with a subject of "unsubscribe". Trouble? Contact listmaster@lists.debian.org

----- End forwarded message -----

-- 
Martin Michlmayr
tbm@cyrius.com



Reply to: