Go Premium for a chance to win a PS4. Enter to Win

x
  • Status: Solved
  • Priority: Medium
  • Security: Public
  • Views: 202
  • Last Modified:

How does DHCP server hand out IP addresses for IP Phones

In Cisco IP Telephony, If I understand there can be just one cable connecting the IP phone to the Switch and the PC needs  another cable to connect to the IP phone. I mean they are in 2 different Vlans, but connected to the same Switch Port.

I would like to know how DHCP hands Out IP  address to Voice and Data in this case.
Assuming in the topology below there is a Router (not shown in the topology)connected to L2 Switch(Switch B) and serves as DHCP server.
phones
Any help will be very much appreciated.

Thanks
0
jskfan
Asked:
jskfan
  • 6
  • 4
  • 3
  • +3
11 Solutions
 
Mohammed KhawajaCommented:
IP Phones will be on a separate VLAN of their own.  On your DHCP server, you will create a scope for your phones.  Refer to the IP phone manufacturer for setting up options 66 or 150 to specify the TFTP server IP address.
0
 
schapsCommented:
Many phone controllers can provide their own DHCP for the voice VLAN. Some prefer it. No reason not to use it. It makes troubleshooting problems somewhat easier when you can tell the vendor you're using their DHCP, not your own they have no control over.
0
 
Don JohnstonCommented:
Each device (phone & PC) is in a different VLAN.  The DHCP server has a scope (or pool) defined for each network (VLAN).  So the DHCP requests come from the network that the device is on.

Is that what you're asking?
0
VIDEO: THE CONCERTO CLOUD FOR HEALTHCARE

Modern healthcare requires a modern cloud. View this brief video to understand how the Concerto Cloud for Healthcare can help your organization.

 
jskfanAuthor Commented:
Assuming the same port on the switch is configured with Vlan 10 for Voice as well Vlan 50 for Data.
So the major work is done by the L2 switch, that categorizes each broadcast whether it is coming from the PC (Tag it with 50) if it is coming from the IP phone(tag it with 10). ???
I mean , the Switch got to have some kind of some kind capabilities to tell if broadcast is coming from the PC or IP phone
0
 
jskfanAuthor Commented:
In other words how does the L2 switch determines if DHCP broadcast is coming from the PC or IP phone, since both are plugged to the same Port switch ??? Then I believe the L2 Switch will forward the broadcast to the Router (configured as DHCP server)
0
 
phil435Commented:
CDP is used between the upstream switch and the phone to pass the voice vlan to the phone. The DHCP DORA then is passed to the voice vlan to get the IP address from the correct vlan. The PC will send its Dora request untagged which will be sent out the data vlan only. Hope this helps.
0
 
AkinsdNetwork AdministratorCommented:
A simple ip helper address configuration may help, that is, if I understand your goal correctly.

Switch(config)#int vlan 50
Switch(config-if)#ip helper-address x.x.x.x

Switch(config)#int vlan 10
Switch(config-if)#ip helper-address x.x.x.x
0
 
Don JohnstonCommented:
In other words how does the L2 switch determines if DHCP broadcast is coming from the PC or IP phone, since both are plugged to the same Port switch ???

Because the frames from the phone will be tagged as VLAN 10 and the frames from the PC will be untagged.  Since the native VLAN on that port will be VLAN 50, those frames will be flooded out VLAN 50 ports.
0
 
jskfanAuthor Commented:
Since the native VLAN on that port will be VLAN 50, those frames will be flooded out VLAN 50 ports.
-Why VLAN 50 will be native vlan, if we do not manually make it native.? by default vlan1 is the native.
-Why frames from the phone will be tagged and from the PC will be untagged ?
0
 
phil435Commented:
In your upstream l2 you defined a voice vlan and then defined the access port for data. This is what CDP passes to the phone which is a switch as well and it knows to tag the voice vlan. The switchport that has the PC plugged into will be the data vlan which will be untagged. All untagged frames will be be part of the data vlan that you defined when using switchport access vlan x.
0
 
Don JohnstonCommented:
Because when you setup a switchport for a phone with the ability to hang a PC off of it, you will either use the voice VLAN command or manually define the trunk to tag the voice VLAN as 10 and make the data VLAN 50.

Whichever way you do it, you will have a trunk port with two VLANs: voice VLAN tagged, data VLAN untagged.
0
 
AkinsdNetwork AdministratorCommented:
IP Phones have the ability to tag their own packets because you can specify vlan assignments on the phones, but computers don't. PCs rely on either a native vlan or the vlan assignment on the port they connect to

If the switchport connection is a trunk port, and your PCs are connected to the phones, then you'll have to make your native vlan the vlan the PCs are in which will be vlan 50. This is not recommended though for security purposes. You always should make your native vlan a "blackhole" (goes nowhere).

If the switchport is an access port, and your PCs are connected to the phones, then you'll have to configure voice vlan as 20, and normal vlan assignment on that port as 50
eg
Switch(config)#int fa0/1
Switch(config-if)#switchport access vlan 50
Switch(config-if)#switchport voice vlan 10
0
 
jskfanAuthor Commented:
Switch(config-if)#Switchport [b]access[/b] vlan 50
Switch(config-if)#switchport [b]voice[/b] vlan 10

Open in new window


OK ..
--the Keyword voice makes the incoming traffic to the port tagged.
--the Keyword access makes the incoming traffic to the port untagged
 what about native vlan ? does the access keyword make the port native vlan ?
0
 
AkinsdNetwork AdministratorCommented:
Switch(config-if)#switchport trunk native vlan ??
0
 
jskfanAuthor Commented:
Akinsd
switchport access native vlan ??

so it has to be entered manually otherwise, by default Vlan 1 will be the native vlan
0
 
AkinsdNetwork AdministratorCommented:
Switch(config-if)#switchport trunk native vlan ??

Correct
For security reasons however, like I mentioned earlier, you're better off sticking with the access and voice vlan configuration. Configure IP Helper-address instead to direct dhcp queries to your dhcp server.

Any intruding device plugged into your switchport will automatically gain access to your network if the native vlan is an active vlan.
0
 
phil435Commented:
If you use switchport voice vlan and switchport access vlan then you don't need to worry about using the native command. This is all handled for you by the switch.
0
 
jskfanAuthor Commented:
Thank you Guys!
0

Featured Post

Windows Server 2016: All you need to know

Learn about Hyper-V features that increase functionality and usability of Microsoft Windows Server 2016. Also, throughout this eBook, you’ll find some basic PowerShell examples that will help you leverage the scripts in your environments!

  • 6
  • 4
  • 3
  • +3
Tackle projects and never again get stuck behind a technical roadblock.
Join Now