Bug 917522 - [RHEVM] [backend] VNIC plug/unplug is incorrectly reported in logs
Summary: [RHEVM] [backend] VNIC plug/unplug is incorrectly reported in logs
Keywords:
Status: CLOSED ERRATA
Alias: None
Product: Red Hat Enterprise Virtualization Manager
Classification: Red Hat
Component: ovirt-engine
Version: 3.2.0
Hardware: x86_64
OS: Linux
unspecified
low
Target Milestone: ---
: 3.2.0
Assignee: Alona Kaplan
QA Contact: Martin Pavlik
URL:
Whiteboard: network
Depends On:
Blocks: 948448
TreeView+ depends on / blocked
 
Reported: 2013-03-04 09:28 UTC by Martin Pavlik
Modified: 2022-07-09 07:16 UTC (History)
10 users (show)

Fixed In Version: sf13.1
Doc Type: Enhancement
Doc Text:
Clone Of:
Environment:
Last Closed: 2013-06-10 21:34:54 UTC
oVirt Team: Network
Target Upstream Version:
Embargoed:


Attachments (Terms of Use)
log_collector (9.24 MB, application/x-xz)
2013-03-04 09:28 UTC, Martin Pavlik
no flags Details
screenshot 1 (226.96 KB, image/png)
2013-03-04 09:29 UTC, Martin Pavlik
no flags Details


Links
System ID Private Priority Status Summary Last Updated
Red Hat Issue Tracker RHV-47305 0 None None None 2022-07-09 07:16:12 UTC
Red Hat Product Errata RHSA-2013:0888 0 normal SHIPPED_LIVE Moderate: Red Hat Enterprise Virtualization Manager 3.2 update 2013-06-11 00:55:41 UTC
oVirt gerrit 12760 0 None None None Never

Description Martin Pavlik 2013-03-04 09:28:11 UTC
Created attachment 704825 [details]
log_collector

Description of problem:

1) When VNIC is unplugged from a VM, log message says plugged=true and when VNIC is plugged, plugged=false (See Additional info for full log line)

Hotplug itself works fine, just the log is wrong.

2) GUI event message could be improved

now it says that VNIC was updated, but does not say how
Interface nic2 (Red Hat VirtIO) was updated for VM F18. (User: admin@internal)

if possible change it to

Interface nic2 (Red Hat VirtIO) was plugged for VM F18. (User: admin@internal)
Interface nic2 (Red Hat VirtIO) was unplugged for VM F18. (User: admin@internal)

- see screenshot


Version-Release number of selected component (if applicable):
SF9

How reproducible:
100%

Steps to Reproduce:
1. Create VM with 1 VNIC and OS supporting hotplug
2. Start VM and plug/unplug the VNIC
  
Actual results:
plugged = false in log when VNIC is plugged
plugged = true in log when VNIC is NOT plugged

Expected results:
plugged = true in log when VNIC is plugged
plugged = false in log when VNIC is NOT plugged


Additional info:

It would be nice if all boolean values were grouped together in the following log line

2013-03-04 09:17:31,009 INFO  [org.ovirt.engine.core.vdsbroker.vdsbroker.HotUnplugNicVDSCommand] (ajp-/127.0.0.1:8702-8) [1a4b1955] START, HotUnplugNicVDSCommand(HostName = dell-06, HostId = 4ebe3c1b-6fb7-4de6-8045-3459fad14131, vm.vm_name=F18, nic=VmNetworkInterface {id=9ef89efd-6073-4fa0-9ac5-902c301ed7d6, networkName=rhevm, speed=1000, type=3, name=nic2, macAddress=00:1a:4a:22:3f:29, active=true, linked=true, portMirroring=false, vmId=be00921f-365f-42bb-99d0-b33b4a097c1b, vmName=F18, vmTemplateId=null}, vmDevice=VmDevice {vmId=be00921f-365f-42bb-99d0-b33b4a097c1b, deviceId=9ef89efd-6073-4fa0-9ac5-902c301ed7d6, device=bridge, type=interface, bootOrder=0, specParams={}, address={bus=0x00, domain=0x0000, type=pci, slot=0x08, function=0x0}, managed=true, plugged=true, readOnly=false, deviceAlias=net0}), log id: bd82abd
2013-03-04 09:17:31,315 INFO  [org.ovirt.engine.core.vdsbroker.vdsbroker.HotUnplugNicVDSCommand] (ajp-/127.0.0.1:8702-8) [1a4b1955] FINISH, HotUnplugNicVDSCommand, log id: bd82abd

Comment 1 Martin Pavlik 2013-03-04 09:29:15 UTC
Created attachment 704826 [details]
screenshot 1

Comment 2 Moti Asayag 2013-03-06 09:55:51 UTC
Regarding 1: the printed nic properties are part of log mechanism which prints the entity passed to VDS command. It reflects the current value of the property, prior to the execution. Therefore if the nic should be plugged, its 'plugged' property value would be 'false', since this is its actual value.

If it causes any confusion, we can remove the properties from the log for this specific action.

Regarding 2: There are 2 separate commands which are equivalent to performed commands: The Add/Update command and the Activate/Deactivate command.
The log should present both of them when performing plug/unplug via the Add/Update vnic commands. And basically this is what is shown on the log: 
'Deactivate nic' message followed by 'Update nic' message - two messages which reflects the performed actions.

Comment 3 Martin Pavlik 2013-03-06 13:38:24 UTC
Hello Moti,
thanks for the clarification

1) I would not remove it, I consider more information better in this case

2) I think problem is the word "activate/deactivate" since it appears after "plug/unplug" action in the GUI

If activate/deactivate could be changed to plug/unplug, it would be perfect.

Comment 4 Martin Pavlik 2013-03-06 13:39:59 UTC
Please ignore comment 3, I see you already did it.

Comment 5 Martin Pavlik 2013-04-11 14:43:49 UTC
VERIFIED

Network Interface nic1 (Red Hat VirtIO) was unplugged from VM F18. (User: admin@internal)

Network Interface nic1 (Red Hat VirtIO) was plugged to VM F18. (User: admin@internal)

Comment 8 errata-xmlrpc 2013-06-10 21:34:54 UTC
Since the problem described in this bug report should be
resolved in a recent advisory, it has been closed with a
resolution of ERRATA.

For information on the advisory, and where to find the updated
files, follow the link below.

If the solution does not work for you, open a new bug report.

http://rhn.redhat.com/errata/RHSA-2013-0888.html


Note You need to log in before you can comment on or make changes to this bug.