Update libvirtd status checkpoint

Update search key word from "pid" to "running" to avoid check fail
if host running systemd.

Signed-off-by: Yanbing Du <ydu@redhat.com>
tests.cfg.dd_test: Fix the image bootindex bug

When image_boot is set, autotest assigns index = 1
which leads to duplicated indexes.

Signed-off-by: Lukáš Doktor <ldoktor@redhat.com>
netstress_kill_guest: update netperf configuration

netperf in Autotest already been updated to 2.6,
this patch just updated related configuration.

Signed-off-by: Amos Kong <akong@redhat.com>
timedrift_with_reboot.py: use the configurable timeout in reboot

Current vm.reboot() uses the default timeout(240), sometimes it's
too short for Windows guest.

Signed-off-by: Amos Kong <akong@redhat.com>
Acked-by: Lukas Doktor <ldoktor@redhat.com>
virtio_console: adjust the hardcode timeout to 720

Use a experienced reboot timeout 720.

Signed-off-by: Amos Kong <akong@redhat.com>
cartesian_config_unittest.py: Turn it into an executable

Following the convention of other unittests.

Signed-off-by: Lucas Meneghel Rodrigues <lmr@redhat.com>
cartesian_config_unittest.py: Fix indentation problem on RHEL6

Signed-off-by: Lucas Meneghel Rodrigues <lmr@redhat.com>
qemu.tests.virtio_console: Kill immortal background threads

Take care of freezed sender thread everywhere as in 66e657

Signed-off-by: Lukáš Doktor <ldoktor@redhat.com>
virtest.qemu_virtio_port: Disable serial-getty@hvc0.service

SystemD automatically spawns console on /dev/hvc0 if exists.
(even if it's not specified on initrd line). Since guest worker
uses hvc0 as plain pipe we have to mask this service.

Signed-off-by: Lukáš Doktor <ldoktor@redhat.com>
qemu.tests.virtio_console: Raise TestError when S3/S4 cmd is missing

Fail with error.TestError in case suspend or hibernate commands are
missing.

Signed-off-by: Lukáš Doktor <ldoktor@redhat.com>
virt_vm: Plug some more fd leaks

Close log files that are opened one time, such as the
ones opened for file transfers. This helps to reduce
even further the amount of files opened after a given
test job, specially if it involves a lot of file transfers.

With this patch, this test set:

./run -t qemu -g RHEL.6.3.x86_64 --nettype bridge --tests "migrate.with_autotest"

Comes from 94 files opened at the end to 43.

CC: Lei Yang <yanglei.fage@gmail.com>
Signed-off-by: Lucas Meneghel Rodrigues <lmr@redhat.com>
run: Avoid machine_type setting when using custom config

When custom config was used and default_guest_os was None,
the _process_machine_type added a DEFAULT_MACHINE_TYPE filter,
which might fail on configs without 'i440fx' variant.

Signed-off-by: Lukáš Doktor <ldoktor@redhat.com>
virt: Adds migration tests for dst problem.

1) Migration to read-only space.
2) Migration to low space destination.

Both migration uses exec protocol for migration to file.

qemu-kvm is started like Expect class not only like Tail.

Signed-off-by: Jiří Župka <jzupka@redhat.com>
virttest.bootstrap: Don't change a list when transversing it

Currently, when creating config files, autotest tries to find out
the config files that need to be overridden in testdir/cfg/*.cfg.

But it tries to pop the element for the list during traversing
itself, this is very dangerous, and it might cause an error when
running get_started.py, because the list wasn't updated yet, but
the transverse index wasn't updated.

Signed-off-by: Mike Qiu <qiudayu@linux.vnet.ibm.com>
virttest.qemu_installer: Autodetect qemu based on host arch

When detecting appropriate qemu names by default to run the
test suite, right now x86_64 is assumed. So, in order to
support other host architectures, such as ppc64, guess the
appropriate qemu name based on the host architecture.

Signed-off-by: Mike Qiu <qiudayu@linux.vnet.ibm.com>
virt-libvirt: virsh.net_state_dict() bugfix

Signed-off-by: Chris Evich <cevich@redhat.com>
virt: add virsh function for virsh {at|de}tach-disk.

Signed-off-by: Li Yang <liyang.fnst@cn.fujitsu.com>
virt: add virsh function for virsh update-device

Signed-off-by: Li Yang <liyang.fnst@cn.fujitsu.com>
virt-libvirt: Add configuration for virsh schedinfo(posix on qemu/kvm).

Signed-off-by: Yu Mingfei <yumingfei@cn.fujitsu.com>
virt-libvirt: Add configuration for virsh schedinfo(credit on xen).

Signed-off-by: Yu Mingfei <yumingfei@cn.fujitsu.com>