Netgate Discussion Forum
    • Categories
    • Recent
    • Tags
    • Popular
    • Users
    • Search
    • Register
    • Login

    Hyper-V NIC to PFsense

    Scheduled Pinned Locked Moved Hardware
    4 Posts 2 Posters 3.1k Views
    Loading More Posts
    • Oldest to Newest
    • Newest to Oldest
    • Most Votes
    Reply
    • Reply as topic
    Log in to reply
    This topic has been deleted. Only users with topic management privileges can see it.
    • T
      tunge2
      last edited by

      I have a fysical pc with two NICS.
      I have installed Microsoft WIndows 2012 R2 Hyper-V version on the pc. Windows recognizes both NICS
      I have installed the last version of PFsense as VM
      I have made both network NICS available for the Pfsense VM machine

      I have a Internet Provider that asigns only one DHCP Public IP adres.

      The strange thing is that the public IP adres is awarded to the Windows 2012 R2 NIC and not awarded to the VM pfsense machine?
      If i login directly to the Hyper-V host machine Internet is working. But the WAN IPadres from the VM (pfsense) stays empty….........

      I have tryed to set the NICS in Hyper-V to Public/Internal/External but nothing is working.......Help....

      1 Reply Last reply Reply Quote 0
      • D
        dreamslacker
        last edited by

        You have 2 NICs, 1 should be assigned for use with pfSense VM only for WAN.

        Your Hyper-V server should ride behind pfSense's LAN interface.

        To do this determine which pNIC is use for WAN.

        On this pNIC, setup an external vSwitch - make sure that the option for 'Host management OS to use this vSwitch' is NOT checked. This ensures that no Hyper-V virtual adapters are attached to this vSwitch (which will hijack the WAN DHCP IP).

        On the 2nd pNIC, setup the external Switch but check the option for Host Management OS to use the vSwitch. This creates a vNIC for the host OS which you will use for LAN.
        If you intend to use VLANs on the physical link to the switch, go ahead and add the VLAN ID for the host OS in the vSwitch manager menu.

        If you are using VLANs to get multi-LAN on pfSense, setup multiple vNICs for the VM with individual VLAN IDs and attach them to the vSwitch connected to the 'LAN' pNIC. Let Hyper-V vSwitch handle the VLAN tagging, pfSense will just see a regular NIC for each interface.

        1 Reply Last reply Reply Quote 0
        • T
          tunge2
          last edited by

          @dreamslacker:

          You have 2 NICs, 1 should be assigned for use with pfSense VM only for WAN.

          Your Hyper-V server should ride behind pfSense's LAN interface.

          To do this determine which pNIC is use for WAN.

          On this pNIC, setup an external vSwitch - make sure that the option for 'Host management OS to use this vSwitch' is NOT checked. This ensures that no Hyper-V virtual adapters are attached to this vSwitch (which will hijack the WAN DHCP IP). If i do that the NIC is not vissible any more on the Hyper-V machine (not PFsense VM) when run the command ipconfig. –>but thats correct?

          If i understand it correctly the thing that I'am doning wrong is  the checkbox 'Host management OS to use this vSwitch'  :)

          On the 2nd pNIC, setup the external Switch but check the option for Host Management OS to use the vSwitch. This creates a vNIC for the host OS which you will use for LAN.
          If you intend to use VLANs on the physical link to the switch, go ahead and add the VLAN ID for the host OS in the vSwitch manager menu. Iám not using vlan's :)

          1 Reply Last reply Reply Quote 0
          • D
            dreamslacker
            last edited by

            Yes, once you stop the Host management OS from using the vSwitch, the Hyper-V host/ machine no longer has access to that pNIC. That's what you want in order to stop the host from hijacking the IP; and more importantly, to prevent it from being directly exposed to the internet.

            1 Reply Last reply Reply Quote 0
            • First post
              Last post
            Copyright 2025 Rubicon Communications LLC (Netgate). All rights reserved.