cancel
Showing results for 
Search instead for 
Did you mean: 
cancel
4396
Views
0
Helpful
4
Replies

Data+Voice vlan configured on a switchport

Marc_AMI1
Level 1
Level 1

Hi guys, 

 

I have a Cisco switch configured with two vlans : 

VLAN 10 : Voice

VLAN 20 : DATA

 

My switch ports are configured as shown below : 

interface GigabitEthernet1/0/X

switchport mode access

switchport access vlan 20

switchport voice vlan 10.

 

When I connect : Switchport-----IpPhone -----PC  : it's working fine.

 

My Questions :

Can I directly connect the PC  to that switchports ? 

Will the PC fall in the DATA VLAN ?

How does the switch detect if it's a PC or Phone to provide the right vlan ?

 

Thanks very much

4 Replies 4

hemmerling
Level 1
Level 1

I don't remember the exact mechanism of how the phone goes into the voice VLAN (possibly CDP from the phone), but the computer will only be in the data VLAN if plugged directly to the switchport. I think the tagged voice VLAN traffic is available to the computer's NIC (so a promiscuous mode NIC and Wireshark can likely see voice VLAN broadcast traffic).

Reza Sharifi
Hall of Fame
Hall of Fame

Hi,

Can I directly connect the PC  to that switchports ? 

Yes

Will the PC fall in the DATA VLAN ?

Yes

How does the switch detect if it's a PC or Phone to provide the right vlan ?

The switch uses CDP to instruct the phone to send voice traffic:

see link page-page-14-2

https://www.cisco.com/c/en/us/td/docs/switches/lan/catalyst2960/software/release/12-2_40_se/configuration/guide/scg/swvoip.pdf

 

HTH

 

balaji.bandi
Hall of Fame
Hall of Fame

an I directly connect the PC to that switchports ?

 

BB - yes you can as per the config.

 

Will the PC fall in the DATA VLAN ?

 

BB - yes PC get Data vlan IP address ( from DHCP)

 

How does the switch detect if it's a PC or Phone to provide the right vlan ?

 

Cisco has good document which explains :

 

https://www.cisco.com/c/en/us/td/docs/switches/lan/catalyst2960/software/release/12-2_40_se/configuration/guide/scg/swvoip.pdf

 

BB

***** Rate All Helpful Responses *****

How to Ask The Cisco Community for Help

Joseph W. Doherty
Hall of Fame
Hall of Fame

"Can I directly connect the PC to that switchports ? "

As already noted by other posters, yes you can.

"Will the PC fall in the DATA VLAN ?"

Normally, yes.  The DATA VLAN is untagged and PCs, almost always, don't tag their frames.  However, if PC tags its frames, which again is possible, its traffic might end up on Voice VLAN, or not work at all.

"How does the switch detect if it's a PC or Phone to provide the right vlan ?"

I recall, the switch, itself, doesn't (nor care).  It's up to the connecting device to use untagged or (correctly) tagged frames.

As the other posters have noted, a device, especially Cisco VoIP phones, can determine (i.e. using CDP) there's a voice VLAN and the VLAN being used for it.  The device can then, dynamically, tag its frames to access that VLAN.

Non-Cisco VoIP phone, if they don't use CDP, might need to be "hard coded" for what VLAN to use for their voice traffic.  Some non-Cisco phones, might first get a DHCP packet on the DATA VLAN, which contains a DHCP option for what VLAN to be used for voice traffic, upon which, the VoIP phone will dynamically start using frames tagged for that VLAN.

BTW, you can have "Switchport-----IpPhone -----PC " also working fine w/o using a voice VLAN.  A voice VLAN, shared with a DATA VLAN, on the same port, allows "logical" control of traffic on their respective VLANs, but remember, the physical port, and its capacity, is still shared between the VLANs.

Review Cisco Networking for a $25 gift card