# Booting problem with mini FreeBSD



## anti (Apr 16, 2010)

Hi

i have compiled mini FreeBSD without removing any features and i copy it in a compact flash memory using dd.
and i traying to boot it on SOEKRIS board, but there is no response to any thing, mini BSD does not start to boot

any idea?


----------



## SirDice (Apr 16, 2010)

Not enough info. How and what exactly did you copy using dd?


----------



## anti (Apr 16, 2010)

i did copy the compiled mini Freebsd system (.hardisk)
i mean just i put the compiled OS in the compact flash to boot it on soekris board
compack flash acts the hardisk of soekris


----------



## bschmidt (Apr 16, 2010)

Did you get the C/H/S information right? This is real tricky part.. Have a look at tools/tools/nanobsd/nanobsd.sh for way on how to do it correctly.


----------



## anti (Apr 17, 2010)

Hi bschmidt
I don't know what do you mean by C/H/S .. can you please provide me with more information


----------



## bschmidt (Apr 17, 2010)

anti said:
			
		

> Hi bschmidt
> I don't know what do you mean by C/H/S .. can you please provide me with more information



I'm talking about about the cylinder, head and sector sizes of the disk. For example the CF card on an ALIX board might look like this:

```
meshnode# diskinfo -v ad0
ad0
        512             # sectorsize
        509386752       # mediasize in bytes (486M)
        994896          # mediasize in sectors
        0               # stripesize
        0               # stripeoffset
        987             # Cylinders according to firmware.
        16              # Heads according to firmware.
        63              # Sectors according to firmware.
        20090603 00007ABA       # Disk ident.
```

If you plug the same card into a CF reader, it might look totally different (eg. 62 sectors). If you use `# fdisk` with false information, you won't be able to boot.

Usually, one can fix this by creating an md(4) image of same size as the CF card, and use `# mdconfig` to pass the cylinders/track and heads/cylinder information of the target system. This way, you get an image which you can `# dd` to the cf card, now matter how wrong C/H/S is.

HTH


----------



## embeddedbob (Apr 21, 2010)

As youre using a SOEKRIS board with serial console (and no vga?), have you checked that the first bootloader is /boot/boot0sio and not /boot/boot0. I dont know about minibsd but the first set of "I get nothing" problems with nanobsd was all todo with the first boot stage. 

http://www.freebsd.org/cgi/man.cgi?...ion=0&manpath=FreeBSD+8.0-RELEASE&format=html 

Ive had loads of problems with bsd on a CF card not booting, getting there....
http://forums.freebsd.org/showthread.php?p=78831#post78831


----------

