[PATCH] qemuxmlconftest: Test 'page_per_vq' config option for 'vhostuser' backed disk
by Peter Krempa
Add a missing option for the test to prove that we parse/format this
option.
Signed-off-by: Peter Krempa <pkrempa(a)redhat.com>
---
Added to see whether the claim in
https://gitlab.com/libvirt/libvirt/-/issues/627
is true as I was fairly certain that virtio options are parsed commonly
and thus this should 'Just work'.
tests/qemuxmlconfdata/disk-vhostuser-numa.x86_64-4.2.0.args | 2 +-
tests/qemuxmlconfdata/disk-vhostuser-numa.x86_64-4.2.0.xml | 2 +-
tests/qemuxmlconfdata/disk-vhostuser-numa.x86_64-latest.args | 2 +-
tests/qemuxmlconfdata/disk-vhostuser-numa.x86_64-latest.xml | 2 +-
tests/qemuxmlconfdata/disk-vhostuser-numa.xml | 2 +-
5 files changed, 5 insertions(+), 5 deletions(-)
diff --git a/tests/qemuxmlconfdata/disk-vhostuser-numa.x86_64-4.2.0.args b/tests/qemuxmlconfdata/disk-vhostuser-numa.x86_64-4.2.0.args
index 7522be4582..2f52151245 100644
--- a/tests/qemuxmlconfdata/disk-vhostuser-numa.x86_64-4.2.0.args
+++ b/tests/qemuxmlconfdata/disk-vhostuser-numa.x86_64-4.2.0.args
@@ -32,7 +32,7 @@ XDG_CONFIG_HOME=/var/lib/libvirt/qemu/domain--1-QEMUGuest1/.config \
-chardev socket,id=chr-vu-virtio-disk0,path=/tmp/vhost1.sock \
-device vhost-user-blk-pci,bus=pci.0,addr=0x2,chardev=chr-vu-virtio-disk0,id=virtio-disk0,bootindex=1 \
-chardev socket,id=chr-vu-virtio-disk1,path=/tmp/vhost1.sock,reconnect=10 \
--device vhost-user-blk-pci,iommu_platform=on,ats=on,packed=on,bus=pci.0,addr=0x3,chardev=chr-vu-virtio-disk1,id=virtio-disk1 \
+-device vhost-user-blk-pci,iommu_platform=on,ats=on,packed=on,page-per-vq=on,bus=pci.0,addr=0x3,chardev=chr-vu-virtio-disk1,id=virtio-disk1 \
-audiodev '{"id":"audio1","driver":"none"}' \
-device virtio-balloon-pci,id=balloon0,bus=pci.0,addr=0x4 \
-sandbox on,obsolete=deny,elevateprivileges=deny,spawn=deny,resourcecontrol=deny \
diff --git a/tests/qemuxmlconfdata/disk-vhostuser-numa.x86_64-4.2.0.xml b/tests/qemuxmlconfdata/disk-vhostuser-numa.x86_64-4.2.0.xml
index f1825f3a8d..d020923bc7 100644
--- a/tests/qemuxmlconfdata/disk-vhostuser-numa.x86_64-4.2.0.xml
+++ b/tests/qemuxmlconfdata/disk-vhostuser-numa.x86_64-4.2.0.xml
@@ -27,7 +27,7 @@
<address type='pci' domain='0x0000' bus='0x00' slot='0x02' function='0x0'/>
</disk>
<disk type='vhostuser' device='disk' snapshot='no'>
- <driver name='qemu' type='raw' iommu='on' ats='on' packed='on'/>
+ <driver name='qemu' type='raw' iommu='on' ats='on' packed='on' page_per_vq='on'/>
<source type='unix' path='/tmp/vhost1.sock'>
<reconnect enabled='yes' timeout='10'/>
</source>
diff --git a/tests/qemuxmlconfdata/disk-vhostuser-numa.x86_64-latest.args b/tests/qemuxmlconfdata/disk-vhostuser-numa.x86_64-latest.args
index cbe9f9ef48..48bb792206 100644
--- a/tests/qemuxmlconfdata/disk-vhostuser-numa.x86_64-latest.args
+++ b/tests/qemuxmlconfdata/disk-vhostuser-numa.x86_64-latest.args
@@ -31,7 +31,7 @@ XDG_CONFIG_HOME=/var/lib/libvirt/qemu/domain--1-QEMUGuest1/.config \
-chardev socket,id=chr-vu-virtio-disk0,path=/tmp/vhost1.sock \
-device '{"driver":"vhost-user-blk-pci","bus":"pci.0","addr":"0x2","chardev":"chr-vu-virtio-disk0","id":"virtio-disk0","bootindex":1}' \
-chardev socket,id=chr-vu-virtio-disk1,path=/tmp/vhost1.sock,reconnect=10 \
--device '{"driver":"vhost-user-blk-pci","iommu_platform":true,"ats":true,"packed":true,"bus":"pci.0","addr":"0x3","chardev":"chr-vu-virtio-disk1","id":"virtio-disk1"}' \
+-device '{"driver":"vhost-user-blk-pci","iommu_platform":true,"ats":true,"packed":true,"page-per-vq":true,"bus":"pci.0","addr":"0x3","chardev":"chr-vu-virtio-disk1","id":"virtio-disk1"}' \
-audiodev '{"id":"audio1","driver":"none"}' \
-device '{"driver":"virtio-balloon-pci","id":"balloon0","bus":"pci.0","addr":"0x4"}' \
-sandbox on,obsolete=deny,elevateprivileges=deny,spawn=deny,resourcecontrol=deny \
diff --git a/tests/qemuxmlconfdata/disk-vhostuser-numa.x86_64-latest.xml b/tests/qemuxmlconfdata/disk-vhostuser-numa.x86_64-latest.xml
index 0a2e40f496..9b62de174a 100644
--- a/tests/qemuxmlconfdata/disk-vhostuser-numa.x86_64-latest.xml
+++ b/tests/qemuxmlconfdata/disk-vhostuser-numa.x86_64-latest.xml
@@ -27,7 +27,7 @@
<address type='pci' domain='0x0000' bus='0x00' slot='0x02' function='0x0'/>
</disk>
<disk type='vhostuser' device='disk' snapshot='no'>
- <driver name='qemu' type='raw' iommu='on' ats='on' packed='on'/>
+ <driver name='qemu' type='raw' iommu='on' ats='on' packed='on' page_per_vq='on'/>
<source type='unix' path='/tmp/vhost1.sock'>
<reconnect enabled='yes' timeout='10'/>
</source>
diff --git a/tests/qemuxmlconfdata/disk-vhostuser-numa.xml b/tests/qemuxmlconfdata/disk-vhostuser-numa.xml
index 49efbae0a2..2b72bac4a3 100644
--- a/tests/qemuxmlconfdata/disk-vhostuser-numa.xml
+++ b/tests/qemuxmlconfdata/disk-vhostuser-numa.xml
@@ -22,7 +22,7 @@
<boot order='1'/>
</disk>
<disk type='vhostuser' device='disk'>
- <driver name='qemu' type='raw' iommu='on' ats='on' packed='on'/>
+ <driver name='qemu' type='raw' iommu='on' ats='on' packed='on' page_per_vq='on'/>
<source type='unix' path='/tmp/vhost1.sock'>
<reconnect enabled='yes' timeout='10'/>
</source>
--
2.44.0
7 months, 2 weeks
[PATCH v2] docs: ensure HTML/images are built before running reference tests
by Daniel P. Berrangé
The 'check-html-references' test will process the built HTML files,
so they must exist before it is run, along with any images that
they point to.
If using the older 'configure_file' command, no changes are needed
since that always gets executed at 'meson setup' time, rather than
at 'meson compile' time.
Signed-off-by: Daniel P. Berrangé <berrange(a)redhat.com>
---
docs/images/meson.build | 3 ++-
docs/logos/meson.build | 3 ++-
docs/meson.build | 1 +
3 files changed, 5 insertions(+), 2 deletions(-)
This is the only remaining unpushed patch from my previous v1
series, now I figured out how to make it compatible with old
meson (see last sentence in the commit message)
diff --git a/docs/images/meson.build b/docs/images/meson.build
index b9ab30fc91..f3e3dd50da 100644
--- a/docs/images/meson.build
+++ b/docs/images/meson.build
@@ -18,7 +18,8 @@ foreach file : docs_image_files
# This hack enables us to view the web pages
# from within the uninstalled build tree
if meson.version().version_compare('>=0.64.0')
- fs.copyfile(file)
+ imgfile = fs.copyfile(file)
+ install_web_deps += imgfile
else
configure_file(input: file, output: file, copy: true)
endif
diff --git a/docs/logos/meson.build b/docs/logos/meson.build
index c3f4c9f522..2d9d0fcbb0 100644
--- a/docs/logos/meson.build
+++ b/docs/logos/meson.build
@@ -26,7 +26,8 @@ foreach file : docs_logo_files
# This hack enables us to view the web pages
# from within the uninstalled build tree
if meson.version().version_compare('>=0.64.0')
- fs.copyfile(file)
+ logofile = fs.copyfile(file)
+ install_web_deps += logofile
else
configure_file(input: file, output: file, copy: true)
endif
diff --git a/docs/meson.build b/docs/meson.build
index 87d728213c..2dfe98ef62 100644
--- a/docs/meson.build
+++ b/docs/meson.build
@@ -360,6 +360,7 @@ if tests_enabled[0]
'--webroot',
meson.project_build_root() / 'docs'
],
+ depends: install_web_deps,
env: runutf8,
suite: 'script'
)
--
2.43.0
7 months, 2 weeks
[PATCH v2 0/3] Introduce SSH proxy
by Michal Privoznik
v2 of:
https://lists.libvirt.org/archives/list/devel@lists.libvirt.org/thread/QY...
diff to v1:
- rebased onto current master
- Worked in Dan's review
Michal Prívozník (3):
tools: Introduce SSH proxy
docs: Document SSH proxy
NEWS: Document SSH proxy feature
NEWS.rst | 5 +
docs/docs.rst | 3 +
docs/meson.build | 1 +
docs/nss.rst | 7 +
docs/ssh-proxy.rst | 68 ++++++
libvirt.spec.in | 33 +++
meson.build | 16 +-
meson_options.txt | 2 +
po/POTFILES | 1 +
tools/meson.build | 2 +
tools/ssh-proxy/30-libvirt-ssh-proxy.conf.in | 6 +
tools/ssh-proxy/meson.build | 25 ++
tools/ssh-proxy/ssh-proxy.c | 239 +++++++++++++++++++
13 files changed, 407 insertions(+), 1 deletion(-)
create mode 100644 docs/ssh-proxy.rst
create mode 100644 tools/ssh-proxy/30-libvirt-ssh-proxy.conf.in
create mode 100644 tools/ssh-proxy/meson.build
create mode 100644 tools/ssh-proxy/ssh-proxy.c
--
2.43.2
7 months, 2 weeks
[PATCH v2] qemu-options: Deprecate "-runas" and introduce "-run-with user=..." instead
by Thomas Huth
The old "-runas" option has the disadvantage that it is not visible
in the QAPI schema, so it is not available via the normal introspection
mechanisms. We've recently introduced the "-run-with" option for exactly
this purpose, which is meant to handle the options that affect the
runtime behavior. Thus let's introduce a "user=..." parameter here now
and deprecate the old "-runas" option.
Signed-off-by: Thomas Huth <thuth(a)redhat.com>
---
v2: Add missing part in qemu-options.hx as suggested by Philippe
docs/about/deprecated.rst | 6 ++++++
system/vl.c | 15 +++++++++++++++
qemu-options.hx | 15 +++++++++++----
3 files changed, 32 insertions(+), 4 deletions(-)
diff --git a/docs/about/deprecated.rst b/docs/about/deprecated.rst
index 3310df3274..fe69e2d44c 100644
--- a/docs/about/deprecated.rst
+++ b/docs/about/deprecated.rst
@@ -61,6 +61,12 @@ configurations (e.g. -smp drawers=1,books=1,clusters=1 for x86 PC machine) is
marked deprecated since 9.0, users have to ensure that all the topology members
described with -smp are supported by the target machine.
+``-runas`` (since 9.1)
+----------------------
+
+Use ``-run-with user=..`` instead.
+
+
User-mode emulator command line arguments
-----------------------------------------
diff --git a/system/vl.c b/system/vl.c
index 7756eac81e..b031427440 100644
--- a/system/vl.c
+++ b/system/vl.c
@@ -773,6 +773,10 @@ static QemuOptsList qemu_run_with_opts = {
.name = "chroot",
.type = QEMU_OPT_STRING,
},
+ {
+ .name = "user",
+ .type = QEMU_OPT_STRING,
+ },
{ /* end of list */ }
},
};
@@ -3586,6 +3590,7 @@ void qemu_init(int argc, char **argv)
break;
#if defined(CONFIG_POSIX)
case QEMU_OPTION_runas:
+ warn_report("-runas is deprecated, use '-run-with user=...' instead");
if (!os_set_runas(optarg)) {
error_report("User \"%s\" doesn't exist"
" (and is not <uid>:<gid>)",
@@ -3612,6 +3617,16 @@ void qemu_init(int argc, char **argv)
if (str) {
os_set_chroot(str);
}
+ str = qemu_opt_get(opts, "user");
+ if (str) {
+ if (!os_set_runas(str)) {
+ error_report("User \"%s\" doesn't exist"
+ " (and is not <uid>:<gid>)",
+ optarg);
+ exit(1);
+ }
+ }
+
break;
}
#endif /* CONFIG_POSIX */
diff --git a/qemu-options.hx b/qemu-options.hx
index cf61f6b863..3031479a15 100644
--- a/qemu-options.hx
+++ b/qemu-options.hx
@@ -4824,7 +4824,8 @@ DEF("runas", HAS_ARG, QEMU_OPTION_runas, \
SRST
``-runas user``
Immediately before starting guest execution, drop root privileges,
- switching to the specified user.
+ switching to the specified user. This option is deprecated, use
+ ``-run-with user=...`` instead.
ERST
DEF("prom-env", HAS_ARG, QEMU_OPTION_prom_env,
@@ -4990,13 +4991,15 @@ DEF("qtest-log", HAS_ARG, QEMU_OPTION_qtest_log, "", QEMU_ARCH_ALL)
#ifdef CONFIG_POSIX
DEF("run-with", HAS_ARG, QEMU_OPTION_run_with,
- "-run-with [async-teardown=on|off][,chroot=dir]\n"
+ "-run-with [async-teardown=on|off][,chroot=dir][user=username|uid:gid]\n"
" Set miscellaneous QEMU process lifecycle options:\n"
" async-teardown=on enables asynchronous teardown (Linux only)\n"
- " chroot=dir chroot to dir just before starting the VM\n",
+ " chroot=dir chroot to dir just before starting the VM\n"
+ " user=username switch to the specified user before starting the VM\n"
+ " user=uid:gid dito, but use specified user-ID and group-ID instead\n",
QEMU_ARCH_ALL)
SRST
-``-run-with [async-teardown=on|off][,chroot=dir]``
+``-run-with [async-teardown=on|off][,chroot=dir][user=username|uid:gid]``
Set QEMU process lifecycle options.
``async-teardown=on`` enables asynchronous teardown. A new process called
@@ -5013,6 +5016,10 @@ SRST
``chroot=dir`` can be used for doing a chroot to the specified directory
immediately before starting the guest execution. This is especially useful
in combination with -runas.
+
+ ``user=username`` or ``user=uid:gid`` can be used to drop root privileges
+ by switching to the specified user (via username) or user and group
+ (via uid:gid) immediately before starting guest execution.
ERST
#endif
--
2.45.0
7 months, 2 weeks
[PATCH 0/2] tests: fix very subtle bugs in 'read-big-pipe'
by Daniel P. Berrangé
Daniel P. Berrangé (2):
tests: fix hang in virshtest 'read-big-pipe' case
tests: fix two off-by-1 errors in read-big-pipe test
tests/virshtest.c | 6 +++---
1 file changed, 3 insertions(+), 3 deletions(-)
--
2.43.0
7 months, 2 weeks
[PATCH 00/35] vsh: Fix handling of commands and help - part 3 (virsh testing overhaul)
by Peter Krempa
Part 3 was supposed to be the refactor of the command parser but since
I wanted to add few tests I've noticed that there's a lot of old cruft
and many tests are skipped.
This series refactors virshtest and optimizes it to run multiple
commands with one virsh instance. Doing this allows us to do more
testing in the same run time allowing us to reduce the amount of
"expensive" tests.
Further down this removes all of the 'shell' test infra which was used
for virsh.
Peter Krempa (35):
virshtest: Prepare for testing against output files
virshtest: Allow to test failure of commands
virshtest: Filter multiple occurences of string to drop in
testFilterLine
virshtest: Add support for testing commands read from input file and
adapt alias tests
virshtest: Adapt 'echo --split' tests to DO_TEST_SCRIPT
virshtest: Drop some redundant 'echo' cases
virshtest: Adapt some 'escaping' tests via DO_TEST_SCRIPT
vrishtest: Prepare for simpler testing - echo tests
virshtest: Test against output files ("echo" tests)
virshtest: Drop string form of expected output data of "echo" tests
virshtest: Replace list and nodeinfo tests by equivalent
VIR_TEST_SCRIPT variant
virshtest: Adapt tests for domain id lookup and state query to
DO_TEST_SCRIPT
virshtest: Adapt 'blkiotune' tests to DO_TEST_SCRIPT
virshtest: Adapt 'iothread' tests to DO_TEST_SCRIPT
virshtest: Drop support for testing against hardcoded strings
virshtest: Adapt argument parsing tests from 'virsh-optparse'
virshtest: Adapt 'snapshot-create-as' arg handling tests from
'virsh-optparse'
virshtest: Adapt numeric option arg handling tests from
'virsh-optparse'
virshtest: Adapt 'event' option arg handling tests from
'virsh-optparse'
virshtest: Reimplement 'virsh-output' test
qemuxmlconftest: Adapt XMLs from 'virsh-cpuset' and
'virsh-define-dev-segfault' cases
virshtest: Adapt 'virsh-vcpupin' test
virshtest: Adapt 'virsh-int-overflow'
virshtest: Adapt 'virsh-schedinfo'
virshtest: Adapt 'virsh-start' and 'virsh-undefine' tests as
'lifecycle' case
virsh: Fix '--name' and '--parent' used together in
'(snapshot|checkpoint)-list' command
vsh: Allow non-interactive use of 'cd' command
virshtest: Adapt 'virsh-snapshot' test
virshtest: Adapt 'virsh-checkpoint' test
virshtest: Adapt 'virsh-read-bufsiz' and 'virsh-read-non-seekable'
virshtest: Adapt 'libvirtd-pool'
tests: Re-implement '(virsh|virt-admin)-self-test' directly in meson
tests: Reimplement 'libvirtd-fail' case directly in meson
virshtest: Adapt virsh-uriprecedence test case
tests: Drop 'test-lib.sh'
build-aux/syntax-check.mk | 6 +-
docs/manpages/virsh.rst | 17 +-
src/meson.build | 5 +
tests/libvirtd-fail | 16 -
tests/libvirtd-pool | 38 -
tests/meson.build | 39 +-
.../console-compat-crash.x86_64-latest.args | 46 +
.../console-compat-crash.x86_64-latest.xml | 65 ++
.../console-compat-crash.xml} | 36 +-
.../cpuset-invalid.x86_64-latest.err | 1 +
tests/qemuxmlconfdata/cpuset-invalid.xml | 12 +
tests/qemuxmlconftest.c | 2 +
tests/test-lib.sh | 280 ------
tests/virsh-checkpoint | 178 ----
tests/virsh-cpuset | 46 -
tests/virsh-int-overflow | 18 -
tests/virsh-optparse | 292 ------
tests/virsh-output | 29 -
tests/virsh-output-commands | 94 --
tests/virsh-output.out | 496 ----------
tests/virsh-read-bufsiz | 49 -
tests/virsh-read-non-seekable | 51 -
tests/virsh-schedinfo | 40 -
tests/virsh-self-test | 48 -
tests/virsh-snapshot | 233 -----
tests/virsh-start | 41 -
tests/virsh-undefine | 76 --
tests/virsh-uriprecedence | 97 --
tests/virsh-vcpupin | 100 --
tests/virshtest.c | 878 +++++++-----------
tests/virshtestdata/argument-assignment.in | 15 +
tests/virshtestdata/argument-assignment.out | 91 ++
tests/virshtestdata/attach-disk.in | 79 ++
tests/virshtestdata/attach-disk.out | 343 +++++++
tests/virshtestdata/blkiotune.in | 3 +
tests/virshtestdata/blkiotune.out | 15 +
tests/virshtestdata/checkpoint-c2.xml | 41 +
tests/virshtestdata/checkpoint-c3.xml | 38 +
tests/virshtestdata/checkpoint-redefine.out | 13 +
tests/virshtestdata/checkpoint.in | 35 +
tests/virshtestdata/checkpoint.out | 133 +++
tests/virshtestdata/dash-dash-argument-1.out | 1 +
tests/virshtestdata/dash-dash-argument-2.out | 1 +
tests/virshtestdata/dash-dash-argument-3.out | 1 +
tests/virshtestdata/dash-dash-argument-4.out | 1 +
tests/virshtestdata/dash-dash-argument-5.out | 1 +
tests/virshtestdata/dash-dash-argument-6.out | 1 +
tests/virshtestdata/domain-id-overflow.out | 3 +
tests/virshtestdata/domain-id.in | 18 +
tests/virshtestdata/domain-id.out | 73 ++
tests/virshtestdata/echo-alias-argv.out | 1 +
tests/virshtestdata/echo-alias.in | 3 +
tests/virshtestdata/echo-alias.out | 3 +
tests/virshtestdata/echo-escaping-1.out | 2 +
tests/virshtestdata/echo-escaping-2.out | 2 +
tests/virshtestdata/echo-escaping-3.out | 2 +
tests/virshtestdata/echo-escaping.in | 11 +
tests/virshtestdata/echo-escaping.out | 11 +
tests/virshtestdata/echo-quote-removal-1.out | 1 +
tests/virshtestdata/echo-quote-removal-2.out | 1 +
tests/virshtestdata/echo-quote-removal-3.out | 1 +
tests/virshtestdata/echo-quote-removal-4.out | 1 +
tests/virshtestdata/echo-quote-removal-5.out | 1 +
tests/virshtestdata/echo-quote-removal-6.out | 1 +
tests/virshtestdata/echo-quote-removal-7.out | 2 +
tests/virshtestdata/echo-quote-removal-8.out | 1 +
tests/virshtestdata/echo-split.in | 5 +
tests/virshtestdata/echo-split.out | 24 +
tests/virshtestdata/info-custom.in | 2 +
tests/virshtestdata/info-custom.out | 15 +
tests/virshtestdata/info-default.in | 2 +
tests/virshtestdata/info-default.out | 13 +
tests/virshtestdata/iothreads.in | 14 +
tests/virshtestdata/iothreads.out | 51 +
tests/virshtestdata/lifecycle.in | 23 +
tests/virshtestdata/lifecycle.out | 106 +++
tests/virshtestdata/multiple-commands-1.out | 2 +
tests/virshtestdata/multiple-commands-10.out | 1 +
tests/virshtestdata/multiple-commands-11.out | 1 +
tests/virshtestdata/multiple-commands-12.out | 1 +
tests/virshtestdata/multiple-commands-2.out | 2 +
tests/virshtestdata/multiple-commands-3.out | 2 +
tests/virshtestdata/multiple-commands-4.out | 2 +
tests/virshtestdata/multiple-commands-5.out | 3 +
tests/virshtestdata/multiple-commands-6.out | 1 +
tests/virshtestdata/multiple-commands-7.out | 2 +
tests/virshtestdata/multiple-commands-8.out | 2 +
tests/virshtestdata/multiple-commands-9.out | 1 +
tests/virshtestdata/numeric-parsing-event.in | 26 +
tests/virshtestdata/numeric-parsing-event.out | 10 +
tests/virshtestdata/numeric-parsing.in | 43 +
tests/virshtestdata/numeric-parsing.out | 12 +
tests/virshtestdata/pool-define-as.out | 12 +
tests/virshtestdata/read-big-pipe.out | 7 +
.../schedinfo-invalid-argument.out | 5 +
tests/virshtestdata/snapshot-create-args.in | 9 +
tests/virshtestdata/snapshot-create-args.out | 82 ++
tests/virshtestdata/snapshot-redefine.out | 17 +
tests/virshtestdata/snapshot-s2.xml | 43 +
tests/virshtestdata/snapshot-s3.xml | 40 +
tests/virshtestdata/snapshot.in | 54 ++
tests/virshtestdata/snapshot.out | 173 ++++
.../uriprecedence-LIBVIRT_DEFAULT_URI.out | 5 +
...riprecedence-VIRSH_DEFAULT_CONNECT_URI.out | 5 +
tests/virshtestdata/uriprecedence-param.out | 5 +
.../uriprecedence-xdg-config.out | 5 +
.../bad/libvirt/libvirt.conf | 1 +
.../good/libvirt/libvirt.conf | 1 +
tests/virshtestdata/vcpupin.in | 23 +
tests/virshtestdata/vcpupin.out | 26 +
tests/virt-admin-self-test | 1 -
tools/meson.build | 4 +-
tools/virsh-checkpoint.c | 18 +-
tools/virsh-snapshot.c | 18 +-
tools/vsh.c | 5 -
115 files changed, 2352 insertions(+), 2852 deletions(-)
delete mode 100755 tests/libvirtd-fail
delete mode 100755 tests/libvirtd-pool
create mode 100644 tests/qemuxmlconfdata/console-compat-crash.x86_64-latest.args
create mode 100644 tests/qemuxmlconfdata/console-compat-crash.x86_64-latest.xml
rename tests/{virsh-define-dev-segfault => qemuxmlconfdata/console-compat-crash.xml} (59%)
mode change 100755 => 100644
create mode 100644 tests/qemuxmlconfdata/cpuset-invalid.x86_64-latest.err
create mode 100644 tests/qemuxmlconfdata/cpuset-invalid.xml
delete mode 100644 tests/test-lib.sh
delete mode 100755 tests/virsh-checkpoint
delete mode 100755 tests/virsh-cpuset
delete mode 100755 tests/virsh-int-overflow
delete mode 100755 tests/virsh-optparse
delete mode 100755 tests/virsh-output
delete mode 100755 tests/virsh-output-commands
delete mode 100644 tests/virsh-output.out
delete mode 100755 tests/virsh-read-bufsiz
delete mode 100755 tests/virsh-read-non-seekable
delete mode 100755 tests/virsh-schedinfo
delete mode 100755 tests/virsh-self-test
delete mode 100755 tests/virsh-snapshot
delete mode 100755 tests/virsh-start
delete mode 100755 tests/virsh-undefine
delete mode 100755 tests/virsh-uriprecedence
delete mode 100755 tests/virsh-vcpupin
create mode 100644 tests/virshtestdata/argument-assignment.in
create mode 100644 tests/virshtestdata/argument-assignment.out
create mode 100755 tests/virshtestdata/attach-disk.in
create mode 100644 tests/virshtestdata/attach-disk.out
create mode 100644 tests/virshtestdata/blkiotune.in
create mode 100644 tests/virshtestdata/blkiotune.out
create mode 100644 tests/virshtestdata/checkpoint-c2.xml
create mode 100644 tests/virshtestdata/checkpoint-c3.xml
create mode 100644 tests/virshtestdata/checkpoint-redefine.out
create mode 100755 tests/virshtestdata/checkpoint.in
create mode 100644 tests/virshtestdata/checkpoint.out
create mode 100644 tests/virshtestdata/dash-dash-argument-1.out
create mode 100644 tests/virshtestdata/dash-dash-argument-2.out
create mode 100644 tests/virshtestdata/dash-dash-argument-3.out
create mode 100644 tests/virshtestdata/dash-dash-argument-4.out
create mode 100644 tests/virshtestdata/dash-dash-argument-5.out
create mode 100644 tests/virshtestdata/dash-dash-argument-6.out
create mode 100644 tests/virshtestdata/domain-id-overflow.out
create mode 100644 tests/virshtestdata/domain-id.in
create mode 100644 tests/virshtestdata/domain-id.out
create mode 100644 tests/virshtestdata/echo-alias-argv.out
create mode 100644 tests/virshtestdata/echo-alias.in
create mode 100644 tests/virshtestdata/echo-alias.out
create mode 100644 tests/virshtestdata/echo-escaping-1.out
create mode 100644 tests/virshtestdata/echo-escaping-2.out
create mode 100644 tests/virshtestdata/echo-escaping-3.out
create mode 100644 tests/virshtestdata/echo-escaping.in
create mode 100644 tests/virshtestdata/echo-escaping.out
create mode 100644 tests/virshtestdata/echo-quote-removal-1.out
create mode 100644 tests/virshtestdata/echo-quote-removal-2.out
create mode 100644 tests/virshtestdata/echo-quote-removal-3.out
create mode 100644 tests/virshtestdata/echo-quote-removal-4.out
create mode 100644 tests/virshtestdata/echo-quote-removal-5.out
create mode 100644 tests/virshtestdata/echo-quote-removal-6.out
create mode 100644 tests/virshtestdata/echo-quote-removal-7.out
create mode 100644 tests/virshtestdata/echo-quote-removal-8.out
create mode 100644 tests/virshtestdata/echo-split.in
create mode 100644 tests/virshtestdata/echo-split.out
create mode 100644 tests/virshtestdata/info-custom.in
create mode 100644 tests/virshtestdata/info-custom.out
create mode 100644 tests/virshtestdata/info-default.in
create mode 100644 tests/virshtestdata/info-default.out
create mode 100644 tests/virshtestdata/iothreads.in
create mode 100644 tests/virshtestdata/iothreads.out
create mode 100644 tests/virshtestdata/lifecycle.in
create mode 100644 tests/virshtestdata/lifecycle.out
create mode 100644 tests/virshtestdata/multiple-commands-1.out
create mode 100644 tests/virshtestdata/multiple-commands-10.out
create mode 100644 tests/virshtestdata/multiple-commands-11.out
create mode 100644 tests/virshtestdata/multiple-commands-12.out
create mode 100644 tests/virshtestdata/multiple-commands-2.out
create mode 100644 tests/virshtestdata/multiple-commands-3.out
create mode 100644 tests/virshtestdata/multiple-commands-4.out
create mode 100644 tests/virshtestdata/multiple-commands-5.out
create mode 100644 tests/virshtestdata/multiple-commands-6.out
create mode 100644 tests/virshtestdata/multiple-commands-7.out
create mode 100644 tests/virshtestdata/multiple-commands-8.out
create mode 100644 tests/virshtestdata/multiple-commands-9.out
create mode 100644 tests/virshtestdata/numeric-parsing-event.in
create mode 100644 tests/virshtestdata/numeric-parsing-event.out
create mode 100644 tests/virshtestdata/numeric-parsing.in
create mode 100644 tests/virshtestdata/numeric-parsing.out
create mode 100644 tests/virshtestdata/pool-define-as.out
create mode 100644 tests/virshtestdata/read-big-pipe.out
create mode 100644 tests/virshtestdata/schedinfo-invalid-argument.out
create mode 100644 tests/virshtestdata/snapshot-create-args.in
create mode 100644 tests/virshtestdata/snapshot-create-args.out
create mode 100644 tests/virshtestdata/snapshot-redefine.out
create mode 100644 tests/virshtestdata/snapshot-s2.xml
create mode 100644 tests/virshtestdata/snapshot-s3.xml
create mode 100755 tests/virshtestdata/snapshot.in
create mode 100644 tests/virshtestdata/snapshot.out
create mode 100644 tests/virshtestdata/uriprecedence-LIBVIRT_DEFAULT_URI.out
create mode 100644 tests/virshtestdata/uriprecedence-VIRSH_DEFAULT_CONNECT_URI.out
create mode 100644 tests/virshtestdata/uriprecedence-param.out
create mode 100644 tests/virshtestdata/uriprecedence-xdg-config.out
create mode 100644 tests/virshtestdata/uriprecedence-xdg/bad/libvirt/libvirt.conf
create mode 100644 tests/virshtestdata/uriprecedence-xdg/good/libvirt/libvirt.conf
create mode 100755 tests/virshtestdata/vcpupin.in
create mode 100644 tests/virshtestdata/vcpupin.out
delete mode 120000 tests/virt-admin-self-test
--
2.44.0
7 months, 2 weeks
[PATCH 00/13] Big CI update (and some bug fixes)
by Michal Privoznik
There's a lot happening here, but I did not find a way to split this any
better. It all started with me wanting to switch from Ubuntu 20.04 to
24.04 and resulted in this.
Firstly, Ubuntu 24.04 started to complain about a few things:
1) ASAN wasn't working (some missing .a archive). Fix is pending:
https://gitlab.com/libvirt/libvirt-ci/-/merge_requests/482
2) ASAN was complaining about some memleaks in qemuxmlconftest. When I
tried to run the test locally under valgrind I found out I can't.
This resulted in the first two patches. Mind you, after this, there
are still some tests which are unable to run under valgrind (do NOT
forget --trace-children=yes if the test binary uses mocks). Well,
they may get fixes later. Firstly, I need to understand what really
bother valgrind.
3) UBSAN complained about some undefined behavior. This was the hardest
to make sense out of, for me. But part of the fix is bumping glib so
yay! I guess.
And, since I'm dropping AlmaLinux 8, we get to generate website on
something newer.
Finally, green pipeline with these patches applied:
https://gitlab.com/MichalPrivoznik/libvirt/-/pipelines/1279666864
Michal Prívozník (13):
domaincapsmock: Drop link time dependency on virQEMUCapsGet()
qemuxml2argvmock: Drop link time dependency on qemuFDPassDirectNew()
testutilsqemu: Don't leak struct testQemuArgs::vdpafds
security: Fix return types of .probe callbacks
meson: Disable -fsanitize=function
gitlab-ci: Move website_job to Fedora 39
ci: Drop Fedora 38
ci: Drop Ubuntu 20.04
ci: Drop AlmaLinux 8
meson: Bump glib version to 2.58.0
ci: Introduce Fedora 40
ci: Introduce Ubuntu 24.04
ci: Introduce AlmaLinux 9
.gitlab-ci.yml | 6 +-
.../{almalinux-8.sh => almalinux-9.sh} | 8 +-
ci/buildenv/centos-stream-9.sh | 1 +
ci/buildenv/debian-12-cross-aarch64.sh | 1 +
ci/buildenv/debian-12-cross-armv6l.sh | 1 +
ci/buildenv/debian-12-cross-armv7l.sh | 1 +
ci/buildenv/debian-12-cross-i686.sh | 1 +
ci/buildenv/debian-12-cross-mips64el.sh | 1 +
ci/buildenv/debian-12-cross-mipsel.sh | 1 +
ci/buildenv/debian-12-cross-ppc64le.sh | 1 +
ci/buildenv/debian-12-cross-s390x.sh | 1 +
ci/buildenv/debian-12.sh | 1 +
ci/buildenv/debian-sid-cross-aarch64.sh | 1 +
ci/buildenv/debian-sid-cross-armv6l.sh | 1 +
ci/buildenv/debian-sid-cross-armv7l.sh | 1 +
ci/buildenv/debian-sid-cross-i686.sh | 1 +
ci/buildenv/debian-sid-cross-mips64el.sh | 1 +
ci/buildenv/debian-sid-cross-ppc64le.sh | 1 +
ci/buildenv/debian-sid-cross-s390x.sh | 1 +
ci/buildenv/debian-sid.sh | 1 +
ci/buildenv/fedora-39.sh | 1 +
...-mingw32.sh => fedora-40-cross-mingw32.sh} | 1 +
...-mingw64.sh => fedora-40-cross-mingw64.sh} | 1 +
ci/buildenv/{fedora-38.sh => fedora-40.sh} | 1 +
ci/buildenv/fedora-rawhide-cross-mingw32.sh | 1 +
ci/buildenv/fedora-rawhide-cross-mingw64.sh | 1 +
ci/buildenv/fedora-rawhide.sh | 1 +
.../{ubuntu-2004.sh => ubuntu-2404.sh} | 8 +-
...ux-8.Dockerfile => almalinux-9.Dockerfile} | 10 +-
ci/containers/centos-stream-9.Dockerfile | 1 +
.../debian-12-cross-aarch64.Dockerfile | 1 +
.../debian-12-cross-armv6l.Dockerfile | 1 +
.../debian-12-cross-armv7l.Dockerfile | 1 +
ci/containers/debian-12-cross-i686.Dockerfile | 1 +
.../debian-12-cross-mips64el.Dockerfile | 1 +
.../debian-12-cross-mipsel.Dockerfile | 1 +
.../debian-12-cross-ppc64le.Dockerfile | 1 +
.../debian-12-cross-s390x.Dockerfile | 1 +
ci/containers/debian-12.Dockerfile | 1 +
.../debian-sid-cross-aarch64.Dockerfile | 1 +
.../debian-sid-cross-armv6l.Dockerfile | 1 +
.../debian-sid-cross-armv7l.Dockerfile | 1 +
.../debian-sid-cross-i686.Dockerfile | 1 +
.../debian-sid-cross-mips64el.Dockerfile | 1 +
.../debian-sid-cross-ppc64le.Dockerfile | 1 +
.../debian-sid-cross-s390x.Dockerfile | 1 +
ci/containers/debian-sid.Dockerfile | 1 +
ci/containers/fedora-39.Dockerfile | 1 +
...ile => fedora-40-cross-mingw32.Dockerfile} | 3 +-
...ile => fedora-40-cross-mingw64.Dockerfile} | 3 +-
...ora-38.Dockerfile => fedora-40.Dockerfile} | 3 +-
.../fedora-rawhide-cross-mingw32.Dockerfile | 1 +
.../fedora-rawhide-cross-mingw64.Dockerfile | 1 +
ci/containers/fedora-rawhide.Dockerfile | 1 +
...2004.Dockerfile => ubuntu-2404.Dockerfile} | 11 +-
ci/gitlab/builds.yml | 113 ++++++++--------
ci/gitlab/containers.yml | 54 ++++----
ci/integration.yml | 24 ----
ci/lcitool/projects/libvirt.yml | 1 +
ci/manifest.yml | 40 +++---
meson.build | 15 ++-
src/libvirt_private.syms | 1 -
src/security/security_apparmor.c | 2 +-
src/security/security_selinux.c | 2 +-
src/util/glibcompat.c | 125 ------------------
src/util/glibcompat.h | 10 --
tests/domaincapsmock.c | 13 +-
tests/qemuxml2argvmock.c | 8 +-
tests/testutilsqemu.c | 1 +
69 files changed, 203 insertions(+), 305 deletions(-)
rename ci/buildenv/{almalinux-8.sh => almalinux-9.sh} (93%)
rename ci/buildenv/{fedora-38-cross-mingw32.sh => fedora-40-cross-mingw32.sh} (98%)
rename ci/buildenv/{fedora-38-cross-mingw64.sh => fedora-40-cross-mingw64.sh} (98%)
rename ci/buildenv/{fedora-38.sh => fedora-40.sh} (99%)
rename ci/buildenv/{ubuntu-2004.sh => ubuntu-2404.sh} (94%)
rename ci/containers/{almalinux-8.Dockerfile => almalinux-9.Dockerfile} (91%)
rename ci/containers/{fedora-38-cross-mingw32.Dockerfile => fedora-40-cross-mingw32.Dockerfile} (97%)
rename ci/containers/{fedora-38-cross-mingw64.Dockerfile => fedora-40-cross-mingw64.Dockerfile} (97%)
rename ci/containers/{fedora-38.Dockerfile => fedora-40.Dockerfile} (97%)
rename ci/containers/{ubuntu-2004.Dockerfile => ubuntu-2404.Dockerfile} (93%)
--
2.43.2
7 months, 2 weeks
[PATCH 00/12] fix many test failures in various build config scenarios
by Daniel P. Berrangé
I was annoyed that
meson build --auto-features=disabled -Dtests=enabled
will fail in unit tests. Rather than just fix that scenario, I went
down the rabbit hole and tested (almost) every single minimal build
option.
By that I mean I looked at meson_options.txt and got a list of every
option that has 'auto' as its default. I then attempted a minimal
build with only that enabled. I quickly found some options have
mandatory pre-requisite options, so I re-did the tests with such
deps present.
This uncovered many scenarios where we didn't use the right conditions
for tests. Surprisingly (at first, but not in retrospect) it also
found many places where the tests failed to depend on the earlier
build artifacts.
My test process was:
opts=$(grep auto meson_options.txt | sed -e 's/option(//' -e 's/,.*//' -e "s/'//g")
for opt in $opts
do
deps=`grep --before 1 "option('$opt'" meson_options.txt | grep dep: | head -1 | sed -e 's/# //' -e 's/dep:/-D/g' -e 's/$/=enabled/' -e 's/ -D/=enabled -D/g'`
echo "Try test $opt with $deps"
rm -rf build
meson setup build --auto-features=disabled -Dtests=enabled $deps -D$opt=enabled 1> opt-$opt.log 2>&1
meson test -C build --no-suite syntax-check --print-errorlogs 1>> opt-$opt.log 2>&1 ; done
done
Then to check results
grep '^Fail:' opt-*.log | grep -v 0
This is slow, but not as slow as you might think, because each
build is very minimal, so we're not actually building more than
300-400 files each time, rather than 1000's, and we're not running
as many tests either.
Might be interesting to get extensive test into CI.
Strictly speaking we care about the combinatorial expansion of
meson_options.txt, but that would be insanely slow and is likely
to be overkill.
Daniel P. Berrangé (12):
scripts/rpcgen: skip tests if tirpc is not present
tests: fix tests when test driver is disabled
meson: record which other options are a pre-requisite
docs: ensure HTML/images are built before running reference tests
src: ensure augeas test file is generated before running test
tests: build 'virsh' before running virsh-auth test
tests: build driver modules before virdrivermoduletest
test: conditionalize 'virsh-auth' on test driver
tests: always build securityselinuxhelper if libselinux is present
test: drop bogus check for YAJL from libxl test/mock
tests: don't run mdevctl test if lacking YAJL
src/node_device: don't overwrite error messages
docs/images/meson.build | 5 ++-
docs/logos/meson.build | 5 ++-
docs/meson.build | 1 +
meson_options.txt | 20 +++++++++
scripts/rpcgen/meson.build | 2 +-
src/meson.build | 6 ++-
src/node_device/node_device_driver.c | 2 -
tests/fchosttest.c | 9 ++--
tests/libxlmock.c | 4 +-
tests/libxlxml2domconfigtest.c | 4 +-
tests/meson.build | 67 ++++++++++++++++++----------
11 files changed, 87 insertions(+), 38 deletions(-)
--
2.43.0
7 months, 2 weeks
[PATCH 0/4] Introduce SSH proxy
by Michal Privoznik
*** BLURB HERE ***
Michal Prívozník (4):
datatypes: Declare g_autoptr cleanup functions for more public objects
tools: Introduce SSH proxy
docs: Document SSH proxy
NEWS: Document SSH proxy feature
NEWS.rst | 5 +
docs/docs.rst | 3 +
docs/meson.build | 1 +
docs/nss.rst | 7 +
docs/ssh-proxy.rst | 60 +++++
libvirt.spec.in | 27 +++
meson.build | 16 +-
meson_options.txt | 2 +
po/POTFILES | 1 +
src/datatypes.h | 16 ++
tools/meson.build | 2 +
tools/ssh-proxy/30-libvirt-ssh-proxy.conf.in | 10 +
tools/ssh-proxy/meson.build | 25 ++
tools/ssh-proxy/ssh-proxy.c | 233 +++++++++++++++++++
14 files changed, 407 insertions(+), 1 deletion(-)
create mode 100644 docs/ssh-proxy.rst
create mode 100644 tools/ssh-proxy/30-libvirt-ssh-proxy.conf.in
create mode 100644 tools/ssh-proxy/meson.build
create mode 100644 tools/ssh-proxy/ssh-proxy.c
--
2.43.2
7 months, 2 weeks
[PATCH 0/2] interface: Refactor code and fix old listing API when interface is unbound
by Peter Krempa
Patch 1/2 removes a pointless helper in favor of making an almost
identical function more universal, so that patch 2/2 then fixes all
cases in one place.
Peter Krempa (2):
interface_udev: Replace udevNumOfInterfacesByStatus by
udevListInterfacesByStatus
udevListInterfacesByStatus: Don't try to return NULL names
src/interface/interface_backend_udev.c | 84 +++++++++-----------------
1 file changed, 30 insertions(+), 54 deletions(-)
--
2.44.0
7 months, 2 weeks