NetBSD-Users archive
[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index][Old Index]
Re: Partition problems when using 'restore'
In article <20964601.post%talk.nabble.com@localhost>,
superdave <dave.gibson%coloradovnet.com@localhost> wrote:
>
>Hello everyone! I'm hoping someone can help out here. I'm not too proficient
>with NetBSD yet, and I'm having some trouble with manual partitioning while
>restoring from dump files.
>
>I have a remote server that has dump files of many other servers. I would
>like to use these dump files to populate virtual machines (VMware), in order
>to experiment with changes on the VM before going live on the actual server.
>The idea is to boot the VM to the NetBSD LiveCD, mount the remote
>filesystem, and then restore the dump to the vmdk hard drive. The result
>would be a bootable vmdk drive that gives me a running copy of the dumped
>system.
>
>I'm having no trouble with the mounting and the restore; however, my trouble
>is getting the new image to boot. Upon restart, I get the "Fn: diskn"
>message, and any input results in "error?" or "error 3".
>
>I'm working off of a set of instructions left by a previous sysadmin; my
>problem is that I have very little understanding of how NetBSD partitions
>work (and the online help is only for standard situations).
>
>Here is the flow of work:
>
>1. Boot to liveCD
>2. mount the remote filesystem
>3. Set up a new partition (on vmdk drive):
> $ fdisk -u wd0
> $ disklabel -I -e wd0
> $ newfs /dev/rwd0a
>4. Mount the new partition
>5. Restore from dumpfile
>6. Set partition MBR:
> $ fdisk -B wd0
>7. Reboot into new system
>
>These steps were provided to me by the previous admin; however, that's as
>detailed as they get.
>
>During the "fdisk -u wd0" process, I'm keeping the BIOS geometry, setting up
>partition 0, accepting all defaults (sysid=169, start= 63,0cyl,0MB, size =
>default (8192MB), bootmenu=[])
>
>During the "disklabel -I -e wd0" process, I don't know what to do. Partition
>c and d look normal, and the only other partition listed is e:, with an
>offset of 63 and a fstype of NetBSD4.2. I've tried using the disklabel as
>is, and tried changing the e: partition to be the a: partition; these didn't
>help.
cat /etc/fstab from the restore image
and you'll see what partitions and mountpoints you had before.
Try to make guesses at the sizes from the size of the dump files and
use disklabel to create them.
create the mountpoint directories mount the filesystems and restore
the dump files in them.
>The newfs process goes fine; not much I can screw up there. I know that the
>filesystem is fine, because mounting and moving files to it both work.
>
>After restore, when I run the "fdisk -B wd0" process, I have to update the
>bootcode from /usr/mdec/mbr_bootsel, and I accept the default timeout of 10.
>As for the default boot option, I've tried both "0: The first active
>partition" and "1: Harddisk 0"; neither gets past the "Fn: diskn" reboot
>error. There is no multiboot in my scenario - is bootcode even necessary?
>
>Some things I've noticed: the instructions never show to set the partition
>active; I've tried this with "fdisk -a wd0", and setting partition 0 to
>active. This doesn't seem to change the reboot error.
>
>Also, the system being restored uses the "ld0" partition; I assume this is a
>logical volume, and may be part of my problem.
>
>I can't find enough info to help me troubleshoot this; does anybody have any
>idea about steps I'm missing or any other info on how I can get this
>restored dump image to boot?
$ cp /usr/mdec/boot /boot
depending on the newfs command (I would use -O 2 for ffsv2) you should
$ installboot -v /dev/rwd0<partition letter> /usr/mdec/bootxx_ffsv<1 or 2>
christos
Home |
Main Index |
Thread Index |
Old Index