VMware Horizon Community
djak44
Enthusiast
Enthusiast

One DHCP server and few subnets

I have attached a diagram, maybe the diagram can state the issue better, please have a look at the attached, my question is: how does the DHCP server distinguish between Computer A and Computer B when assigning IP addresses? or how can computer A gets the right IP from the right scope?

Thank you.

Djak44

0 Kudos
9 Replies
orthohin
Enthusiast
Enthusiast

djak44 wrote:

I have attached a diagram, maybe the diagram can state the issue better, please have a look at the attached, my question is: how does the DHCP server distinguish between Computer A and Computer B when assigning IP addresses? or how can computer A gets the right IP from the right scope?

Thank you.

Djak44

To distinguish between Computer A and Computer B you have to configure the switch port. Suppose you switchport f 0/10 is VLAN 11 then you have configure port f 0/10 as a access port with access VLAN 11. Have fun..

Regards,
Milton

Never trust a computer you can't throw out a window
djak44
Enthusiast
Enthusiast

Thank you for your reply, I have all that configured, Computer A port is a VLAN 10 tag and B is VLAN 20, this is all fine, when the guest send a DHCP request to the server with the help of the DHCP helper on the switch/router, when it arrives to the server, the server will need to assign an IP to it, the question what is there for the server to tell it to assign an IP from a specific pool? Is there anything on the server that needs to be bound to somekind of an interface (virtual) for each LAN segment?

Thank you.

Djak44

0 Kudos
Camek
Enthusiast
Enthusiast

othohin -  Your response would be true if you only wanted one VLAN to appear to your ESXi servers.  Instead what you need to do is configure the network ports which are being used with the ESXi server running View to support "trunks" and not "access" VLANs.  If you wanted to have say VLAN 10,11,12 visable to the ESXi server you would setup the trunk on all the ports used by the servers and allow all 3 vlans.  Now in ESXi under "Network" configuration you would add a "Vitrual Machine" for each of the 3 VLAN, one for each of the vlan you setup above.   Now when you setup our desktop image for View make sure on it's network configuation that you select the proper Vitural Machine and it and any replicans from that image will now be attached to the selected VLAN.   If you want images running on more VLAN than you must have an image for each VLAN.

To avoid this issue what we do is have one VLAN which is dedicated to View then all desktops being use in View have he same VLAN.  This helps us too because now we know which user is View user and which one in "local" in the building just base on the IP address.

djak44
Enthusiast
Enthusiast

Thank you for your note, you are right regarding the trunk, but if you do have one DHCP server all the requests from different VLANs will eventually make it to the DHCP server using DHCP helper, how does the server supply IP addresses from different scopes to the right view nodes? knowing that the requests will be tagged with VLAN IDs from the helper.

Thank you.

Djak44

0 Kudos
Camek
Enthusiast
Enthusiast

As you say the scope is determined by the VLAN which is tagged on the network traffic.  First, let's look at ESXi. To have different virtual machines use different VLAN you have first go into the Configuration > Networking and make sure your "VirtualSwitch" is setup so that it has more than one "Virtual Machine" (this goes back to conversations about trunking on the physical network).  In our case lets say we have one Virtual Machine in our Virtual Switch named  "TEST" which is assigned a VLAN ID of 10  and other "PROD" which is assigned a VLAN ID of 11.   Now we go to any of our virtual machines on our ESXi server and change the Network Adapter > Network Connection Label settings to use either the TEST or PROD and depending on which it is set to the network interface on the ESXi server will "tags" the traffic with the VLAN you have setup in your Virtual Network and it will get passed across the network to the DHCP server (via helper) to get an IP address.

Same thing happends in View.....  When you setup your Desktop pool you will select a Default Image to use from your ESXi servers and when View generates desktops in the pool the network setting you had in the Default Image will be cloned to very desktop in the pool and which Vitrual Switch is being used and hence which VLAN is "TAGGED".   If you need a different vlan tagged on the desktops in a pool you must then use a different default image with the proper network settings.

Hope this helps but check out what "VLAN ID" you have setup on your Vitrual Swtichs in ESXi and I think it should fall into place for you.

0 Kudos
djak44
Enthusiast
Enthusiast

I understand what you are saying but if you already have the only DHCP server in production and you want your proof of concept View VMs to get an ip range that is different from the production, then I will setup another scope on the DHCP server (superscope?) and here is the missing step:....something needs to be setup within the DHCP server to make it distinguish between the two subnets: Production and Test. So is there a way of binding the second scope (View) to a port group (NIC) so when a View VM boots up it will reach the DHCP server as you said using the portgroup assigned to the parent image and get an IP address different from the production. Maybe I am just paranoid, I should just increase the existing scope and let everything on the same IP range:).

Thank you.

Regards

Djak44

0 Kudos
Camek
Enthusiast
Enthusiast

Do you have any VLANs setup on your network and do you have routing setup between them?  If not you need to start at that basic level and then the rest will start making sense.... 

0 Kudos
orthohin
Enthusiast
Enthusiast

Camek wrote:

othohin -  Your response would be true if you only wanted one VLAN to appear to your ESXi servers.  Instead what you need to do is configure the network ports which are being used with the ESXi server running View to support "trunks" and not "access" VLANs.  If you wanted to have say VLAN 10,11,12 visable to the ESXi server you would setup the trunk on all the ports used by the servers and allow all 3 vlans.  Now in ESXi under "Network" configuration you would add a "Vitrual Machine" for each of the 3 VLAN, one for each of the vlan you setup above.  Now when you setup our desktop image for View make sure on it's network configuation that you select the proper Vitural Machine and it and any replicans from that image will now be attached to the selected VLAN.  If you want images running on more VLAN than you must have an image for each VLAN.

To avoid this issue what we do is have one VLAN which is dedicated to View then all desktops being use in View have he same VLAN.  This helps us too because now we know which user is View user and which one in "local" in the building just base on the IP address.

hi  Camek,

If you see the attachment file you will understand the matter. It's not a tranking or VLAN routing issue. It's about differentiate the DHCP server according the VLAN. So no need to trund or VLAN routing!!!!!!!!!!!

Orthohin
Never trust a computer you can't throw out a window
0 Kudos
Camek
Enthusiast
Enthusiast

Othohin -- for ESXi to commuinate with more than one VLAN it will work tons better if you just send more than one than VLAN (via a trunk port) to all ports on the ESXi server.  Then use VMWare built in abilty to set tagging on each server to send it to the proper VLAN.

0 Kudos