Re: installing from a harddisk prepared in a functional system



On Tue, Dec 05, 2006 at 08:03:56PM -0700, Steve Franks wrote:

How does one make a 'boot' disk - be it cdrom, harddrive or flash
(presuming your bios will boot from all those devices, of course)?

1.The handbook specifies you need to minimally copy the /bin folder to
the destination.
2. Obviously you want a valid ufs2 partition.
3. I've repeatedly tried setting the 'bootable' option in fdisk, and
the 'A' appears next to the slice, but everytime I reboot it
dissappears, even after a 'W' command, so I'm going to try to get this
to go without using sysinstall by a manual copy, if I can.
4. Windows partitions need some special files, i.e. ntldr, at a
special location on the boot partiton - equivalent in bsd? Or does the
loader just look for /bin and load the kernel from there?
5. bootloader seems to work when I put the disk in the new computer -
get F1 and F2, but nothing else happens.

Basically I'm trying to make an 'image' - put a fresh disk in my
working system, format it, make it boot, at least to sysinstall, so I
can put it in my other system that has no floppy or cdrom to install
from, and get things rolling over the network card. I was thinking I
could just do this with a single partition on the target disk, like
the install cdrom's do. I want to turn a harddisk into an install
cdrom, and then have it install to itself, a dangerous idea, no doubt,
but it appears that it could work, I just can't get the new disk to
boot in the new system.

If I understand you, you are trying to install enough of FreeBSD on a disk
that you will then move to another machine to finish the install???

First of all, why don't you just do the complete install on the
disk rather than just a part of it.

Second, did you write the MBR to the disk? I would suggest this:
dd if=/dev/zero of=/dev/da1 bs=512 count=32
fdisk -BI da1
That first dd just makes sure no previous junk on the disk gets in the way.

The fdisk command writes two main things: The primary slice table
and the MBR. But, it does not put the boot sector there. That
is done with bsdlabel.

bsdlabel -w -B da1s1 will do it

Then, you have to divide that slice you made in the fdisk command
into at least one partition - probably several.
FreeBSD doesn't boot to the slice, but rather needs a real partition
that has been made in to a file system and had needed files written on it.

For that you again use bsdlabel. The easiest is to use it in edit mode:

bsdlabel -e da0s1

That puts you in an edit session to edit the partition table for the slice.
Edit it as you prefer. I posted a long response yesterday that gives
a good example.

Then, you should install all of what goes in root and preferably also
what goes in /usr before trying to boot.

You can do all this through sysinstall and if you really must only
partially install, then just get really selective on what you tell
it to install rather than just take the general/normal installation.

But, as I said above, just do the whole install at this time.
The only thing you might come out funny on are the device names
it puts in /etc/fstab. In might name them da1 or ad1 instead of
the da0 or ad0 you need when you move the disk over to the other
machine. So, mount up the newroot (on the new disk) and check out
the /newroot/etc/fstab file and edit if necessary before moving
the disk over.

////jerry



Thanks,
Steve

--
Steve Franks, KE7BTE
Staff Engineer
La Palma Devices, LLC
http://www.lapalmadevices.com
(520) 312-0089
_______________________________________________
freebsd-questions@xxxxxxxxxxx mailing list
http://lists.freebsd.org/mailman/listinfo/freebsd-questions
To unsubscribe, send any mail to "freebsd-questions-unsubscribe@xxxxxxxxxxx"
_______________________________________________
freebsd-questions@xxxxxxxxxxx mailing list
http://lists.freebsd.org/mailman/listinfo/freebsd-questions
To unsubscribe, send any mail to "freebsd-questions-unsubscribe@xxxxxxxxxxx"



Relevant Pages

  • Windows on Mac - how to.
    ... No-nonsense instructions for those "in the know". ... A custom slipstreamed CD is required to install XP on a Mac. ... This procedure WILL WIPE YOUR iMAC DISK CLEAN. ... Partition the disk in two using the OSX CD: ...
    (uk.comp.sys.mac)
  • SUMMARY: Moving /usr From Under Root "/" To Its Own Partition
    ... One of the reasons for doing this is to end up with a smaller root ... Install the boot block and boot off the new drive. ... " In order for the root partition to be fscked and remounted ... D> temporarily on the existing disk. ...
    (SunManagers)
  • Re: xp on intel Mac from usb stick?
    ... Would it be possible to run windows xp native from a usb stick? ... A custom slipstreamed CD is required to install XP on a Mac. ... partition managers but if you're feeling adventurous you may ... This procedure WILL WIPE YOUR iMAC DISK CLEAN. ...
    (comp.sys.mac.apps)
  • Re: Dual booting
    ... I am installing Server 2003 in a new partition and use the NTLDR to boot my OSes. ... You can, of course, install Windows Server on any of your spare ... install any OS or XOSL on the storage disk, ...
    (microsoft.public.windowsxp.general)
  • Re: Dual Boot Instructions
    ... I ended up reinstalling Vista, ... The boot SECTOR is not the bootLOADER. ... finds the partition table for that HDD and sees that the first partition is ... violated, we no longer can simply install WinXP, install Vista and ...
    (microsoft.public.windows.vista.hardware_devices)