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

Re: Request for enhancement [Re: Question about /etc/fstab in Squeeze]

On 20101221_031624, Tom H wrote:
> On Mon, Dec 20, 2010 at 5:37 PM, Stephen Powell <zlinuxman@wowway.com> wrote:
> > On Sun, 19 Dec 2010 11:44:35 -0500 (EST), Rick Thomas wrote:
> >> On Dec 19, 2010, at 8:09 AM, Stephen Powell wrote:
> >>>
> >>> Caution: reformatting a swap partition with mkswap will change the
> >>> uuid unless the existing one is explicitly re-specified during
> >>> formatting.
> >>
> >> Which raises a question that has been on my mind for a while...
> >>
> >> The Debian Installer insists on reformatting any swap partitions it
> >> finds, even though that partition, specified by UUID, is probably in
> >> use in the /etc/fstab for some other instantiation of Linux -- thus
> >> breaking the other Linux, leaving it without a usable swap partition.
> >>
> >> Would it be possible to either:
> >>
> >> 1) have the option (default) of *not* reformatting a swap partition
> >>               or
> >> 2) if reformatting is necessary or desired, have the option (default)
> >> of preserving the UUID.
> >>               or
> >> 3) using "LABEL=" instead of "UUID=" in fstab for swap partitions, if
> >> it turns out to be easier to preserve a LABEL than a UUID.
> >
> > From what I've heard, the Ubuntu installer has the same problem,
> > and it can ruin a functioning Debian system too.  Of course, that's
> > not something the Debian installer team can do anything about.
> > That's outside of their jurisdiction.  But many Ubuntu people, both
> > users and developers, are known to monitor Debian's lists.
> I used to have a netbook on which I installed multiple distributions
> and I had to run "mkswap - U <uuid>"after on any new
> install/re-install and edit its fstab. Both the Live CD and the
> alternate CD Ubuntu installers run mkswap (the alternate is basically
> the Debian installer) just like d-i.
> We had a thread on d-u about this some time ago and someone said that
> the expert installation mode allows you to disable mkswap from
> running.

Long ago Debian install scripts made DHCP be the default for setting
the IP address. Since then I have always used expert because I have a
personal preference for controlling what IP address are in use. 

I have never noticed an option disabling mkswap during install. Of
course you can use mkswap to install your preferred UUID after the
install is complete, IF you have taken care to record your preferred
UUID (or if you are a Cylon who carries such data effortlessly in your
internal memory banks.) 

Otherwise, you can mount each of the partitions that contain an
alternative OS and edit the new UUID into the older versions of
/etc/fstab. Or mount one of the older OS partitions (on /mnt), read
the prior UUID, edit it into the new /etc/fstab and use mkswap -U to
write it back onto the partition. Somehow this reminds me of the old
saying, "Real programmers write code in octal."

Paul E Condon           

Reply to: