Skip to main content
Topic solved
This topic has been marked as solved and requires no further attention.
Topic: Problems with libvirtd (Read 1033 times) previous topic - next topic
0 Members and 1 Guest are viewing this topic.

Problems with libvirtd

So I noticed lately that whenever I try to open libvirtd I get error:
Code: [Select]
down: libvirtd: 0s, normally up, want up; run: log: (pid 1143) 33509s
And I'm genuinely not sure how to fix it. It used to work in last month but now It can't even run and I tried to install the service `sudo pacman -S libvirt-runit` but no luck

Re: Problems with libvirtd

Reply #1
First off, try running the libvirtd command in your shell and seeing if anything goes wrong.

Re: Problems with libvirtd

Reply #2
First off, try running the libvirtd command in your shell and seeing if anything goes wrong.

Sometimes it does start normally and sometimes it gives timeout but in both cases when I do status I get the messages that I already posted in my first post.

Code: [Select]
esmailelbob in ~ 
$ sudo sv start libvirtd
timeout: down: libvirtd: 1s, normally up, want up                                                                                                7.6s
esmailelbob in ~
$ sudo sv start libvirtd
ok: run: libvirtd: (pid 5609) 0s                                                                                                                 4.6s
esmailelbob in ~
$ sudo sv status libvirtd
down: libvirtd: 1s, normally up, want up; run: log: (pid 1138) 514s                                                                              0.0s
esmailelbob in ~

Re: Problems with libvirtd

Reply #3
No I meant try to run what's in the init script.

Re: Problems with libvirtd

Reply #4
No I meant try to run what's in the init script.

Oh my god what a such* good idea, how it did not come at my mind 😂

TDLR: it works, thank you for your amazing suggestion <3

Code: [Select]
esmailelbob in ~ 
$ sudo /etc/runit/sv/libvirtd/run
libvirt:  error : failed to open /var/log/libvirt/libvirtd.log: No such file or directory                                                        0.0s
esmailelbob in ~
$ touch /var/log/libvirt/libvirtd.log 
touch: cannot touch '/var/log/libvirt/libvirtd.log': No such file or directory                                                                   0.0s
esmailelbob in ~
$ mkdir /var/log/libvirt/      
mkdir: cannot create directory ‘/var/log/libvirt/’: Permission denied                                                                            0.0s
esmailelbob in ~
$ sudo mkdir /var/log/libvirt/                                                                                                                   0.0s
esmailelbob in ~
$ touch /var/log/libvirt/libvirtd.log
touch: cannot touch '/var/log/libvirt/libvirtd.log': Permission denied                                                                           0.0s
esmailelbob in ~
$ sudo touch /var/log/libvirt/libvirtd.log                                                                                                       0.0s
esmailelbob in ~
$ sudo /etc/runit/sv/libvirtd/run                                                                                                                0.0s
esmailelbob in ~
$ sudo sv status libvirtd           
run: libvirtd: (pid 3498) 17s; run: log: (pid 1138) 11541s                                                                                       0.0s
[EDIT: code tags]

Re: Problems with libvirtd

Reply #5
It seems like the runit init script should be updated to make /var/log/libvirt by default.

Re: Problems with libvirtd

Reply #6
It seems like the runit init script should be updated to make /var/log/libvirt by default.

I mean it used to work fine not sure what changed...but yeah it would be good idea

maybe something like,
cd /var/log/libvirt/ || mkdir /var/log/libvirt/  && touch /var/log/libvirt/libvirtd.log

Re: Problems with libvirtd

Reply #7
It seems like the runit init script should be updated to make /var/log/libvirt by default.

/var/log/libvirt is provided by the libvirt package, if a user willingly removes the directory it isn't service's fault.

Re: Problems with libvirtd

Reply #8
/var/log/libvirt is provided by the libvirt package, if a user willingly removes the directory it isn't service's fault.
Yes but it would be still a good touch for weird edge cases like mine...and I can assure you I removed nothing it's literally stopped out of no where (maybe bleachbit removed it as part of waste files)

Re: Problems with libvirtd

Reply #9
On a philosophical note:
It is not an edge case, just someone that let a tool does things on his computer (as root) without knowing what it does

On a packaging note:
Since it is a file provided by another package that is a dependence of the service there is absolutely no reason to check if it exists

On a general note:
Just use stuff as they are intended and be sure what tools do before executing them

 

Re: Problems with libvirtd

Reply #10
On a philosophical note:
It is not an edge case, just someone that let a tool does things on his computer (as root) without knowing what it does

On a packaging note:
Since it is a file provided by another package that is a dependence of the service there is absolutely no reason to check if it exists

On a general note:
Just use stuff as they are intended and be sure what tools do before executing them
as note, I never ran bleachbit as root

and yes this related to libvirt package itself not the service but if you can fix a bug or weird edge case (because again I did not run bleachbit as root) that maybe will happen in another 100 years I think it worth a shot because I see it as try to stop a bug not matter if its in package itself or service
maybe like elden ring and what steam did with proton instead waiting from software, I see it like that so correct me if I'm wrong

And for me I learned a new trick thanks to **Dudemanguy** so next time this service go down or really another service I will use this trick to fix it so for me it's solved but I talk about new people