Go Back   Hardware Canucks > SOFTWARE > Networking

    
Reply
 
LinkBack Thread Tools Display Modes
  #11 (permalink)  
Old November 7, 2012, 03:49 PM
lowfat's Avatar
Moderator
 
Join Date: Feb 2007
Location: Grande Prairie, AB
Posts: 7,955

My System Specs

Default

Quote:
Originally Posted by botat29 View Post
When you use VM, you have 3 choices for your virtual network,

NAT; it will share the same NIC as the HOST PC,
Bridged ; the NIC will be use only by the VM
Internal: not usefull here

NIC 1 ( bridge ) ; use by PFsence in the VM to connect to the WAN, example a cable modem
NIC 2 ( bridge) ; use by PFsence to connect to your switch
NIC 3 ; use to connect the host to the switch



with this setup it's like if you are using PfSense in a dedicated PC , depending o the VM hypervisor it can be very hard to make your PCs on the network communicate with Pfsense if you are using NAT


here a small drawing, the VM is represented as a smaller pc inside the host
Thanks for adding the pic. Honestly this way seems the easiest to me. I have room for my NICs in my rig so I'll probably end up just doing this. I'd rather not have to use ESXi, which I have no experience with. I also use the server as my backup machine so I'd rather not be running it in a VM all the time.

Quote:
Originally Posted by Ardric View Post
Seems pretty straightforward. NIC #1 is assigned exclusively to the pfsense VM and is used as the WAN connection to the cable modem. NIC #2 is bridged with the pfsense VM and this bridge is the LAN. pfsense can number itself as the gateway IP on the LAN bridge, and the host can number itself on the "physical" NIC #2 as another LAN host. NIC #2 is then connected to a LAN switch for any other LAN clients that want to join in. There's no need for a 3rd NIC at all. Just a software-only bridge on the LAN side.
VirtualBox can't get exclusive control over NIC1 (WAN) though, maybe because I don't have Vt-d?

I've tried turning off IPv4 for the NIC1 in Windows, however I lose internet on the host machine. Everything connected to the switch on NIC2 still has internet. I am also still able to connect to my internet network from the host. Just no internet. It more than likely is a setting issue somewhere in VirtualBox or pfsense, but I haven't been able to figure it out.
Reply With Quote
  #12 (permalink)  
Old November 7, 2012, 03:55 PM
Top Prospect
 
Join Date: Apr 2010
Location: East Van
Posts: 50

My System Specs

Default

Quote:
Originally Posted by lowfat View Post
VirtualBox can't get exclusive control over NIC1 (WAN) though, maybe because I don't have Vt-d?
I see. Forgive my ignorance, I'm more of a VMware guy. Ok, non-exclusive control should be ok, turning off IP on the host and still bridging the outside NIC to the pfsense outside virtual NIC.

Quote:
I've tried turning off IPv4 for the NIC1 in Windows, however I lose internet on the host machine. Everything connected to the switch on NIC2 still has internet. I am also still able to connect to my internet network from the host. Just no internet. It more than likely is a setting issue somewhere in VirtualBox or pfsense, but I haven't been able to figure it out.
At this point you need to assign the host machine a private IP address on NIC2, and use the IP of pfsense on NIC2 as the default gateway. Then the host will route through pfsense to get to the Internet, same as the rest of the LAN clients.

The 3rd NIC method will work fine too, I'm just trying to save you the hassle since I don't think it's necessary.
Reply With Quote
  #13 (permalink)  
Old November 7, 2012, 04:17 PM
lowfat's Avatar
Moderator
 
Join Date: Feb 2007
Location: Grande Prairie, AB
Posts: 7,955

My System Specs

Default

OMG I am such an idiot. Sometime this morning I had turned off IPv4 on the host WAN while troubleshooting. I assumed I had turned it back on, but I didn't. Internet has been working on the host machine through pfsense all day and I never even realized.

This thread fixed my issues without me even knowing.
Reply With Quote
  #14 (permalink)  
Old November 8, 2012, 09:42 PM
BrainEater's Avatar
Hall Of Fame
 
Join Date: Mar 2007
Location: Calgary
Posts: 2,510
Default

Glad you got it working !

So ok , explain why you are doing PFsense on a VM ?

Listen....I have a p3 here somewhere and some nics that will last a hundred years as a PF rig.I'll give em to yah
__________________
Intel 3930k /rIVe/32 Gb vengeance LP/Nvidia TITAN/760/760/Intel 520's/WD raptors/etc...
Reply With Quote
  #15 (permalink)  
Old November 9, 2012, 03:43 PM
lowfat's Avatar
Moderator
 
Join Date: Feb 2007
Location: Grande Prairie, AB
Posts: 7,955

My System Specs

Default

I am trying to simply the amount of computer I have. Not sure I'll keep it in a VM though. I've already have to rebuild the VM from scratch as yesterday for some reason internet quit working on all devices.

Still haven't been able to get OpenVPN working properly unfortunately.

EDIT: Got the VPN working now too.

Last edited by lowfat; November 10, 2012 at 09:43 AM.
Reply With Quote
  #16 (permalink)  
Old November 10, 2012, 05:12 PM
BrainEater's Avatar
Hall Of Fame
 
Join Date: Mar 2007
Location: Calgary
Posts: 2,510
Default

That's cool !

I've never considered running a PF router as a VM.Interesting.

I'm 25 hours from the service of my pf rig.This will be 70 thousand hours uptime.

__________________
Intel 3930k /rIVe/32 Gb vengeance LP/Nvidia TITAN/760/760/Intel 520's/WD raptors/etc...
Reply With Quote
  #17 (permalink)  
Old November 13, 2012, 07:06 AM
odis172's Avatar
Allstar
F@H
 
Join Date: Oct 2008
Location: Ottawa, ON
Posts: 683

My System Specs

Default

I'm running pfsense in a vm on esxi, so I'd like to chime in here, but it seems you all have it covered. One thing I would add though, is if you are running pfsense as a vm on top of an OS, disable all protocols on the adapter you using for the WAN connection - except vmware bridge. You don't want any tcp/ip packets going to the host OS from the WAN connection, only to the vm. The VMware protocol will send anything coming in to the VM.
__________________
Laptop: Lenovo T420 - Core i5 2520 - 8GB DDR3
Server: 2 xeon E5530 - Asus Z8N-D6 - 12GB DDR3 - 8x 500GB raid 50 - Perc 6/i - Compucase RA448A00
Reply With Quote
Reply


Thread Tools
Display Modes

Similar Threads
Thread Thread Starter Forum Replies Last Post
is there a virtual machine that supports more then 8 cores? Shadowmeph O/S's, Drivers & General Software 6 April 19, 2012 07:12 AM
PFsense on RSA appliance lcdguy Networking 5 July 7, 2011 07:24 PM
pfSense, FreeNAS and SABnzbd+ in one box ADay2Long New Builds 12 April 21, 2011 03:12 PM
YOu are using VM ( Virtual Machine) for ? botat29 O/S's, Drivers & General Software 6 April 3, 2011 01:16 PM
WinSMP MPICH vs Virtual Machine Dwayne HardwareCanucks F@H Team 5 April 12, 2009 09:45 AM