Problem Description
The customer connected one IP Phone to S5700 and he found the IP Phone cannot get an IP address from voice VLAN.
The port configuration is following. VLAN 16 is voice VLAN and VLAN 44 is data VLAN.
interface GigabitEthernet0/0/4
description Phone-Data Access
port link-type hybrid
voice-vlan 16 enable
voice-vlan legacy enable
port hybrid pvid vlan 44
port hybrid tagged vlan 16
port hybrid untagged vlan 44
With the above configuration, the IP Phone gets IP address from data VLAN rather than voice VLAN.
<Test>display lldp neighbor interface GigabitEthernet 0/0/4
GigabitEthernet0/0/4 has 1 neighbor(s):
..................................
Neighbor index :1
Chassis type :networkAddress
Chassis ID :X.X.44.X
Port ID type :macAddress
Port ID :0004-f242-cbc8
Port description :1
System name :Polycom SoundPoint IP 335
System description :Polycom;SoundPointIP-SPIP_335;2345-12375-001,1;SIP/3.2.2.0477/18-Nov-09 13:58;BR/4.2.2.0710/24-Feb-10 16:39;
System capabilities supported :bridge telephone
System capabilities enabled :telephone
Management address type :ipv4
Management address value :X.X.44.X
Expired time :102s
..................................
Alarm Information
Procedure
1.For this kind of issue, we need to confirm how IP Phone gets voice VLAN. There are several ways. Like LLDP, DHCP, CDP. Confirmed with the customer. However, he cannot provide us the answer. In order to know how IP Phone gets voice VLAN. We use the below command to capture packet on our s5700
[huawei]capture-packet interface GigabitEthernet 0/0/4 destination terminal packet-len total-packet packet-num 30
In the capture, we find the LLDP packet as following and S5700 provided the voice VLAN to IP Phone.
Using the command "display lldp neighbor interface GigabitEthernet 0/0/4", we also confirmed that IP Phone learned the voice VLAN from LLDP.
<Test>display lldp neighbor interface GigabitEthernet 0/0/4
..................................
Media policy type :Voice
Unknown Policy :Defined
VLAN tagged :Yes
Media policy VlanID :16
Media policy L2 priority :5
Media policy Dscp :46
Media policy type :Voice Signaling
Unknown Policy :Defined
VLAN tagged :Yes
Media policy VlanID :16
Media policy L2 priority :5
Media policy Dscp :44
..................................
3. Usually, when IP Phone got voice VLAN from S5700, it will send a packet with VLAN 16. However, the IP Phone did not get IP from voice VLAN. In capture, we found the packet from IP Phone did not bring the voice VLAN. That is why the IP Phone got IP from data VLAN.
It proves that the packet from IP Phone does not contain the voice VLAN. In this situation, we have one command to solve it as following.
<HUAWEI> system-view
[HUAWEI] voice-vlan mac-address 0004-f242-cbc8 mask ffff-ff00-0000 description ipphone // after this configuration all the packets coming from the phone will be identified as part of the voice vlan
[HUAWEI] interface gigabitethernet 0/0/4
[HUAWEI-GigabitEthernet0/0/1] voice-vlan 16 enable include-untagged
4. After making the change, the customer confirmed that the IP Phone could get an IP address from voice VLAN correctly.
<Test>display lldp neighbor interface GigabitEthernet 0/0/4
GigabitEthernet0/0/4 has 1 neighbor(s):
..................................
Neighbor index :1
Chassis type :networkAddress
Chassis ID :X.X.16.X
Port ID type :macAddress
Port ID :0004-f242-cbc8
Port description :1
System name :Polycom SoundPoint IP 335
System description :Polycom;SoundPointIP-SPIP_335;2345-12375-001,1;SIP/3.2.2.0477/18-Nov-09 13:58;BR/4.2.2.0710/24-Feb-10 16:39;
System capabilities supported :bridge telephone
System capabilities enabled :telephone
Management address type :ipv4
Management address value :X.X.16.X
Expired time :102s
..................................
However, the customer reported another issue with the 'included-untagged' parameter. The port connected to IP Phone is keeping flapping.
Oct 13 2015 22:35:28+13:00 DST TEST %IFPDT/4/IF_STATE(l)[0]:Interface GigabitEthernet0/0/4 has turned into UP state.
Oct 13 2015 22:35:24+13:00 DST TEST %IFPDT/4/IF_STATE(l)[1]:Interface GigabitEthernet0/0/4 has turned into DOWN state.
Oct 13 2015 22:34:20+13:00 DST TEST %IFPDT/4/IF_STATE(l)[2]:Interface GigabitEthernet0/0/4 has turned into UP state.
Oct 13 2015 22:34:17+13:00 DST TEST %IFPDT/4/IF_STATE(l)[3]:Interface GigabitEthernet0/0/4 has turned into DOWN state.
Oct 13 2015 22:33:13+13:00 DST TEST %IFPDT/4/IF_STATE(l)[4]:Interface GigabitEthernet0/0/4 has turned into UP state.
Oct 13 2015 22:33:10+13:00 DST TEST %IFPDT/4/IF_STATE(l)[5]:Interface GigabitEthernet0/0/4 has turned into DOWN state.
Oct 13 2015 22:32:07+13:00 DST TEST %IFPDT/4/IF_STATE(l)[6]:Interface GigabitEthernet0/0/4 has turned into UP state.
If customer deletes the "included-untagged" parameter, the port will not flapp however IP Phone cannot take IP address from voice vlan.
5. Analyzed the process, "included-untagged" parameter should not affect the port behavior. It is just used for inbound packet from IP Phone. Port flapping should be caused by other issue. Made one remote troubleshooting with this new issue and we found that when Huawei switch replied LLDP packet, the IP Phone will release its IP address and send DHCP discover packet again. After that, the port is down.
Based on above capture, we can see that some thing is wrong on IP Phone with strange behavior. In order to solve port flapping issue, we disable LLDP on port Gi0/0/4 which is connected to IP Phone
interface GigabitEthernet0/0/4
port link-type hybrid
voice-vlan 16 enable include-untagged
port hybrid pvid vlan 44
port hybrid untagged vlan 16 44
undo lldp enable
After that, the problem is solved completely.
Root Cause
1. The IP Phone did not send a packet in voice VLAN after learned it from S5700. We could use the 'included-untagged' parameter to solve it.
2. Strange behavior on the IP Phone when it receives LLDP packet from S5700 with voice vlan enabled.
Solution
With the below configuration, the problem is solved completely.
interface GigabitEthernet0/0/4
port link-type hybrid
voice-vlan 16 enable include-untagged
port hybrid pvid vlan 44
port hybrid untagged vlan 16 44
undo lldp enable