This could cause issues for people trying unattended non-graphical
kickstart installs and expecting ttyS0 in the guest to be hooked
up to the default console. So to get back the default behavior, you
can do:
--console pty
The XML we use is:
<clock offset="utc">
<timer name="rtc" tickpolicy="catchup"/>
<timer name="pit" tickpolicy="delay"/>
<timer name="hpet" present="no"/>
</clock>
Which translates to the qemu commands:
-no-hpet -no-kvm-pit-reinjection -rtc driftfix=slew
The latter two bits are already used by openstack and gnome boxes by
default.
On RHEL hpet is compiled out so -no-hpet is the default,
but not everywhere else. Though recently the RH guys confirmed that
for regular usage it should be turned off because a) qemu support
is not that good, b) most users don't need it anyways c) it has
a performance penalty.
This default can be overridden from a virt-install command like
--clock rtc_tickpolicy=delay
When Guest() sees that a timer has already been defined, it won't
set the new defaults, and that setting above is the old implied
default rtc setting.
These bits only apply if virt-manager is running directly on a RHEL6.
Since latest virt-manager can't do that thanks to GTK3 conversion,
just drop it all.
qcow2 enables fancy features like snapshots and is generally more
desktopy, which we purport to be.
We only do this on not horribly old libvirt/qemu, and only on qemu
connections. This may work for xen but I'm not going to turn it on
until someone tests it.
According to the changelog of libvirt http://libvirt.org/news.html,
the required version for stream console should be 0.8.6.
Please check the link: http://libvirt.org/news.html, libvirt started
to support virDomainOpenConsole() since "0.8.6: Nov 30 2010". And there
were also many changes related to stream console.
In practical terms, I have tested the change with libvirtd-0.8.8 in
Ubuntu 12.04.2 (x64) and another ARM port libvird-0.8.8. I think changing
to 0.8.6 should be fine because according to the changelog there are
no big changes in libvirt-0.8.7 and libvirt-0.8.8.
Signed-off-by: Ying-Shiuan Pan <yspan@itri.org.tw>
Some ARM bits we are about to add would substantially complicate the
current setup, so move all the logic into guest.py where we can be
more flexible. I think this is closer to what libosinfo will give us
as well.
These calls save us a few API lookups, but are not supported by all
libvirt versions.
Since these bits were getting quite large, move them all to a separate
pollhelpers file.
However listAllInterfaces is returning an empty list for now, so we
disable the check: https://bugzilla.redhat.com/show_bug.cgi?id=982014
This base connection object will be used to simplify the API in various
places, reduce libvirt API calls, and better share code between virtinst
and virt-manager. For now it just centralizes connection opening.
This also exposed various places where our handling for older libvirt
was busted, so raise our minimum host version to 0.6.0, the first
version that supports threaded client requests.
UPDATE_CPU flag exists after v0.8.0, so libvirt that
supports HOST_MODEL should support UPDATE_CPU,
the earliest version we are going to check is v0.9.10.