Skip site navigation (1)Skip section navigation (2)
Date:      Fri, 17 Sep 2010 15:32:32 -0300 (BRT)
From:      "Nenhum_de_Nos" <matheus@eternamente.info>
To:        freebsd-stable@freebsd.org
Subject:   Re: How to predict drive number change for 7.3->8.1 upgrade?
Message-ID:  <b22040dfbbccffc147e288e346e20c24.squirrel@cygnus.homeunix.com>
In-Reply-To: <AANLkTinCiDX2zfeM74BonLe3Ndq44jOz1Tj4mPJScUfm@mail.gmail.com>
References:  <y9l7himgit9.fsf@deinprogramm.de> <201009171238.o8HCcwCl084727@lurza.secnetix.de> <AANLkTinCiDX2zfeM74BonLe3Ndq44jOz1Tj4mPJScUfm@mail.gmail.com>

next in thread | previous in thread | raw e-mail | index | archive | help

On Fri, September 17, 2010 13:10, Freddie Cash wrote:
> On Fri, Sep 17, 2010 at 5:38 AM, Oliver Fromme <olli@lurza.secnetix.de>
> wrote:
>> Michael Sperber <sperber@deinprogramm.de> wrote:
>>  > I just upgraded my desktop system from 7.3 to 8.1, and the main hard
>>  > drive, which was /dev/ad6 before is now /dev/ad10.  Consequently,
>> the
>>  > initial boot failed when trying to mount the root file system from
>> ad6.
>>  >
>>  > The desktop system is now fixed, but I also have a rented server
>> with
>>  > only a serial console, and I worry that the upgrade is going to
>> leave me
>>  > with a dead machine.  Is there any way to predict how the drive
>> number
>>  > changes?  (Why does it change at all?)  If so, what's the proper
>> way to
>>  > tell the system the initial root device *before* rebooting?
>>
>> Remove "options ATA_STATIC_ID" from your kernel config
>> before building the new kernel and rebooting.  Then your
>> first disk will be ad0, no matter what controller and
>> channel it is connected to.  Be sure to update your
>> /etc/fstab file.
>
> Problem with doing that (no ATA_STATIC_ID) is that if you change the
> order that your PCI devices are enumerated, you will change the order
> in which your disks are probed, and all your numbers change again.  :)
>  And there's an option for this in every BIOS I've worked with.  Plus,
> moving addon controllers from one slot to another will also re-number
> your devices.
>
> The best, long-term, solution is to label your devices/filesystems so
> that the name never changes, no matter what happsn to the underlying
> device nodes.  There are multiple ways to do so, depending on whether
> you want to label the disk, the slice, the partition, or the
> filesystem:
>   - glabe;
>   - gpart labels
>   - filesystem labels

I have the same issue, a virtual machine rented in some datacenter. I'd
like to know a way that is safe, as I did already on another box the
glabel way without newfs on the label (but the underlying device). never
got problems thought, but I figure this way is better for aditional disks,
not / and system slices.

thanks,

matheus

-- 
We will call you cygnus,
The God of balance you shall be

A: Because it messes up the order in which people normally read text.
Q: Why is top-posting such a bad thing?

http://en.wikipedia.org/wiki/Posting_style



Want to link to this message? Use this URL: <https://mail-archive.FreeBSD.org/cgi/mid.cgi?b22040dfbbccffc147e288e346e20c24.squirrel>