Uploaded image for project: 'RHEL'
  1. RHEL
  2. RHEL-21867

Link is up in vm when starting it with <link state='down'/> for e1000e or igb model interface

    • None
    • None
    • 1
    • rhel-sst-virtualization-networking
    • ssg_virtualization
    • 1
    • False
    • Hide

      None

      Show
      None
    • Yes
    • Virtio-Net Sprint 2 - June
    • Known Issue
    • Hide
      .Link status shows `up` on VM, even when status is `down` of `e1000e` or `igb` model interface

      Before booting the VM, set the status of Ethernet link `down` for the `e1000` or `igb` model network interface. Despite this, after the VM boots, the network interface keeps the `up` status, because when you set the status of Ethernet link `down` and then stop and re-start the VM, it is automatically set back to `up`. Consequently, the correct state of network interface is not maintained. As a workaround, set the network interface status to `down` inside the VM by using command:

      ----
      # ip link set dev eth0 down
      ----

      Alternatively, you can try to remove and add this network interface again while the VM is running.
      Show
      .Link status shows `up` on VM, even when status is `down` of `e1000e` or `igb` model interface Before booting the VM, set the status of Ethernet link `down` for the `e1000` or `igb` model network interface. Despite this, after the VM boots, the network interface keeps the `up` status, because when you set the status of Ethernet link `down` and then stop and re-start the VM, it is automatically set back to `up`. Consequently, the correct state of network interface is not maintained. As a workaround, set the network interface status to `down` inside the VM by using command: ---- # ip link set dev eth0 down ---- Alternatively, you can try to remove and add this network interface again while the VM is running.
    • Done
    • x86_64
    • None

      What were you trying to do that didn't work?

      After starting vm with <link state='down'/> for e1000e or igb model type interface, login vm, get "Link detected: yes" and can ping outside.

      Please provide the package NVR for which bug is seen:

      libvirt-10.0.0-1.el9.x86_64
      qemu-kvm-8.2.0-2.el9.x86_64

      How reproducible:

      100%

      Steps to reproduce

      1. Start vm with:

          <interface type='network'>
            <mac address='52:54:00:0d:34:ce'/>
            <source network='default'/>
            <model type='igb'/>
            <link state='down'/>
            <address type='pci' domain='0x0000' bus='0x01' slot='0x00' function='0x0'/>
          </interface>

      1. virsh start yqz-test
        Domain 'yqz-test' started
      1. ps aux|grep qemu-kvm|grep yqz-test|grep net

      ...-netdev {"type":"tap","fd":"24","id":"hostnet0"} -device

      {"driver":"igb","netdev":"hostnet0","id":"net0","mac":"52:54:00:0d:34:ce","bus":"pci.1","addr":"0x0"}

      ...

      1. Check vm interface on host:
      1. virsh domif-getlink yqz-test vnet9
        vnet9 down
      1. Check vm interface in vm:
      1. virsh console yqz-test

      [root@localhost ~]# ethtool enp1s0|grep Link
      Link detected: yes

      [root@localhost ~]# ping www.baidu.com -c2
      PING www.wshifen.com (45.113.192.101) 56(84) bytes of data.
      64 bytes from 45.113.192.101 (45.113.192.101): icmp_seq=1 ttl=49 time=69.9 ms
      64 bytes from 45.113.192.101 (45.113.192.101): icmp_seq=2 ttl=49 time=70.0 ms

      Expected results

      Starting vm with <link state='down'/> for e1000e or igb model interface but get an actually up link in vm.

      Actual results

      The link in vm should also be down.

      Additional info:

      1. If we do 'virsh domif-setlink xxx up' then 'virsh domif-setlink xxx down', we will get expected results: "Link detected: no" and ping doesn't work.

      2. Not reproduced for model type 'virtio' or 'rtl8139'.

      3. Not reproduced by pure qemu way of  RHEL-1218.

              lvivier@redhat.com Laurent Vivier
              yanqzhan1@redhat.com Yanqiu Zhang
              Gabriela Fialova
              Laurent Vivier Laurent Vivier
              Lei Yang Lei Yang
              Mayur Patil Mayur Patil
              Votes:
              0 Vote for this issue
              Watchers:
              13 Start watching this issue

                Created:
                Updated:
                Resolved: