FreeBSD 7.2 o/s on a flash stick

View: New views
3 Messages — Rating Filter:   Alert me  

FreeBSD 7.2 o/s on a flash stick

by Al Plant-2 :: Rate this Message:

Reply to Author | View Threaded | Show Only this Message

Aloha Gurus.

All the gogle-ing I did does not give a current status on or how-to on
installing FreeBSD 7.2 on a flash stick on one slice with the default
partions.  I want to boot from it on a mini lap top ( no CD ) and use it
like the hd inside.

I see plenty of how-to's on loading Flash sticks for installing on other
boxes and using a 2 slice flash to load FreeBSD onto other duplicate
boxes again.

All I need is to have a FreeBSD  o/s on the stick so I can use it
instead of the OS on the existing laptop.

I'm sure I saw on this list where somebody did this successfully but I
cant find it.

Any help is appreciated. Thanks.

~Al Plant - Honolulu, Hawaii -  Phone:  808-284-2740
   + http://hawaiidakine.com + http://freebsdinfo.org +
   + http://aloha50.net   - Supporting - FreeBSD 6.* - 7.* - 8.* +
   < email: noc@... >
"All that's really worth doing is what we do for others."- Lewis Carrol

_______________________________________________
freebsd-questions@... mailing list
http://lists.freebsd.org/mailman/listinfo/freebsd-questions
To unsubscribe, send any mail to "freebsd-questions-unsubscribe@..."

Re: FreeBSD 7.2 o/s on a flash stick

by Fbsd1 :: Rate this Message:

Reply to Author | View Threaded | Show Only this Message

Al Plant wrote:

> Aloha Gurus.
>
> All the gogle-ing I did does not give a current status on or how-to on
> installing FreeBSD 7.2 on a flash stick on one slice with the default
> partions.  I want to boot from it on a mini lap top ( no CD ) and use it
> like the hd inside.
>
> I see plenty of how-to's on loading Flash sticks for installing on other
> boxes and using a 2 slice flash to load FreeBSD onto other duplicate
> boxes again.
>
> All I need is to have a FreeBSD  o/s on the stick so I can use it
> instead of the OS on the existing laptop.
>
> I'm sure I saw on this list where somebody did this successfully but I
> cant find it.
>
> Any help is appreciated. Thanks.
>
> ~Al Plant - Honolulu, Hawaii -  Phone:  808-284-2740
>   + http://hawaiidakine.com + http://freebsdinfo.org +
>   + http://aloha50.net   - Supporting - FreeBSD 6.* - 7.* - 8.* +
>   < email: noc@... >
> "All that's really worth doing is what we do for others."- Lewis Carrol
>
> _______________________________________________
> freebsd-questions@... mailing list
> http://lists.freebsd.org/mailman/listinfo/freebsd-questions
> To unsubscribe, send any mail to
> "freebsd-questions-unsubscribe@..."
>
>
Hi Al

The way i have done this in 7.0 7.1 and 7.2 is to boot off the cd1
install cd and do a normal install to my 1gb flash stick. A 1gb flash
stick is to small for the default slice sizes. You will have to manually
allocate the / /usr /var /swap sizes. I also found it usefully to set
the boot flag when allocating the whole flash stick. A 2gb or larger
flash stick allows you to take the auto-allocate option for / /usr /var
/swap sizes. Keep in mind that your /var log files can fill up you flash
stick real quick and lock up your system. If your running this flash
stick 7/24 then rotate them more often deleting the oldest one. It's as
simple as that.
_______________________________________________
freebsd-questions@... mailing list
http://lists.freebsd.org/mailman/listinfo/freebsd-questions
To unsubscribe, send any mail to "freebsd-questions-unsubscribe@..."

Re: FreeBSD 7.2 o/s on a flash stick

by Morgan Wesström-7 :: Rate this Message:

Reply to Author | View Threaded | Show Only this Message

Fbsd1 wrote:

> Al Plant wrote:
>> Aloha Gurus.
>>
>> All the gogle-ing I did does not give a current status on or how-to on
>> installing FreeBSD 7.2 on a flash stick on one slice with the default
>> partions.  I want to boot from it on a mini lap top ( no CD ) and use
>> it like the hd inside.
>>
> Hi Al
>
> The way i have done this in 7.0 7.1 and 7.2 is to boot off the cd1
> install cd and do a normal install to my 1gb flash stick. A 1gb flash
> stick is to small for the default slice sizes. You will have to manually
> allocate the / /usr /var /swap sizes. I also found it usefully to set
> the boot flag when allocating the whole flash stick. A 2gb or larger
> flash stick allows you to take the auto-allocate option for / /usr /var
> /swap sizes. Keep in mind that your /var log files can fill up you flash
> stick real quick and lock up your system. If your running this flash
> stick 7/24 then rotate them more often deleting the oldest one. It's as
> simple as that.

I usually find it easier and faster to do this the manual way. You need
the DVD iso image with the live filesystem. Boot from it and enter the
fixit shell.

Create one bootable slice covering the whole USB-stick:
 # fdisk -BI /dev/da0

Create one bootable BSD partition covering the whole slice:
 # bsdlabel -B -w /dev/da0s1

Create the filesystem and give it a label you can refer to in fstab:
 # newfs -U -L FreeBSDonUSB /dev/da0s1a

Mount it:
 # mount /dev/da0s1a /mnt

Extract at a minimum base and the generic kernel:
 # DESTDIR=/mnt /dist/7.2-RELEASE/base/install.sh
 # DESTDIR=/mnt /dist/7.2-RELEASE/kernels/install.sh generic

Delete the empty default kernel directory and move the generic kernel
into its place:
 # rmdir /mnt/boot/kernel
 # mv /mnt/boot/GENERIC /mnt/boot/kernel

Create /etc/fstab:
 # echo '/dev/ufs/FreeBSDonUSB / ufs rw,noatime 1 1' > /mnt/etc/fstab

Load the necessary kernel module at boot:
 # echo 'geom_label_load="YES"' > /mnt/boot/loader.conf

Create /etc/rc.conf. Adjust and add to your own needs:
 # echo 'ifconfig_DEFAULT="DHCP"' > /mnt/etc/rc.conf
 # echo 'hostname="freebsd"' >> /mnt/etc/rc.conf
 # echo 'keymap="swedish.iso"' >> /mnt/etc/rc.conf
 # echo 'sshd_enable="YES"' >> /mnt/etc/rc.conf

Set the time zone:
 # cp /mnt/usr/share/zoneinfo/Europe/Stockholm /mnt/etc/localtime

Set the root password in the new environment:
 # chroot /mnt /bin/sh
 # passwd root
 # exit

Now exit SYSINSTALL and reboot. I hope I haven't missed anything. I
think geom_label is unnecessary in FreeBSD 7+ but it doesn't hurt. Also
remember that the displayed time is dependent on whether your computer's
CMOS clock is UTC or local time. Maybe someone has a nice trick to
correct for both options. Finally some credit to the guide I learned
this from:
http://typo.submonkey.net/articles/2006/04/13/installing-freebsd-on-usb-stick-episode-2
I actually do all my FreeBSD installs this way nowadays but I use
gmirror instead of the label.

Regards
Morgan Wesström
_______________________________________________
freebsd-questions@... mailing list
http://lists.freebsd.org/mailman/listinfo/freebsd-questions
To unsubscribe, send any mail to "freebsd-questions-unsubscribe@..."