How to set label on swap partition (SOLVED)

Pasha R e97665728 at 013.net
Sat Mar 12 08:42:25 UTC 2005


On Fri, 2005-03-11 at 19:04 -0500, Jeff Kinz wrote:
> On Fri, Mar 11, 2005 at 09:05:43PM +0000, Paul Howarth wrote:
> > On Fri, 2005-03-11 at 15:07 -0500, Jeff Kinz wrote:
> > > On Fri, Mar 11, 2005 at 10:02:05PM +0200, Pasha R wrote:
> > > > It appears that mkswap does have a -L option, though undocumented in man
> > > > page. Using it fixed my problem.
> > > > 
> > > > BTW, how do you set label in fdisk? I tried that, but could not find an
> > > > appropriate option.
> > > 
> > > from the "m" command ("m" for "help" :-) )
> > >    "t"   change a partition's system id
> > > 
> > > The type for linux swap is "82"
> > 
> > That's setting the partition type in the partition table, which is not
> > the same as the filesystem label, which lives "inside" the filesystem on
> > each partition.
> 
> <Hesitantly>
> ummm - but a swap partition has no "filesystem" per se.  Just a chunk of
> addressable bytes, nicht?
> 
> I have to assume that Pasha is talking about the partition type ID
> since you (might, probably?) have to know what the type of filesystem,
> if any, a partition contains, before you can "read it" to retrieve any
> label?
> 
> </Hesitantly>
> 
 No, I was talking about "filesystem" label. That's why I wrote that
e2label doesn't do it. Apparently, FC3 sets labels for swap partitions
somehow. In fact swapon has 2 options to find a swap device - either a
device name or a label in format LABEL=name. Anaconda set label
automatically for swap device as SWAP-hdb2 (in my case).





More information about the fedora-list mailing list