Isso corrigiu
sudo systemctl stop apparmor.service
sudo apt-get -f install
sudo systemctl start apparmor.service
Eu fiz o upgrade do Ubuntu 14.04 para o 16.04. Kvm gerente não funcionaria. Tentei removê-lo e agora, ao tentar reinstalar, ainda recebo o mesmo erro quando executo sudo apt install qemu qemu-kvm
Setting up libvirt-bin (1.3.1-1ubuntu10.10) ...
Job for libvirt-bin.service failed because the control process exited with error code. See "systemctl status libvirt-bin.service" and "journalctl -xe" for details.
invoke-rc.d: initscript libvirt-bin, action "start" failed.
● libvirt-bin.service - Virtualization daemon
Loaded: loaded (/lib/systemd/system/libvirt-bin.service; enabled; vendor preset: enabled)
Active: activating (auto-restart) (Result: exit-code) since lun 2017-06-26 16:34:35 EDT; 4ms ago
Docs: man:libvirtd(8)
http://libvirt.org
Process: 13371 ExecStart=/usr/sbin/libvirtd $libvirtd_opts (code=exited, status=6)
Main PID: 13371 (code=exited, status=6)
CGroup: /system.slice/libvirt-bin.service
└─13389 /usr/sbin/libvirtd
jun 26 16:34:35 john-Lenovo-Yoga-2-Pro systemd[1]: Failed to start Virtualiza...
jun 26 16:34:35 john-Lenovo-Yoga-2-Pro systemd[1]: libvirt-bin.service: Unit ...
jun 26 16:34:35 john-Lenovo-Yoga-2-Pro systemd[1]: libvirt-bin.service: Faile...
Hint: Some lines were ellipsized, use -l to show in full.
dpkg: error processing package libvirt-bin (--configure):
subprocess installed post-installation script returned error exit status 1
Errors were encountered while processing:
libvirt-bin
E: Sub-process /usr/bin/dpkg returned an error code (1)
Quando executo o comando journalctl -xe
, recebo essa saída
jun 26 16:34:36 john-Lenovo-Yoga-2-Pro audit[13459]: AVC apparmor="DENIED" operation="create" profile="/usr/sbin/libvirtd" pid=13459 comm="libvirtd" family="netlink" sock_type="raw" protocol=0 requested_m
jun 26 16:34:36 john-Lenovo-Yoga-2-Pro libvirtd[13459]: cannot connect to netlink socket with protocol 0: Permission denied
jun 26 16:34:36 john-Lenovo-Yoga-2-Pro kernel: audit: type=1400 audit(1498509276.292:198): apparmor="DENIED" operation="create" profile="/usr/sbin/libvirtd" pid=13459 comm="libvirtd" family="netlink" sock
jun 26 16:34:36 john-Lenovo-Yoga-2-Pro systemd[1]: libvirt-bin.service: Main process exited, code=exited, status=6/NOTCONFIGURED
jun 26 16:34:36 john-Lenovo-Yoga-2-Pro systemd[1]: Failed to start Virtualization daemon.
-- Subject: Unit libvirt-bin.service has failed
-- Defined-By: systemd
-- Support: http://lists.freedesktop.org/mailman/listinfo/systemd-devel
--
-- Unit libvirt-bin.service has failed.
--
-- The result is failed.
jun 26 16:34:36 john-Lenovo-Yoga-2-Pro systemd[1]: libvirt-bin.service: Unit entered failed state.
jun 26 16:34:36 john-Lenovo-Yoga-2-Pro systemd[1]: libvirt-bin.service: Failed with result 'exit-code'.
jun 26 16:34:36 john-Lenovo-Yoga-2-Pro systemd[1]: libvirt-bin.service: Service hold-off time over, scheduling restart.
jun 26 16:34:36 john-Lenovo-Yoga-2-Pro systemd[1]: Stopped Virtualization daemon.
-- Subject: Unit libvirt-bin.service has finished shutting down
-- Defined-By: systemd
-- Support: http://lists.freedesktop.org/mailman/listinfo/systemd-devel
--
-- Unit libvirt-bin.service has finished shutting down.
jun 26 16:34:36 john-Lenovo-Yoga-2-Pro systemd[1]: Starting Virtualization daemon...
-- Subject: Unit libvirt-bin.service has begun start-up
-- Defined-By: systemd
-- Support: http://lists.freedesktop.org/mailman/listinfo/systemd-devel
--
-- Unit libvirt-bin.service has begun starting up.
jun 26 16:34:36 john-Lenovo-Yoga-2-Pro audit[13481]: AVC apparmor="DENIED" operation="create" profile="/usr/sbin/libvirtd" pid=13481 comm="libvirtd" family="netlink" sock_type="raw" protocol=9 requested_m
jun 26 16:34:36 john-Lenovo-Yoga-2-Pro libvirtd[13481]: libvirt version: 1.3.1, package: 1ubuntu10.10 (Christian Ehrhardt <[email protected]> Tue, 16 May 2017 12:38:02 +0200)
jun 26 16:34:36 john-Lenovo-Yoga-2-Pro libvirtd[13481]: hostname: john-Lenovo-Yoga-2-Pro
jun 26 16:34:36 john-Lenovo-Yoga-2-Pro libvirtd[13481]: Unable to initialize audit layer: Permission denied
jun 26 16:34:36 john-Lenovo-Yoga-2-Pro audit[13481]: AVC apparmor="DENIED" operation="create" profile="/usr/sbin/libvirtd" pid=13481 comm="libvirtd" family="netlink" sock_type="raw" protocol=0 requested_m
jun 26 16:34:36 john-Lenovo-Yoga-2-Pro libvirtd[13481]: cannot connect to netlink socket with protocol 0: Permission denied
jun 26 16:34:36 john-Lenovo-Yoga-2-Pro systemd[1]: libvirt-bin.service: Main process exited, code=exited, status=6/NOTCONFIGURED
jun 26 16:34:36 john-Lenovo-Yoga-2-Pro systemd[1]: Failed to start Virtualization daemon.
-- Subject: Unit libvirt-bin.service has failed
-- Defined-By: systemd
-- Support: http://lists.freedesktop.org/mailman/listinfo/systemd-devel
--
-- Unit libvirt-bin.service has failed.
--
-- The result is failed.
jun 26 16:34:36 john-Lenovo-Yoga-2-Pro systemd[1]: libvirt-bin.service: Unit entered failed state.
jun 26 16:34:36 john-Lenovo-Yoga-2-Pro systemd[1]: libvirt-bin.service: Failed with result 'exit-code'.
jun 26 16:34:36 john-Lenovo-Yoga-2-Pro sudo[13080]: pam_unix(sudo:session): session closed for user root
jun 26 16:34:36 john-Lenovo-Yoga-2-Pro systemd[1]: libvirt-bin.service: Service hold-off time over, scheduling restart.
jun 26 16:34:36 john-Lenovo-Yoga-2-Pro systemd[1]: Stopped Virtualization daemon.
-- Subject: Unit libvirt-bin.service has finished shutting down
-- Defined-By: systemd
-- Support: http://lists.freedesktop.org/mailman/listinfo/systemd-devel
--
-- Unit libvirt-bin.service has finished shutting down.
jun 26 16:34:36 john-Lenovo-Yoga-2-Pro systemd[1]: libvirt-bin.service: Start request repeated too quickly.
jun 26 16:34:36 john-Lenovo-Yoga-2-Pro systemd[1]: Failed to start Virtualization daemon.
-- Subject: Unit libvirt-bin.service has failed
-- Defined-By: systemd
-- Support: http://lists.freedesktop.org/mailman/listinfo/systemd-devel
--
-- Unit libvirt-bin.service has failed.
--
-- The result is failed.
Isso corrigiu
sudo systemctl stop apparmor.service
sudo apt-get -f install
sudo systemctl start apparmor.service