avocado-framework / avocado-vt

Avocado VT Plugin
https://avocado-vt.readthedocs.org/
Other
83 stars 242 forks source link

Hotunplug original nic without closfd #3923

Closed maxujun closed 3 months ago

maxujun commented 5 months ago

ID:2396

maxujun commented 5 months ago

(1/2) Host_RHEL.m8.u10.product_rhel.qcow2.virtio_scsi.up.virtio_net.Guest.RHEL.9.4.0.ppc64le.io-github-autotest-qemu.nic_hotplug.one_pci.nic_virtio: STARTED (1/2) Host_RHEL.m8.u10.product_rhel.qcow2.virtio_scsi.up.virtio_net.Guest.RHEL.9.4.0.ppc64le.io-github-autotest-qemu.nic_hotplug.one_pci.nic_virtio: PASS (412.37 s) (2/2) Host_RHEL.m8.u10.product_rhel.qcow2.virtio_scsi.up.virtio_net.Guest.RHEL.9.4.0.ppc64le.io-github-autotest-qemu.nic_hotplug.migration.after_nichotunplug.nic_virtio: STARTED (2/2) Host_RHEL.m8.u10.product_rhel.qcow2.virtio_scsi.up.virtio_net.Guest.RHEL.9.4.0.ppc64le.io-github-autotest-qemu.nic_hotplug.migration.after_nichotunplug.nic_virtio: PASS (184.67 s)

@PaulYuuu Could you help review?

PaulYuuu commented 4 months ago

@yanglei-rh @YongxueHong, can you help to review as well?

yanglei-rh commented 4 months ago

Hi @maxujun Theoretically, fd should be closed after used. So if there is not close original nic fd, will it cause too many fds to be occupied and unable to be released? Since there is a case scenario is repeat hotplug 100 times, and sometime QE will test it with multi queues.

YongxueHong commented 4 months ago

Hi @maxujun Would you like to give more details about this PR? Please add them to the commit message, thanks.

maxujun commented 4 months ago

Hi @maxujun Theoretically, fd should be closed after used. So if there is not close original nic fd, will it cause too many fds to be occupied and unable to be released? Since there is a case scenario is repeat hotplug 100 times, and sometime QE will test it with multi queues.

Original nic's fds have been closed without getfd after creating. Needn't closefd when hotunplugging.

yanglei-rh commented 4 months ago

Hi @maxujun Theoretically, fd should be closed after used. So if there is not close original nic fd, will it cause too many fds to be occupied and unable to be released? Since there is a case scenario is repeat hotplug 100 times, and sometime QE will test it with multi queues.

Original nic's fds have been closed without getfd after creating. Needn't closefd when hotunplugging.

Got it, so it LGTM.

maxujun commented 4 months ago

Request change according to above comment.

Updated

PaulYuuu commented 4 months ago

@YongxueHong What do you think of the current solution?

YongxueHong commented 3 months ago

Hi @luckyh I would like to hear your thoughts. Thanks in advance.