Crc: [BUG]failed to connect socket to '/var/run/libvirt/virtlogd-sock': Connection refused') Making call to close driver server

Created on 23 Sep 2019  路  8Comments  路  Source: code-ready/crc

General information

  • OS: Linux
  • Hypervisor: KVM
  • Did you run crc setup before starting it ? yes

Put crc version output here

OpenShift version: 4.1.14

CRC status

none

CRC config

CRC VM: Stopped
OpenShift: Stopped
Disk Usage: 0B of 0B (Inside the CRC VM)
Cache Usage: 14.99GB
Cache Directory: /home/eyaldavid/.crc/cache

```

Host Operating System

Fedora 30

after the crc start command i am getting this error massage
ERRO Error occurred: Error creating host: Error creating the VM. Error creating machine: Error in driver during machine creation: virError(Code=38, Domain=7, Message='Failed to connect socket to '/var/run/libvirt/virtlogd-sock': Connection

Logs

Running pre-create checks...
(crc) Calling .PreCreateCheck
(crc) DBG | About to check libvirt version
(crc) DBG | Validating network
(crc) Calling .GetConfigRaw
Creating machine...
(crc) Calling .Create
(crc) Downloading /home/eyaldavid/.crc/cache/crc from file:///home/eyaldavid/.crc/cache/crc_libvirt_4.1.14/crc.qcow2...
(crc) DBG | Verifying executable bit set on /home/eyaldavid/.crc/machines/crc
(crc) DBG | Setting executable bit set on /home/eyaldavid/.crc/machines/crc
(crc) DBG | Verifying executable bit set on /home/eyaldavid/.crc/machines
(crc) DBG | Verifying executable bit set on /home/eyaldavid/.crc
(crc) DBG | Verifying executable bit set on /home/eyaldavid
(crc) DBG | Verifying executable bit set on /home
(crc) DBG | Defining VM...
(crc) DBG | Adding the file: /home/eyaldavid/.crc/machines/crc/.crc-exist
(crc) DBG | Starting VM crc
(crc) Failed to start: virError(Code=38, Domain=7, Message='Failed to connect socket to '/var/run/libvirt/virtlogd-sock': Connection refused')
Making call to close driver server
(crc) Calling .Close
Successfully made call to close driver server

kinbug statuneed more information statustale

Most helpful comment

Solved on CentOS 7:

  1. Add stdio_handler="file" to /etc/libvirt/qemu.conf
  2. Run service libvirtd restart
  3. VMs starting up...

All 8 comments

Are you using Ubuntu?

I believe all that is needed is:

$ systemctl enable virtlogd
$ systemctl start virtlogd

Oh maybe the preflight check enabling/starting the libvirtd service also needs to enable/start virtlockd.socket and virtlogd.socket. Not sure what libvirtd expectations are

As part of fedora libvirtd service side I can see following, which make sure those socket is enabled, not sure on Ubuntu side that is true also.

$ systemctl cat libvirtd
[...]
[Install]
WantedBy=multi-user.target
Also=virtlockd.socket
Also=virtlogd.socket

Are you using Ubuntu?

The report says Fedora 30.

Host Operating System

Fedora 30

Didn't catch this... and if so, this is an issue with Fedora (as the unit should start this). Likely the service crashes. This is outside of the scope of CRC to handle. We assume libvirt to be existing and operational... we can only slightly configure, but not fix it for someone.

@Eyaldavid7 is that still an issue? Can you check systemctl status libvirtd, systemctl status libvirtd.socket and systemctl status virtlockd.socket?

This issue has been automatically marked as stale because it has not had recent activity. It will be closed if no further activity occurs. Thank you for your contributions.

Solved on CentOS 7:

  1. Add stdio_handler="file" to /etc/libvirt/qemu.conf
  2. Run service libvirtd restart
  3. VMs starting up...
Was this page helpful?
0 / 5 - 0 ratings