we should be enabling CONFIG_LONG_OPTS=y in busybox when using systemd

On 3/1/21 8:53 AM, Vivien Didelot wrote:
If systemd is configured with importd, "machinectl import-*" can be
used to add container trees under /var/lib/machines.

But "machinectl import-tar" makes use of "tar --numeric-owner" which
is not supported by the busybox binary, as shown below:

     # machinectl import-tar /tmp/container.tar.xz
     Enqueued transfer job 1. Press C-c to continue download in background.
     Importing '/tmp/container.tar.xz', saving as 'container'.
     Imported 0%.
     tar: unrecognized option '--numeric-owner'
     BusyBox v1.31.1 () multi-call binary.
     Usage: tar c|x|t [-ZzJjahmvokO] [-f TARFILE] [-C DIR] [-T FILE] [-X FILE] 
[FILE]...
     Failed to decode and write: Broken pipe
     Exiting.

To fix this, recommend the standard tar package.

Cc: Chen Qi <[email protected]>
Signed-off-by: Vivien Didelot <[email protected]>
---
  meta/recipes-core/systemd/systemd_247.3.bb | 2 ++
  1 file changed, 2 insertions(+)

diff --git a/meta/recipes-core/systemd/systemd_247.3.bb 
b/meta/recipes-core/systemd/systemd_247.3.bb
index 1aac754cfc..3454085e5f 100644
--- a/meta/recipes-core/systemd/systemd_247.3.bb
+++ b/meta/recipes-core/systemd/systemd_247.3.bb
@@ -484,10 +484,12 @@ FILES_${PN}-container = 
"${sysconfdir}/dbus-1/system.d/org.freedesktop.import1.c
                           
${datadir}/polkit-1/actions/org.freedesktop.machine1.policy \
                          "
+# "machinectl import-tar" uses "tar --numeric-owner", not supported by busybox.
  RRECOMMENDS_${PN}-container += "\
                           ${PN}-journal-gatewayd \
                           ${PN}-journal-remote \
                           ${PN}-journal-upload \
+                         tar \
                          "
FILES_${PN}-extra-utils = "\





-=-=-=-=-=-=-=-=-=-=-=-
Links: You receive all messages sent to this group.
View/Reply Online (#148865): 
https://lists.openembedded.org/g/openembedded-core/message/148865
Mute This Topic: https://lists.openembedded.org/mt/81002411/21656
Group Owner: [email protected]
Unsubscribe: https://lists.openembedded.org/g/openembedded-core/unsub 
[[email protected]]
-=-=-=-=-=-=-=-=-=-=-=-

Reply via email to