Friday, January 25, 2013

Install pfsense to an usb drive

Nanobsd was created to make Freebsd suitable for installing on embedded systems, specifically on flash media.
Flash media has a limited number of write cycles and a standard install can burn through them quickly resulting in drive failure.

Nanobsd avoids this by logging to ram only and mounting the file system read only (among other tweaks).
Because of this some packages cannot work. Most have been adapted to work, for example it's possible to run squid without the cache just as a web filter.


Download embedded builds image 4G with VGA output from:

Writing the image
When using a windows machine the easiest way to write your media is with physdiskwrite.
Place physdiskwrite and the pfSense image in the same folder. Attach the media you want to store pfSense on (i.e. CF-Reader and CF-Card).

Physdiskwrite will show you a numbered list of suitable devices (USB-stick, CF-cards in USB-readers, harddisks,...). Enter the number of the desired media.
physdiskwrite v0.5.2 by Manuel Kasper

Usage: physdiskwrite [-u] [-d driveno]

-u remove 2 GB restriction (WARNING!)
-d specify drive number (0..n) (no confirmation prompts!)

X:DownloadspfSense>physdiskwrite.exe -u pfSense-2.0.2-RELEASE-4g-i386-nanobsd_vga.img.gz

physdiskwrite v0.5.2 by Manuel Kasper

Searching for physical drives...

Information for .PhysicalDrive0:
Windows: cyl: 29185
tpc: 255
spt: 63
C/H/S: 16383/16/63
Serial number: CVKI2455002X240DGN
Firmware rev.: 335t

Information for .PhysicalDrive1:
Windows: cyl: 91201
tpc: 255
spt: 63
C/H/S: 16383/16/63
Model: ST9750420AS
Serial number: 6WS17Q68
Firmware rev.: 0002DEM1

Information for .PhysicalDrive2:
Windows: cyl: 486
tpc: 255
spt: 63

Which disk do you want to write? (0..2) 2
WARNING: that disk is larger than 2 GB! Make sure you're not accidentally
overwriting your primary hard disk! Proceeding on your own risk...
About to overwrite the contents of disk 2 with new data. Proceed? (y/n) y
Found compressed image file
3989970432/3989970432 bytes written in total



  1. Thanks for sharing your info. I really appreciate your efforts and I
    will be waiting for your next write ups thank you once again.

  2. I love your blog.. very nice colors & theme. Did
    you create this website yourself or did
    you hire someone to do it for you? Plz respond as I'm looking to construct my own blog and
    would like to know where u got this from.

    thanks a lot

  3. Good respond in return of this difficulty with genuine arguments
    and telling everything concerning that.

  4. After looking into a number of the blog articles on your
    blog, I honestly appreciate your way of writing
    a blog. I book-marked it to my bookmark webpage list and will be checking back soon. Please visit my website as well
    and let me know what you think.

  5. Thank you almost every other amazing write-up. The place different may any one obtain that form of details in this the best approach regarding composing? I've a presentation up coming 7 days, and I'm within the look for similarly info.