O'Reilly logo

KVM Virtualization Cookbook by Konstantin Ivanov

Stay ahead with the world's most comprehensive technology and business learning platform.

With Safari, you learn the way you learn best. Get unlimited access to videos, live online training, learning paths, books, tutorials, and more.

Start Free Trial

No credit card required

How it works...

In this simple recipe, we enabled the autostart feature of a libvirt controlled KVM instance.

In step 1, we enabled autostart and verified that it has been enabled in step 2.

Next, to simulate a server restart, we first stop the running instance in step 3 and the libvirt daemon in step 4.

In step 5, we started the libvirt daemon back and observe that it started the virtual machine as well, as seen in step 6.

Finally, in steps 7 and 8, we disable the autostart feature and ensure that it indeed has been disabled.

With Safari, you learn the way you learn best. Get unlimited access to videos, live online training, learning paths, books, interactive tutorials, and more.

Start Free Trial

No credit card required