none
VLAN Trunk doesn't work after issuing reboot command on VMs on Hyper-v 2012R2

    General discussion

  • HI, 

    I am using a centos7.3( Linux centos7.localdomain 3.10.0-514.el7.x86_64)
    VM and a ubuntu16.10  VM to test VLAN trunk on hyper-v 2012R2. After configuring vlan on both VMs and trunk mode on windows server 2012 R2. I am able to send and recieve tagged packets to/from VM.

    However when i reboot any one of VM , ping and arp stops working.

    I believed i am facing issue as in below link 

    https://social.technet.microsoft.com/Forums/windowsserver/en-US/700ecfdc-3015-41d8-aa3d-92a72879685f/hyperv-2012-r2-linux-guest-vlan-settings-lost-after-reboot?forum=linuxintegrationservices

    But i am seeing the issue even when i install latest linux integration services (4.1.3-2) on centos.

    Please let me know if there is a solution for this issue?? 

    Please find below config that i used.



    PS C:\Users\Administrator> Set-VMNetworkAdapterVlan -Trunk -AllowedVlanIdList 1-100 -NativeVlanId 0 -VMName centos7
    PS C:\Users\Administrator> Set-VMNetworkAdapterVlan -Trunk -AllowedVlanIdList 1-100 -NativeVlanId 0 -VMName ub1
    PS C:\Users\Administrator> Get-VMNetworkAdapterVlan

    VMName  VMNetworkAdapterName Mode     VlanList
    ------  -------------------- ----     --------
            vs1                  Untagged
            mgmt                 Untagged
    centos7 Network Adapter      Trunk    0,1-100
    centos7 Network Adapter      Trunk    0,1-100
    ub1     Network Adapter      Trunk    0,1-100
    ub1     Network Adapter      Trunk    0,1-100




    centos7

    ========

    not working case :

    =============



    [root@centos7 ~]# ip addr show 

    3: eth1: <BROADCAST,MULTICAST,UP,LOWER_UP> mtu 1500 qdisc mq state UP qlen 1000 
       link/ether 00:15:5d:4c:1d:0a brd ff:ff:ff:ff:ff:ff 
       inet6 fe80::aafc:c9db:3f77:62ab/64 scope link  
          valid_lft forever preferred_lft forever 
    4: vlan10@eth1: <BROADCAST,MULTICAST,UP,LOWER_UP> mtu 1500 qdisc noqueue state UP qlen 1000 
       link/ether 00:15:5d:4c:1d:0a brd ff:ff:ff:ff:ff:ff 
       inet 10.0.0.2/24 brd 10.0.0.255 scope global vlan10 
          valid_lft forever preferred_lft forever 
       inet6 fe80::e22e:9db7:e61c:eda2/64 scope link  
          valid_lft forever preferred_lft forever 
    [root@centos7 ~]# ping 10.0.0.1 
    PING 10.0.0.1 (10.0.0.1) 56(84) bytes of data. 
    From 10.0.0.2 icmp_seq=1 Destination Host Unreachable 
    From 10.0.0.2 icmp_seq=2 Destination Host Unreachable 
    From 10.0.0.2 icmp_seq=3 Destination Host Unreachable 
    From 10.0.0.2 icmp_seq=4 Destination Host Unreachable 
    From 10.0.0.2 icmp_seq=5 Destination Host Unreachable 
    From 10.0.0.2 icmp_seq=6 Destination Host Unreachable 
    From 10.0.0.2 icmp_seq=7 Destination Host Unreachable 
    From 10.0.0.2 icmp_seq=8 Destination Host Unreachable
    root@centos7 ~]# lsvmbus 
    VMBUS ID  1: Synthetic IDE Controller 
    VMBUS ID  2: [Reserved system device] 
    VMBUS ID  3: Synthetic mouse 
    VMBUS ID  4: Synthetic keyboard 
    VMBUS ID  5: Synthetic framebuffer adapter 
    VMBUS ID  6: [Reserved system device] 
    VMBUS ID  7: [Guest services] 
    VMBUS ID  8: [Heartbeat] 
    VMBUS ID  9: [Data Exchange] 
    VMBUS ID 10: [Operating system shutdown] 
    VMBUS ID 11: [Time Synchronization] 
    VMBUS ID 12: [Backup (volume checkpoint)] 
    VMBUS ID 13: [Reserved system device] 
    VMBUS ID 14: Synthetic network adapter 
    VMBUS ID 15: Synthetic SCSI Controller 
    VMBUS ID 16: Synthetic network adapter 
    [root@centos7 ~]# modinfo | grep hv_vmbus 
    modinfo: ERROR: missing module or filename. 
    [root@centos7 ~]# modinfo hv_vmbus        
    filename:       /lib/modules/3.10.0-514.el7.x86_64/extra/microsoft-hyper-v/hv_vmbus.ko 
    version:        4.1.3-2 
    license:        GPL 
    rhelversion:    7.3 
    srcversion:     DA1369C1A64936B3DDD2A5E 
    alias:          acpi*:VMBus:* 
    alias:          acpi*:VMBUS:* 
    depends:         
    vermagic:       3.10.0-514.el7.x86_64 SMP mod_unload modversions 
    [root@centos7 ~]# lsmod | egrep -i "^hv|hyperv" 
    hv_netvsc              44482  0  
    hv_storvsc             22535  2  
    hv_utils               25302  3  
    hyperv_keyboard        12777  0  
    hid_hyperv             13108  0  
    hyperv_fb              17769  1  
    hv_vmbus              398625  6 hyperv_keyboard,hv_netvsc,hid_hyperv,hv_utils,hyperv_fb,hv_storvsc



    Working:

    ==========

    [root@centos7 ~]# lsmod | egrep -i "^hv|hyperv" 
    hv_balloon             22073  0  
    hv_netvsc              44482  0  
    hv_storvsc             22535  2  
    hid_hyperv             13108  0  
    hv_utils               25302  3  
    hyperv_keyboard        12777  0  
    hyperv_fb              17769  1  
    hv_vmbus              398625  7 hv_balloon,hyperv_keyboard,hv_netvsc,hid_hyperv,hv_utils,hyperv_fb,hv_storvsc 
    [root@centos7 ~]# lsvmbus  
    VMBUS ID  1: Synthetic IDE Controller 
    VMBUS ID  2: [Reserved system device] 
    VMBUS ID  3: Synthetic mouse 
    VMBUS ID  4: Synthetic keyboard 
    VMBUS ID  5: Synthetic framebuffer adapter 
    VMBUS ID  6: [Reserved system device] 
    VMBUS ID  7: [Guest services] 
    VMBUS ID  8: [Heartbeat] 
    VMBUS ID  9: [Data Exchange] 
    VMBUS ID 10: [Operating system shutdown] 
    VMBUS ID 11: [Time Synchronization] 
    VMBUS ID 12: [Backup (volume checkpoint)] 
    VMBUS ID 13: [Reserved system device] 
    VMBUS ID 14: Synthetic network adapter 
    VMBUS ID 15: Synthetic SCSI Controller 
    VMBUS ID 16: Synthetic network adapter 
    [root@centos7 ~]# ip addr show 
    1: lo: <LOOPBACK,UP,LOWER_UP> mtu 65536 qdisc noqueue state UNKNOWN qlen 1 
       link/loopback 00:00:00:00:00:00 brd 00:00:00:00:00:00 
       inet 127.0.0.1/8 scope host lo 
          valid_lft forever preferred_lft forever 
       inet6 ::1/128 scope host  
          valid_lft forever preferred_lft forever 
    2: eth0: <BROADCAST,MULTICAST,UP,LOWER_UP> mtu 1500 qdisc mq state UP qlen 1000 
       link/ether 00:15:5d:4c:1d:09 brd ff:ff:ff:ff:ff:ff 
       inet 172.16.137.101/16 brd 172.16.255.255 scope global eth0 
          valid_lft forever preferred_lft forever 
       inet6 fe80::928f:b94c:669d:59b4/64 scope link  
          valid_lft forever preferred_lft forever 
    3: eth1: <BROADCAST,MULTICAST,UP,LOWER_UP> mtu 1500 qdisc mq state UP qlen 1000 
       link/ether 00:15:5d:4c:1d:0a brd ff:ff:ff:ff:ff:ff 
    4: vlan10@eth1: <BROADCAST,MULTICAST,UP,LOWER_UP> mtu 1500 qdisc noqueue state UP qlen 1000 
       link/ether 00:15:5d:4c:1d:0a brd ff:ff:ff:ff:ff:ff 
       inet 10.0.0.2/24 brd 10.0.0.255 scope global vlan10 
          valid_lft forever preferred_lft forever 
       inet6 fe80::e22e:9db7:e61c:eda2/64 scope link  
          valid_lft forever preferred_lft forever 
    [root@centos7 ~]# ping 10.0.0.1 
    PING 10.0.0.1 (10.0.0.1) 56(84) bytes of data. 
    64 bytes from 10.0.0.1: icmp_seq=1 ttl=64 time=0.210 ms 
    64 bytes from 10.0.0.1: icmp_seq=2 ttl=64 time=0.100 ms 
    64 bytes from 10.0.0.1: icmp_seq=3 ttl=64 time=0.100 ms


    Monday, March 27, 2017 7:36 AM