Commit Graph

4988 Commits

Author SHA1 Message Date
Chen Hanxiao
911dac0dfa snapshot: start snapshot when double-click the item of snapshot list
Signed-off-by: Chen Hanxiao <chenhanxiao@gmail.com>
2016-08-02 13:20:15 -04:00
Cole Robinson
1d2cd30677 osdict: Fix incorrect usage of virtio input
Regression reported with latest libosinfo, when the OS reports
virtio-input support:

http://www.redhat.com/archives/virt-tools-list/2016-July/msg00109.html

Really our code presently only cares about the USB tablet, so adjust
our libosinfo lookup to explicitly check for it
2016-07-29 13:17:36 -04:00
Pavel Hrdina
9cdf78e94c translation: fix usage of translate function
Signed-off-by: Pavel Hrdina <phrdina@redhat.com>
2016-07-26 09:34:20 +02:00
Pavel Hrdina
810c73864a translation: mark some strings to be translated
Signed-off-by: Pavel Hrdina <phrdina@redhat.com>
2016-07-26 09:32:14 +02:00
Cole Robinson
158a1e0572 setup: test: up verbosity if --debug is passed 2016-07-20 18:15:27 -04:00
Cole Robinson
4727b31e61 cli: Ignore virt-viewer checks in test suite
Otherwise we can end up hanging with the default --wait behavior
2016-07-20 18:14:37 -04:00
Cole Robinson
d70fccd296 cli: Add helper for checking if we are in the test suite 2016-07-20 18:14:37 -04:00
Cole Robinson
322d212516 cli: Add --serial log.file= and log.append=
And for other character devices --console, --parallel, --channel
2016-07-18 15:04:40 -04:00
Cole Robinson
b08647c2f2 xmlbuilder: Handle setting conditional xpaths correctly
So if xml=<foo> and xpath=./bar[@baz='foo'] and val=XXX, xmlbuilder
previously would generate XML

  <foo>
    <bar>XXX</bar>
  </foo>

But now generates the expected

  <foo>
    <bar baz='foo'/>XXX</bar>
  </foo>

No users yet, but they are incoming
2016-07-18 14:46:50 -04:00
Cole Robinson
835ddc5f77 xmlbuilder: More comments for _build_xpath_node 2016-07-18 14:46:50 -04:00
Cole Robinson
a931a1a6ad xmlbuilder: Opencode single addnode= usage 2016-07-18 14:46:50 -04:00
Cole Robinson
559e813b96 xmlbuilder: Clarify the node 'pretty' helper function 2016-07-18 14:46:50 -04:00
Cole Robinson
d8a0a78805 xmlbuilder: Update XMLProperty docs 2016-07-18 14:46:50 -04:00
Cole Robinson
fb6548d344 tests: testdriver: add <sysinfo> example 2016-07-18 14:46:50 -04:00
Pavel Hrdina
023a55cb39 deviceinterface: disallow using source dev for ethernet interface
Device <interface type='ethernet'/> doesn't support <source dev=''/> attribute
and we should ignore it the same way as we do for <interface type='user'/>.

Signed-off-by: Pavel Hrdina <phrdina@redhat.com>
2016-07-08 18:02:07 +02:00
Pavel Hrdina
1bed021a00 tests.xmlparse: fix network test
Device <interface type='ethernet'/> doesn't support <source dev=''/> attribute.

Signed-off-by: Pavel Hrdina <phrdina@redhat.com>
2016-07-08 18:01:35 +02:00
Pavel Hrdina
ad133796b5 tests.testdriver: add usb controller if usbredir is used
Signed-off-by: Pavel Hrdina <phrdina@redhat.com>
2016-07-08 16:00:13 +02:00
Cole Robinson
6daff68a3f Update translations, and fix it.po problems
https://bugzilla.redhat.com/show_bug.cgi?id=1350185
2016-06-29 08:49:00 -04:00
Cole Robinson
9a67fc4d6e storagepool: Don't double invoke 'refresh' when events are present
We need to tweak refresh() handling to work similar to the shared
XML and status caching in libvirtobject.py: when the user manually
invokes the refresh() operation, and storage events are set up,
we just invoke the refresh() but let the event loop handle
refreshing the cache.

This fixes a backtrace when invoking a manual refresh via the
host details dialog
2016-06-23 15:38:31 -04:00
Cole Robinson
cdf5d32434 libvirtobject: Rename refresh_...->recache_from_event_loop
Since 'refresh' is kind of ambiguous now that we support pool
refresh events
2016-06-23 14:48:04 -04:00
Cole Robinson
61a4318f85 storagelist: Remove unused function 2016-06-21 19:15:43 -04:00
Cole Robinson
c5ce0ab512 connection: Fix transport detection for qemu://$HOST/system
In this case, when a host is specified but not a transport, libvirt
defaults to transport=tls
2016-06-21 11:31:26 -04:00
Cole Robinson
e69cc002b1 viewers: spice: Catch failure to setup usbdev manager
Since some distros like openbsd don't compile support for
usb redirection, which makes this fail

https://bugzilla.redhat.com/show_bug.cgi?id=1348479
2016-06-21 09:01:32 -04:00
Cole Robinson
6d587c40bb storagepool: Don't refresh newly arriving pools
If they show up while a connection is 'active', it means they were
just defined/created, and thus a pool refresh is likely redundant
2016-06-20 17:21:46 -04:00
Cole Robinson
53459cb0f6 conn: Don't process any pool REFRESHED events during conn startup
When new pool objects appear, we call refresh() on them, to ensure
we have the latest data (in case manual changes were made to the
storage pool directory behind libvirt's back, which is quite common).

However with the storage event support, this results in lots of
REFRESHED signals during initial connection startup, which kick
off redundant object polling.

Avoid storage REFRESHED events if they come in before the connection
is finished starting up to skip this redundant polling.
2016-06-20 17:07:26 -04:00
Cole Robinson
6a740ff91c conn: Build default pool before registering events
Otherwise this triggers some event calls and results in double
polling during connection startup. Doesn't cause any issues, just
spams the logs and needless libvirt calls
2016-06-20 17:03:12 -04:00
Cole Robinson
720ea801bc about: Update copyright year to 2016 2016-06-19 11:31:11 -04:00
Cole Robinson
b7d4267cd2 spec: Add dep on python2-devel
This is needed to pull in the __python2 RPM macro
2016-06-18 16:58:21 -04:00
Jovanka Gulicoska
b904d62e47 Use storage pool lifecycle events
API will be available in upcoming libvirt 2.0.0
2016-06-18 11:08:14 -04:00
Cole Robinson
296d7e922a Prep for release 1.4.0 2016-06-18 10:00:39 -04:00
Cole Robinson
4c87b5e541 tests: uitests: Fix with git 2016-06-17 19:30:45 -04:00
Cole Robinson
df5c688c11 tests_inject: Update to use standard --only option
Rather than custom --distro option. And fix the URL list
2016-06-17 18:41:50 -04:00
Cole Robinson
cf3a1cc1f0 appdata: Modernize, and translate it
This also revealed our translations were busted for .desktop files
as well, so rework the POTFILES.in generation to account for it
2016-06-17 18:06:07 -04:00
Cole Robinson
40e0354631 guest: Fix multiple address.type=pci auto allocate requests
And test it for aarch64, which is the only place it's really
interesting at the moment
2016-06-17 17:17:49 -04:00
Cole Robinson
118bf85cba Apparently -tt doesn't work with #!/usr/bin/env ... 2016-06-17 16:38:57 -04:00
Cole Robinson
20c2d5b6ff delete: Don't offer to delete floppy media by default
Even if it's not marked readonly or shareable, floppy media is
very likely to be a shared resource and not something that belongs
to the VM that the user will want to delete by default.
2016-06-17 13:06:35 -04:00
Cole Robinson
47dd38eb3e Use #!/usr/bin/env for python scripts
This is recommended for upstream, but not for downstream, like Fedora.
So change /usr/bin/env to /usr/bin/python2 at RPM install time to
match the ideal Fedora config.

https://fedoraproject.org/wiki/Features/SystemPythonExecutablesUseSystemPython
https://bugzilla.redhat.com/show_bug.cgi?id=1303282
2016-06-17 12:56:14 -04:00
Richard W.M. Jones
246e3c9c59 virtinst: Add --transient flag.
If this flag is specified, --import|--boot will create a transient
libvirt domain, ie. one which goes away when the guest shuts down or
the host is rebooted.

(crobinso: some tweaks and tests)
2016-06-17 12:20:24 -04:00
Cole Robinson
f2d2630f45 virt-install: Uncontionally use domain.isActive()
It's been around for seven years, and even RHEL5 has it... I don't think
we need to work around platforms that don't have support for it.

Use this as an opportunity to simplify the surrounding code
2016-06-17 12:20:24 -04:00
Cole Robinson
81231530e5 tests: Add virt-install --wait test, and tweak the logic a bit 2016-06-17 12:13:21 -04:00
Cole Robinson
116fabb37a virt-install: Access domain in place via guest.domain
And stop returning the domain object from Guest.start_install, it's
redundant
2016-06-17 12:13:21 -04:00
Cole Robinson
0e8d4007cf tests: Add some virt-install autoconsole tests 2016-06-17 12:13:21 -04:00
Cole Robinson
59edd87e9f guest: Rename noboot -> doboot
It's a bit easier to follow the logic IMO
2016-06-17 12:13:21 -04:00
Cole Robinson
b5d0b381ba guest: Rename start_xml -> install_xml
Make it more clear what the case is
2016-06-17 12:13:21 -04:00
Cole Robinson
837a9710a3 guest: Use newer named CreateXML API
CreateLinux is the very old style name. CreateXML has been around
since at least 2009, which covers our minimum libvirt-python version
2016-06-17 08:58:28 -04:00
Cole Robinson
48ba2883e5 virtinst: break out kernel/initrd vol upload to its own file 2016-06-17 07:52:42 -04:00
Cole Robinson
dbb057d095 virtinst: Move initrdinject handling to its own file 2016-06-17 07:52:42 -04:00
Cole Robinson
9f297eda5b virtinst: guest: drop 'continue_install' concept
continue_install is intended to facilitate windows XP style 3 stage
installs:

  stage 1: initial dos style disk setup, reboot
  stage 2: actual full installer, reboot
  stage 3: OS is functional, virt-install is done

The code assumed that we needed to keep the cdrom as the primary
boot device for the second stage, so virt-install/virt-manager needed
to hang around through the second stage run, wait until the VM shutdown,
then encode the final XML to boot of the disk.

Windows is and always has been smart enough to handle that case though...
after the initial boot, if we set the hd as the primary boot device
for stage 2, the disk bits that windows already installed will make
use of the cdrom as necessary. So the entire premise of continue_install
is irrelevant. Maybe back when it was added, when xen didn't even have
working ACPI support, this served a purpose, but I'm pretty sure we
can safely drop it nowadays.
2016-06-17 07:52:42 -04:00
Cole Robinson
5398282e12 storage: Detect backing_store format automatically
By attempting to manage/import the passed path. This makes it
work via both virt-install and virt-manager

https://bugzilla.redhat.com/show_bug.cgi?id=1235406
2016-06-16 20:36:30 -04:00
Cole Robinson
8d4e58c501 cli: Add --disk backing_format= option 2016-06-16 20:09:37 -04:00