May I use a linux rescue disk to restore FreeBSD 4.10?

My CPU or motherboard died, and I need to get the server up and running asap. I have the all the data backed up. It's an internal shared network drive without internet access, hence the lack of consistent upgrading.

I took out the 2 hard drives and put them in a spare computer. Because of the data retrieval process, I get an "invalid partition: no /kernel" error when booting from hard disk, undoubtedly from using System Rescue CD 1.2.2 to transfer saved files to a remote computer. However, may I use this linux disk to set the drive geometry? Will TestDisk be all right? Do I need to change the geometry, or can I just set a partition to "bootable?"

My instinct is to use fsck, but I got confused whether running fsck from a linux disk will be appropriate, since I read "man fsck" online, and it called for different switches than "man fsck" on the rescue disk.

The reason why I didn't put in the v7.2 disks is only because of a total lack of upgrading experience, as well as trying to use FIXIT and not being able to load it, which is another strange issue. And for another unknown reason I can't connect to freesbie.org, after numerous attempts over several days.

I figure if I can at least boot to the hard drive, it will be less complicated.[/just cursed myself, didn't I?]
 
Are you sure the problem isn't something simple like connecting the drives back up in the opposite order? It sounds like the BIOS might be booting what used to be the secondary drive...
 
Good suggestion, but I tried switching the drives (a couple times just to make sure) before I loaded the rescue disk.

I'm trying to download a live cd from http://www.rofreesbie.org, but the download is slow on my end.

Just to throw it out there in case there is something(s) I am missing, here is some drive info:

Code:
[color="SeaGreen"]root@sysresccd[/color] [color="Blue"]/root[/color] % cat /proc/partitions
major minor  #blocks  name

   7        0     194440 loop0
   8        0   39082680 sda
   8        1   39078081 sda1
   8        5     131072 sda5
   8        6     508400 sda6
   8        7     262144 sda7
   8        8     262144 sda8
   8        9   37914321 sda9
   8       16   80043264 sdb
   8       20      25000 sdb4
[color="SeaGreen"]root@sysresccd[/color] [color="Blue"]/root[/color] % fdisk -l

Disk /dev/sda: 40.0 GB, 40020664320 bytes
255 heads, 63 sectors/track, 4865 cylinders
Units = cylinders of 16065 * 512 = 8225280 bytes
Disk identifier: 0x9f330261

   Device Boot      Start         End      Blocks   Id  System
/dev/sda1   *           1        4865    39078081   a5  FreeBSD
This disk has both DOS and BSD magic.
Give the 'b' command to go to BSD mode.

Disk /dev/sdb: 82.0 GB, 81964302336 bytes
256 heads, 63 sectors/track, 9926 cylinders
Units = cylinders of 16128 * 512 = 8257536 bytes
Disk identifier: 0x9080000a

   Device Boot      Start         End      Blocks   Id  System
/dev/sdb4   *           1           4       25000   a5  FreeBSD
This disk has both DOS and BSD magic.
Give the 'b' command to go to BSD mode.

Disk /dev/sdb4: 25 MB, 25600000 bytes
256 heads, 63 sectors/track, 3 cylinders
Units = cylinders of 16128 * 512 = 8257536 bytes
Disk identifier: 0x9080000a

     Device Boot      Start         End      Blocks   Id  System
/dev/sdb4p4   *           1           4       25000   a5  FreeBSD
Partition 4 has different physical/logical endings:
     phys=(1023, 255, 63) logical=(3, 25, 41)
[color="SeaGreen"]root@sysresccd[/color] [color="Blue"]/root[/color] % dmesg | grep sd
Driver 'sd' needs updating - please use bus_type methods
sd 0:0:0:0: [sda] 78165360 512-byte hardware sectors: (40.0 GB/37.2 GiB)
sd 0:0:0:0: [sda] Write Protect is off
sd 0:0:0:0: [sda] Mode Sense: 00 3a 00 00
sd 0:0:0:0: [sda] Write cache: enabled, read cache: enabled, doesn't support DPO or FUA
sd 0:0:0:0: [sda] 78165360 512-byte hardware sectors: (40.0 GB/37.2 GiB)
sd 0:0:0:0: [sda] Write Protect is off
sd 0:0:0:0: [sda] Mode Sense: 00 3a 00 00
sd 0:0:0:0: [sda] Write cache: enabled, read cache: enabled, doesn't support DPO or FUA
 sda: sda1
 sda1: <bsd: sda5 sda6 sda7 sda8 sda9 >
sd 0:0:0:0: [sda] Attached SCSI disk
sd 0:0:0:0: Attached scsi generic sg0 type 0
sd 0:0:1:0: [sdb] 160086528 512-byte hardware sectors: (81.9 GB/76.3 GiB)
sd 0:0:1:0: [sdb] Write Protect is off
sd 0:0:1:0: [sdb] Mode Sense: 00 3a 00 00
sd 0:0:1:0: [sdb] Write cache: enabled, read cache: enabled, doesn't support DPO or FUA
sd 0:0:1:0: [sdb] 160086528 512-byte hardware sectors: (81.9 GB/76.3 GiB)
sd 0:0:1:0: [sdb] Write Protect is off
sd 0:0:1:0: [sdb] Mode Sense: 00 3a 00 00
sd 0:0:1:0: [sdb] Write cache: enabled, read cache: enabled, doesn't support DPO or FUA
 sdb: sdb4
 sdb4: <bsd:bad subpartition - ignored
sd 0:0:1:0: [sdb] Attached SCSI disk
sd 0:0:1:0: Attached scsi generic sg1 type 0
sd 0:0:0:0: [sda] 78165360 512-byte hardware sectors: (40.0 GB/37.2 GiB)
sd 0:0:0:0: [sda] Write Protect is off
sd 0:0:0:0: [sda] Mode Sense: 00 3a 00 00
sd 0:0:0:0: [sda] Write cache: enabled, read cache: enabled, doesn't support DPO or FUA
sda: detected capacity change from 0 to 40020664320
sd 0:0:1:0: [sdb] 160086528 512-byte hardware sectors: (81.9 GB/76.3 GiB)
sd 0:0:1:0: [sdb] Write Protect is off
sd 0:0:1:0: [sdb] Mode Sense: 00 3a 00 00
sd 0:0:1:0: [sdb] Write cache: enabled, read cache: enabled, doesn't support DPO or FUA
sdb: detected capacity change from 0 to 81964302336
sd 0:0:0:0: [sda] 78165360 512-byte hardware sectors: (40.0 GB/37.2 GiB)
sd 0:0:0:0: [sda] Write Protect is off
sd 0:0:0:0: [sda] Mode Sense: 00 3a 00 00
sd 0:0:0:0: [sda] Write cache: enabled, read cache: enabled, doesn't support DPO or FUA
sda: detected capacity change from 0 to 40020664320
sd 0:0:1:0: [sdb] 160086528 512-byte hardware sectors: (81.9 GB/76.3 GiB)
sd 0:0:1:0: [sdb] Write Protect is off
sd 0:0:1:0: [sdb] Mode Sense: 00 3a 00 00
sd 0:0:1:0: [sdb] Write cache: enabled, read cache: enabled, doesn't support DPO or FUA
sdb: detected capacity change from 0 to 81964302336

I was able get this info before I stopped being able to boot:
Code:
ok lsdev

cd@0xff5c
disk@0xef78
disk0:   BIOS drive A:
disk1:   BIOS drive C:
disk1s1a:  FFS
disk1s1b:  FFS
disk1s1e:  FFS
disk1s1f:  FFS
disk1s1g:  FFS
disk2:   BIOS drive D:
disk2c:  FFS
pxe@0xd6ec
 
I'm thinking the easiest might be to use linux to mount the drives, copy the data off to some other drive, then reinstall FreeBSD with a 4.10 boot CD and restore the data via FTP/SCP/etc.

Linux should be able to mount FreeBSD filesystems.
 
Back
Top