Skip to content
View in the app

A better way to browse. Learn more.

Unraid

A full-screen app on your home screen with push notifications, badges and more.

To install this app on iOS and iPadOS
  1. Tap the Share icon in Safari
  2. Scroll the menu and tap Add to Home Screen.
  3. Tap Add in the top-right corner.
To install this app on Android
  1. Tap the 3-dot menu (⋮) in the top-right corner of the browser.
  2. Tap Add to Home screen or Install app.
  3. Confirm by tapping Install.

Libvirt Service failed to start

Featured Replies

This was working just fine until I changed the IP on my unRAID box. When I go to turn on the VM support I get this in the log:

 

May 20 15:40:07 Deepthought emhttpd: shcmd (222): /usr/local/sbin/mount_image '/mnt/user/system/libvirt/libvirt.img' /etc/libvirt 1
May 20 15:40:07 Deepthought kernel: BTRFS info (device loop3): disk space caching is enabled
May 20 15:40:07 Deepthought kernel: BTRFS info (device loop3): has skinny extents
May 20 15:40:07 Deepthought root: Resize '/etc/libvirt' of 'max'
May 20 15:40:07 Deepthought kernel: BTRFS info (device loop3): new size for /dev/loop3 is 1073741824
May 20 15:40:07 Deepthought emhttpd: shcmd (224): /etc/rc.d/rc.libvirt start
May 20 15:40:07 Deepthought root: virtlockd is already running...
May 20 15:40:07 Deepthought emhttpd: shcmd (224): exit status: 1
May 20 15:40:07 Deepthought emhttpd: shcmd (226): umount /etc/libvirt

 

Are there any other logs I can look at to get a sense of why libvirt won't start?

  • Author

Ok, found the libvert logs, here is the issue:

 

2020-05-20 00:47:26.603+0000: 9951: error : virNetSocketNewListenTCP:440 : Unable to bind to port: Cannot assign requested address

So my questions are:

 

1. Why is this suddenly happening? 

2. Why can it not bind to port 440? If something else is using it, what would that be (none of my dockers are using that port)?

3. How do I change this port to something else?

  • Author

For the record there are no dockers installed that are using port 440. 

 

lsof -i -P -n | grep LISTEN

Shows that there is nothing listening on port 440 on the server as well. So it does not appear to be a port conflict.

 

The libvirtd.conf file in /etc/libvirt-/ shows that the listening IP is set to 127.0.0.1 

 

I am not really sure where to go from here.

  • Author

Am I seriously the only one to experience this? There is really no one out there that can help me out?

12 hours ago, lutiana said:

Am I seriously the only one to experience this?

Never seen it before, just changing the Unraid IP should never cause this.

 

Do you have any VMs? No idea if it would help but you could try recreating libvirt.img but that would mean re-creating all VMs, though you could backup current image first.

  • Author
On 5/24/2020 at 3:03 AM, johnnie.black said:

Never seen it before, just changing the Unraid IP should never cause this.

 

Do you have any VMs? No idea if it would help but you could try recreating libvirt.img but that would mean re-creating all VMs, though you could backup current image first.

I tried that, no luck.

 

How do I get help with this? No one here is answering, no one on FB has an answer and putting in a ticket with Unraid directly just results in crickets as well.

 

You could try reddit /unraid

Hi there,

 

Apologies for the delay in getting back to you on this.  You did email support and this one just slipped through the cracks on us, so for that, I apologize.

 

First and foremost, do you have any VMs on the system at this point or are you just trying to create one now?  What happens if you go back to the IP address it was assigned previously?  Have you rebooted the server yet?  What other actions have to taken so far in attempts to resolve this?

 

This is a tricky one because we've never seen this particular issue before and the lack of replies in the forum is because I don't think anyone else has either.  We're definitely committed to working with you to figure it out, but it might take some back and forth to figure it out.

  • Author
1 hour ago, jonp said:

First and foremost, do you have any VMs on the system at this point or are you just trying to create one now? 

I was only running one before, it was a Ubuntu 18 VMs for DNS and DHCP. So this not coming back up caused some major issue and some very unhappy family members while I threw substitutes in place for it.

 

1 hour ago, jonp said:

What happens if you go back to the IP address it was assigned previously?

I have not tried this, but it would be quite difficult to do, as that IP/subnet is no longer routable on my network. I am also not too sure what this would prove either. If it works, then that would imply there is a config file somewhere that needs tweaking, and if it does not, well then it tells us nothing really.

 

1 hour ago, jonp said:

What other actions have to taken so far in attempts to resolve this?

I rebooted the server multiple times. I then disabled the VM engine, deleted the IMG file and re-enabled it, to no avail. I went digging through the configs to see where the port mapping was (but did not change anything), nothing mentions port 440. So I pulled the reports and read through them. Googled the error that comes up, with little success (there is *possibly* a RHL/LibVirt bug related to this, but I don't recall the date on that article and did not really understand the thread it was in).

 

And then I posted here and on the FB group.

 

1 hour ago, jonp said:

Apologies for the delay in getting back to you on this.  You did email support and this one just slipped through the cracks on us, so for that, I apologize.

Thank you for the apology.

 

It is possible that the IP change was co-incidental. Though the timing would imply it's not. When I did change the IP I had to go in and change the internal subnet for Docker as it overlapped with my desired subnet. This was a simple change in a config file. No idea if that could be related to the libvirt issue or not, but I figured I'd mention it. Other than that, the rest of the system appears to be 100% functional (including my dockers).

 

To get the log below, I turned off VM support, then clicked delete on the /mnt/user/system/libvirt/libvirt.img file. Then enabled it and clicked apply.

 

2020-05-21 00:11:03.848+0000: 12388: info : libvirt version: 5.10.0
2020-05-21 00:11:03.848+0000: 12388: info : hostname: Deepthought
2020-05-21 00:11:03.848+0000: 12388: error : virNetSocketNewListenTCP:440 : Unable to bind to port: Cannot assign requested address

 

Edited by lutiana

  • 2 weeks later...

Hi again,

 

The best advice I can give to try and restore Unraid's networking to a default state would be to delete the network.cfg and network-rules.cfg files from the 'config' folder on the flash device and try rebooting.  This will reset the network settings to default.  You may also need to delete your libvirt.img file and recreate it as well, but you can test without doing that first and see if just the network files will be enough.

 

On 5/29/2020 at 6:52 PM, lutiana said:

Googled the error that comes up, with little success (there is *possibly* a RHL/LibVirt bug related to this, but I don't recall the date on that article and did not really understand the thread it was in).

A link to what you were reading could be helpful in us determining if this was really a bug upstream or not.

  • Author
42 minutes ago, jonp said:

A link to what you were reading could be helpful in us determining if this was really a bug upstream or not.

I tried to look it up again, but most of what I found was years old (circa 2011) or referred to live migrating VMs from one host to another.

 

44 minutes ago, jonp said:

Hi again,

 

The best advice I can give to try and restore Unraid's networking to a default state would be to delete the network.cfg and network-rules.cfg files from the 'config' folder on the flash device and try rebooting.  This will reset the network settings to default.  You may also need to delete your libvirt.img file and recreate it as well, but you can test without doing that first and see if just the network files will be enough.

So I decided to give this a go, but first I figured I'd delete the libvirt.img file (again, for like the 10th time). But this time I decided to turn off VM support, delete the downloaded ISO and the .img file. Then for the hell of it, I rebooted.

 

When it came back up, I turned on VM support, and this time it started without issue. This is odd, since I did all of this two weeks ago with no luck, though maybe not in this exact order.

 

For future reference, is there a way to get more detailed logs from libvirt on unraid?

Archived

This topic is now archived and is closed to further replies.

Account

Navigation

Search

Search

Configure browser push notifications

Chrome (Android)
  1. Tap the lock icon next to the address bar.
  2. Tap Permissions → Notifications.
  3. Adjust your preference.
Chrome (Desktop)
  1. Click the padlock icon in the address bar.
  2. Select Site settings.
  3. Find Notifications and adjust your preference.