Hi Serge,

I hit this problem on a stock install of 14.04, only installed MAAS and
libvirt-bin + dist-upgrade.  When I ran your debug commands (@22)
libvirt-bin failed to crash but when I start the process it still fails,
here's the only log output I see below:

/var/log/libvirt/libvirtd.log:
Sep 16 11:14:55 maas kernel: [ 1310.741951] init: libvirt-bin main process 
(30028) terminated with status 6
Sep 16 11:14:55 maas kernel: [ 1310.741980] init: libvirt-bin main process 
ended, respawning
Sep 16 11:15:05 maas kernel: [ 1320.786451] init: libvirt-bin post-start 
process (30033) terminated with status 1

/var/log/upstart/libvirt-bin.log:
/usr/sbin/libvirtd: error: Unable to initialize network sockets. Check 
/var/log/messages or run without --daemon for more info.
Giving up waiting for /var/run/libvirt/libvirt-sock.
libvirt-bin stop/post-start, (post-start) process 30244

One thing I did notice is that I had set /etc/default/libvirt-bin:
'libvirtd_opts="-d -l" ' without changing any
/etc/libvirt/libvirtd.conf, and removing this option allows it to start
again fine.

Recipe:
1) Trusty stock install (and install MAAS from stable PPA?)
2) apt-get install libvirt-bin
3) /etc/default/libvirt-bin:  ' libvirtd_opts="-d -l" '
4) apt-get dist-upgrade
5) sudo service libvirt-bin restart

Linux maas 3.16.0-30-generic #40~14.04.1-Ubuntu SMP Thu Jan 15 17:43:14 UTC 
2015 x86_64 x86_64 x86_64 GNU/Linux
ii  libvirt-bin                          1.2.2-0ubuntu13.1.14                  
amd64        programs for the libvirt library
ii  upstart                              1.12.1-0ubuntu4.2                     
amd64        event-based init daemon
ii  apparmor                             2.8.95~2430-0ubuntu5.3                
amd64        User-space parser utility for AppArmor

Additional:

$ sudo /usr/sbin/libvirtd -l 2>&1 | tee libvirt.debug
2015-09-16 15:30:51.587+0000: 30946: info : libvirt version: 1.2.2
2015-09-16 15:30:51.587+0000: 30946: error : virNetTLSContextCheckCertFile:117 
: Cannot read CA certificate '/etc/pki/CA/cacert.pem': No such file or directory

$ dmesg | grep -i armo | grep libv
[  835.996698] audit: type=1400 audit(1442416021.069:40): apparmor="STATUS" 
operation="profile_replace" profile="unconfined" 
name="/usr/lib/libvirt/virt-aa-helper" pid=30866 comm="apparmor_parser"
[  836.134080] audit: type=1400 audit(1442416021.205:45): apparmor="STATUS" 
operation="profile_replace" profile="unconfined" name="/usr/sbin/libvirtd" 
pid=30868 comm="apparmor_parser"

The problem may just be the /etc/libvirt/libvirtd.conf default settings
and maybe poor messaging or user error?  Hope this helps someone.
Changing the conf file to this fixed my problem:

listen_tls = 0
listen_tcp = 1

-- 
You received this bug notification because you are a member of Ubuntu
Bugs, which is subscribed to Ubuntu.
https://bugs.launchpad.net/bugs/1386465

Title:
  apparmor profile prevents libvirtd from creating a socket

To manage notifications about this bug go to:
https://bugs.launchpad.net/ubuntu/+source/libvirt/+bug/1386465/+subscriptions

-- 
ubuntu-bugs mailing list
ubuntu-bugs@lists.ubuntu.com
https://lists.ubuntu.com/mailman/listinfo/ubuntu-bugs

Reply via email to