diff options
author | Andrea Bolognani <abologna@redhat.com> | 2021-12-02 12:10:14 +0100 |
---|---|---|
committer | Daniel Berrangé <berrange@redhat.com> | 2021-12-03 09:12:27 +0000 |
commit | 2e2d3b84bc06feb88c7f16f7cf2c322a19c311e7 (patch) | |
tree | 1598fabf8016158d3abc409b3eaf0c2289668768 | |
parent | b8aa69477f04f342576ddacc7ee072392bb384b6 (diff) | |
download | virt-manager-2e2d3b84bc06feb88c7f16f7cf2c322a19c311e7.tar.gz |
installerinject: Use root:root instead of +0:+0 as owner
Commit c6b5f22fa61d started passing the --owner argument to
cpio when injecting files into the initrd to comply with the
more strict requirements introduced by systemd starting with
Fedora 30.
However, cpio only started accepting the +uid:+gid syntax in
version 2.12, which means that the fix actually broke the
initrd inject functionality completely in RHEL 7 and other
distros that don't include a recent enough cpio.
Use the user:group syntax instead, which is understood by
all versions of cpio, including non-GNU ones.
Signed-off-by: Andrea Bolognani <abologna@redhat.com>
-rw-r--r-- | virtinst/install/installerinject.py | 2 |
1 files changed, 1 insertions, 1 deletions
diff --git a/virtinst/install/installerinject.py b/virtinst/install/installerinject.py index 97742f6a..8445d21e 100644 --- a/virtinst/install/installerinject.py +++ b/virtinst/install/installerinject.py @@ -20,7 +20,7 @@ def _run_initrd_commands(initrd, tempdir): stderr=subprocess.PIPE, cwd=tempdir) cpio_proc = subprocess.Popen(['cpio', '--create', '--null', '--quiet', - '--format=newc', '--owner=+0:+0'], + '--format=newc', '--owner=root:root'], stdin=find_proc.stdout, stdout=subprocess.PIPE, stderr=subprocess.PIPE, |