Solved

Hyper V VM Running DHCP for multiple VLANs

Posted on 2015-01-12
9
471 Views
Last Modified: 2015-01-18
I am testing a Hyper V Guest config and here is the outcome that I need to achieve.

I have Server 2012 R2 running DHCP. The DHCP has two scopes configured on it: 192.168.1.x/24 for the data (untagged) VLAN and 10.0.1.x/24 for the voice (tagged) VLAN. I can get DHCP from the data VLAN but no requests are sent to the second scope as is the behavior of a physical DHCP server.

Server Config
One Virtual Network switch which run on a 2 NIC team
The VM DHCP sever has two virtual network adapter network adapters (I originally tried it on one NIC and could never get it working)
The physical switch (HP 1910-8G-POE for my lab) connecting to the server is using two ports, both configured as trunks with untagged data VLAN and tagged voice VLAN. The switch is running an IP helper to direct all secondary subnet clients to the DHCP server address.

Thus far I have tried everything I could find on the internet including adding a second virtual NIC in the server and tagging on and untagging the other then configuring the physical switch to match on it's trunk ports. I have also run the powershell command: Set-VMNetworkAdapterVlan -Trunk -VMName "MyVM" -AllowedVlandIdList "10" -NativeLandId 1

I can communicate on both VLAN from a client device on either subnet but the DHCP requests will not be answered on any VLAN other that the untagged VLAN. When I run the Powershell command listed above communication of both subnets stops altogether on the VM DHCP server.

Any thoughts from anyone on this? Has anyone encountered this and overcome it?
0
Comment
Question by:jamesl001
  • 4
  • 3
  • 2
9 Comments
 
LVL 45

Expert Comment

by:Craig Beck
ID: 40546406
You can do it 2 ways...

1] Put a NIC on the Voice VLAN
2] Use the primary NIC for both scopes and use  an IP helper on your router to forward DHCP requests to the IP of the server.

So, it sounds like you've done all that.

I'm guessing that you have an internet connection on the data VLAN and that you're using the switch to route between data and voice VLANs.  If so your problem is that your server doesn't know how to route to the voice VLAN.  Let's assume a single NIC approach... You'll need to add a static route to the server...

route -p add 192.168.1.0 mask 255.255.255.0 10.0.0.254

Open in new window


...where 192.168.1.0 mask 255.255.255.0 is the subnet of your voice VLAN and 10.0.0.254 is the IP of the switch on the data VLAN.
0
 

Author Comment

by:jamesl001
ID: 40546423
I will check the server routes. I do have the gateway on my server pointed to the switch which is acting as the router. That usually is all that is required on physical server systems. Thanks for the advice. I'll let you know.
0
 
LVL 38

Expert Comment

by:Aaron Tomosky
ID: 40547146
I agree with Craig, one nic and use iphelper. I have 8 vlans all getting dhcp from my VM dc with a single nic. I've never added a route or additional nic to make additional dhcp scopes work.

The switch does however need to have both networks added and routable. For a device to get dhcp on the voice vlan, it either needs to send tagged packets to the switch on the voice vlan or use a port set for untagged voice vlan.
0
 

Author Comment

by:jamesl001
ID: 40547199
The original setup was one NIC and a routable VLAN. I started doing other setups when this setup failed. The goal is:
One NIC
Two VLANs. Data VLAN untagged voice VLAN tagged
One DHCP server running two scopes
Switch port to hypervisor trunked: untagged data, tagged voice
Respective switch interface IP is the default gateway for all hosts including the VMs, phones, and client machines
IP helper is running on my switch for VLAN 10
Networks are 192.168.1.x/24 and 10.0.1.x/24

Am I missing anything in this setup??
0
VMware Disaster Recovery and Data Protection

In this expert guide, you’ll learn about the components of a Modern Data Center. You will use cases for the value-added capabilities of Veeam®, including combining backup and replication for VMware disaster recovery and using replication for data center migration.

 
LVL 45

Expert Comment

by:Craig Beck
ID: 40547550
Can you show switch port config for the server NIC?
0
 
LVL 38

Expert Comment

by:Aaron Tomosky
ID: 40547773
try this: make one port on the switch untagged voice vlan, plug in a laptop, see if it gets an ip. If so, the phones aren't tagging voice packets correctly.
0
 
LVL 45

Expert Comment

by:Craig Beck
ID: 40547792
...or the switch or server NIC isn't.  We really need to see switch port configs.
0
 

Accepted Solution

by:
jamesl001 earned 0 total points
ID: 40548102
Did a lot more testing today and narrowed down the root of the issue. For everyone's benefit... it was a misconfigured OUI on the voice vlan global settings on the HP 1910. I had put in 0080-0000-0000 as the OUI when in fact that config was literally  ONE "0" too many. The actual string needed to be 0800-0f00-000. Once I added this in the system work perfectly. This malformed OUI caused the device to miminck a bad DHCP server. Once I corrected this everything was fine.

Thanks to all who offered different views of the issue and solutions to bounce off for testing. I appreciate your participation.
0
 

Author Closing Comment

by:jamesl001
ID: 40556007
The solution was investigated and research and then practical lab experience applied to resolve the issue.
0

Featured Post

How to run any project with ease

Manage projects of all sizes how you want. Great for personal to-do lists, project milestones, team priorities and launch plans.
- Combine task lists, docs, spreadsheets, and chat in one
- View and edit from mobile/offline
- Cut down on emails

Join & Write a Comment

This is an article about my experiences with remote access to my clients (so that I may serve them) and eventually to my home office system via Radmin Remote Control. I have been using remote access for over 10 years and have been improving my metho…
ADCs have gained traction within the last decade, largely due to increased demand for legacy load balancing appliances to handle more advanced application delivery requirements and improve application performance.
This video gives you a great overview about bandwidth monitoring with SNMP and WMI with our network monitoring solution PRTG Network Monitor (https://www.paessler.com/prtg). If you're looking for how to monitor bandwidth using netflow or packet s…
In this tutorial you'll learn about bandwidth monitoring with flows and packet sniffing with our network monitoring solution PRTG Network Monitor (https://www.paessler.com/prtg). If you're interested in additional methods for monitoring bandwidt…

705 members asked questions and received personalized solutions in the past 7 days.

Join the community of 500,000 technology professionals and ask your questions.

Join & Ask a Question

Need Help in Real-Time?

Connect with top rated Experts

18 Experts available now in Live!

Get 1:1 Help Now