-
Notifications
You must be signed in to change notification settings - Fork 89
How to start virtual machine correct from the CLI? #2239
Replies: 1 comment · 3 replies
-
This doesn't feel like an Cockpit specific issue but I'll try to give some debugging points:
Cockpit itself uses |
Beta Was this translation helpful? Give feedback.
All reactions
-
Hi @jelly, my host operation system is a Ubuntu 24.04.2 server without any GUI. The vm operation system is the same. My workflow is logging in as unprivileged user via SSH (new login session), run the command I checked the qemu log of the VM. This is the log of a failed start process. The success version is nearly the same, except it uses
Pretty interesting is the syslog of the host. Here the failed try:
And here the working try:
So the problem is to create the virtual network interface For completeness, this is the syslog of the VM from failed boot process.
|
Beta Was this translation helpful? Give feedback.
All reactions
-
It could be something with libvirt networking not activating but slowly starting and having started when you try again? I'm afraid this goes over my head. |
Beta Was this translation helpful? Give feedback.
All reactions
-
That's possible. My idea was to create the network interface first (and maybe dry again) and then start the VM create network interface. But I have no idea how to do this. Do you have an idea, where I can ask? |
Beta Was this translation helpful? Give feedback.
All reactions
This discussion was converted from issue #2236 on July 23, 2025 08:36.
Uh oh!
There was an error while loading. Please reload this page.
-
I use cockpit to create virtual machines and I if need a VNC client. Most of the time I use the VMs headless and run it only if I need it because I use it for developing and testing server configurations. Therefore the easiest way is to start the VM is via terminal and script instead logging in in the web interface.
My script runs the command
virsh start <vm_name>
but most of the time, the VM is stopped/killed after the first time calling the command. If I run the command a second time, the VM starts and works. If I start the VM via cockpit web interface, the first try works every time.Do I need to add some extra parameters to start the VM via CLI like from the web interface?
Beta Was this translation helpful? Give feedback.
All reactions