Skip site navigation (1)Skip section navigation (2)
Date:      Sun, 30 Nov 2008 12:16:27 +0100
From:      Tijl Coosemans <tijl@ulyssis.org>
To:        freebsd-questions@freebsd.org, admin@azuni.net
Subject:   Re: FreeBSD 4.8: can't load kernel after doing "cp -R /" to another disk
Message-ID:  <200811301216.28523.tijl@ulyssis.org>
In-Reply-To: <49322B49.80005@azuni.net>
References:  <49322B49.80005@azuni.net>

next in thread | previous in thread | raw e-mail | index | archive | help
On Sunday 30 November 2008 06:57:29 admin@azuni.net wrote:
>>> Hello, everyone. This is the problem: our SCSI disk with FreeBSD
>>> 4.8 on it has been failing recently, so I copied its root partition
>>> to a fresh IDE disk with cp -pR and
>> 
>> You should use dump and restore to copy the root partition, see:
> 
> I'd done that before trying cp -pR, as outlined by rse@:
> 
> dump -L -0 -f- /old | (cd /new && restore -r -v -f-)
> http://people.freebsd.org/~rse/mirror/
> 
> which isn't too different. I think I know what the problem is: I made
> the new single slice and FreeBSD partition on it and ran newfs -U on
> it using the latest FreeBSD 5.x livecd toolkit, and later 4.8 can't
> even mount that partition (mount /dev/ad0s1a /mnt) failing with
> "incorrect superblock", so I think its /boot/loader can't load the
> kernel because of FS issues (but strangely enough pressing "?" at the
> boot loader prompt lists directory entries of the root FS just fine).
> It turns out UFS isn't upwards compatible from releases 4.8 -> 5.5.
> I'll try running newfs -U from 4.8. Last time I checked many 4.8
> binaries couldn't run due to disk errors, I hope newfs runs ok...

You need to create a UFS1 file system. Also, root file systems
usually don't have soft updates (-U) enabled.



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