VirtualBox + pfSense + Ubuntu - my experience
-
Hi,
i've been trying quite a few days till I got pfSense work in VirtualBox the way I needed. Here my experience report:
my config:
-
ubuntu 9.04
-
virtual box 2.2.4 from the sun repository (see http://www.virtualbox.org/wiki/Linux_Downloads )
my goals:
-
have pfSense working in VirtualBox for test purposes
-
thus, I wanted to be able to have a network connection from my host to the guest (pfSense)
configure a second ip address:
I wanted to be able to reach the guest machine (pfSense) from my host. So I added a second ip address to my adapter (thanks to Hartmut Funk for the tip): edit /etc/network/interfaces like:auto lo iface lo inet loopback auto eth0:1 iface eth0:1 inet static address 192.168.1.10 netmask 255.255.255.0
Prepare pfSense images
-
download the http://files.pfsense.org/mirror/downloads/pfSense-1.2.2-LiveCD-Installer.iso from pfSense
-
download the vmware image from here http://files.pfsense.org/vmware/pfSense-1.2.2-VM.zip
-
unzip it (produces pfSense-1.2.2-VM.vmdk)
-
if qemu is not available on your machine, then sudo apt-get install qemu
-
do: sudo qemu-img convert pfSense-1.2.2-VM/pfSense-1.2.2-VM.vmdk raw-file.bin
-
do: VBoxManage convertdd raw-file.bin PfSense.vdi
Configure VirtualBox
-
start VirtualBox
-
in the Virtual Media Manager, add a new disk using the PfSense.vdi created above
-
also add a new CD, pointing to the the LiveCD iso
-
create a new machine, using the disk above, and mounting the cd above
-
in the settings, configure the machine to use at least 2 network adapters, with the same config:
-
Adapter Type: PCNet-PCI II
-
Attached to: Bridged Adapter
-
Name: eth0
-
First startup
-
start the machine. It should boot from CD
-
say no to VLANs
-
for LAN/WAN, give le0 and le1
-
no optional interface
-
when at the menu, choose 8 (Shell)
-
do: fsck /dev/ad0s1a
-
shutdown the machine
Second startup
-
in Virtual Box, change the machine configuration so that it does no more mount the CD.
-
start the machine; it should boot from drive.
-
at some point, it stops and asks for boot device. enter ufs:/dev/ad0s1a
-
redo the configuration steps for pfSense
-
when at the pfSense menu, choose 8 again (Shell)
-
edit /etc/fstab (with e.g. vi) and correct both lines from …da0s1a to ...ad0s1a.
-
try to restart, it should work straight.
-
-
I am running a test also on Virtuabox..
But my host is a XP SP2 host , Guest (pfSense).
I create 2 NIC , 1 for bridge another 1 for host-only-network.
From Guest, i can ping my host Lan and Wireless IP only Host-ONly network is not working
But from Host , i can't even reach my guest ip for WAN and LAN(pfSense).Will you have any idea ?
-
I tried Ubuntu Karmic64 9.10 + virtualbox + pfsense 2.0 RC3.. I had no problems getting the host to talk to the guest(pfsense).. Also I was able to recieve and IP, from pfsense DHCP. I believe I used one of the PCNET adaptors in bridge mode.. I could also log into the pfsense console from the karmic host.
My only problem and I didn't have much of a chance to play around with it.. Was getting VLAN's to work.. I am doing this with only one NIC in the host.
Here's my attempted setup:
Pfsense Guest:
LAN = ln0
WAN = ln0_vlan99I have this connected to a Dlink switch that supports 802.1q.
This setup worked right out of the box…