[FreeBSD] USB Install - BSD
Users browsing this thread: 1 Guest(s)
|
|||
USB Install or expert install.
After reading this thread you should know how to install FreeBSD to USB. I run these commands on FreeBSD. What you need : - USB - FreeBSD cd | FreeBSD iso | FreeBSD archives (ftp://ftp.freebsd.org/pub/FreeBSD/releases/) \_ You need at least kernel.txz and base.txz. \_ How to find the packages in FreeBSD iso/cd ? It's in $CD/usr/freebsd-dist/ - Plug in you USB key, a quick look at /var/log/messages should show something like this: (you can use `tail -f /var/log/messages) PHP Code: Jun 8 20:33:30 home kernel: ugen4.2: <USB> at usbus4 - Erase the disk with dd, this should take a few minutes. \_ dd if=/dev/zero of=/dev/da0 count=560 bs=2m - Create the geom and partitions: \_gpart create -s gpt da0 # Create the geom. \_gpart add -s 64K -t freebsd-boot da0 # add the bot partition, 64K should be enough. \_gpart add -s 100M -t freebsd-swap -l swap0 da0 # add the swap partition. I recommend 5-10% of the disk size. \_gpart add -t freebsd-ufs -l disk0 da0 # add the root ufs partition. it will use all the space left. \_newfs -UJt -L freebsdusb /dev/da0p3 # enabling soft-updates and journaling. You can use -t if you want trim (ssd). - Verify everything is correct \_gpart show da0 PHP Code: => 34 15663037 da0 GPT (7.5G) - Mount the root partition \_mount /dev/da0p3 /mnt/usb - Extract at least kernel.txz and base.txz in / on your usb, ilke this: \_ cd /mnt/usb/ \_ tar -xf $packagespath/kernel.txz; tar -xf $packagespath/base.txz - Add the bootcode to your usb installation: \_gpart bootcode -b /boot/pmbr -p /boot/gptboot -i 1 da0 - Edit the fstab in /mnt/usb/etc/fstab, add: \_ PHP Code: /dev/da0p3 / ufs rw,async 1 1 - You can now boot with the USB key to try ! - If you get errors like "permission denied" when running as root, run this: \_sysctl kern.geom.debugflags=16 |
|||
Messages In This Thread |
[FreeBSD] USB Install - by yrmt - 22-07-2012, 07:32 PM
RE: [FreeBSD] USB Install - by FreeBSD - 03-09-2012, 10:38 PM
RE: [FreeBSD] USB Install - by yrmt - 23-12-2012, 02:37 AM
RE: [FreeBSD] USB Install - by zygotb - 29-12-2012, 08:52 PM
RE: [FreeBSD] USB Install - by yrmt - 30-12-2012, 05:10 AM
RE: [FreeBSD] USB Install - by zygotb - 06-01-2013, 04:22 PM
|