Note: This bug is displayed in read-only format because
the product is no longer active in Red Hat Bugzilla.
RHEL Engineering is moving the tracking of its product development work on RHEL 6 through RHEL 9 to Red Hat Jira (issues.redhat.com). If you're a Red Hat customer, please continue to file support cases via the Red Hat customer portal. If you're not, please head to the "RHEL project" in Red Hat Jira and file new tickets here. Individual Bugzilla bugs in the statuses "NEW", "ASSIGNED", and "POST" are being migrated throughout September 2023. Bugs of Red Hat partners with an assigned Engineering Partner Manager (EPM) are migrated in late September as per pre-agreed dates. Bugs against components "kernel", "kernel-rt", and "kpatch" are only migrated if still in "NEW" or "ASSIGNED". If you cannot log in to RH Jira, please consult article #7032570. That failing, please send an e-mail to the RH Jira admins at rh-issues@redhat.com to troubleshoot your issue as a user management inquiry. The email creates a ServiceNow ticket with Red Hat. Individual Bugzilla bugs that are migrated will be moved to status "CLOSED", resolution "MIGRATED", and set with "MigratedToJIRA" in "Keywords". The link to the successor Jira issue will be found under "Links", have a little "two-footprint" icon next to it, and direct you to the "RHEL project" in Red Hat Jira (issue links are of type "https://issues.redhat.com/browse/RHEL-XXXX", where "X" is a digit). This same link will be available in a blue banner at the top of the page informing you that that bug has been migrated.
Fixed upstream by:
Refs: v4.4.0-rc1-7-ge0fae78ad5
Author: Erik Skultety <eskultet>
AuthorDate: Thu May 31 09:42:58 2018 +0200
Commit: Erik Skultety <eskultet>
CommitDate: Thu May 31 12:09:50 2018 +0200
audit: Enforce enum switch type cast in virDomainAuditHostdev
There was a missing enum for mdev causing a strange 'unknown device type'
warning when hot-plugging mdev.
Resolves: https://bugzilla.redhat.com/show_bug.cgi?id=1583927
Signed-off-by: Erik Skultety <eskultet>
Reproduced with libvirt-4.3.0-1.el7.x86_64.
Verified with libvirt-4.5.0-7.el7.x86_64.
Test steps are the same as comment 0. And no warning "Unexpected hostdev type while encoding audit message" in libvirtd.log when attaching a mdev device.
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.
https://access.redhat.com/errata/RHSA-2018:3113
Description of problem: "Unexpected hostdev type while encoding audit message: 4" when attach a mdev hostdev. Version-Release number of selected component (if applicable): libvirt-4.3.0-1.el7.x86_64 How reproducible: 100% Steps to Reproduce: 0.Prepare mdev device 1.Start a guest 2.Attach mdev device to guest: # cat /tmp/mdev.xml <hostdev mode='subsystem' type='mdev' model='vfio-pci'> <source> <address uuid='7bb8579b-55ca-4f4d-b70f-498a583c1e6e'/> </source> <alias name='ua-0febf033-9953-40e1-b803-2df42b0bac4e'/> </hostdev> # virsh attach-device 1 /tmp/mdev.xml Device attached successfully 3.Check libvirtd log: 2018-05-30 03:20:57.241+0000: 19704: warning : virDomainAuditHostdev:424 : Unexpected hostdev type while encoding audit message: 4 Actual results: Warning when log audit message for mdev device. Expected results: Audit log is recorded successfully Additional info: