summaryrefslogtreecommitdiff
diff options
context:
space:
mode:
authorRyan Harper <[email protected]>2018-03-22 15:32:50 -0400
committerScott Moser <[email protected]>2018-03-22 15:32:50 -0400
commitbd40234f2b2618eb84de03892a7028b71164e2f5 (patch)
treeacad2b3073e24f5813597b0406a1cba6d853f4fc
parent36bc81aeb09f07aa7e657a98553d7d4ce633ba67 (diff)
helpers/shell-archive: drop use of tar --sparse flagxx-current
Do not use tar [-S, --sparse] flag: at least one filesystem (btrfs) requires sync/fsync to ensure proper detection of sparse files. curtin doesn't contain any sparse files so this does not affect payload size. LP: #1757565
-rwxr-xr-xhelpers/shell-archive6
1 files changed, 4 insertions, 2 deletions
diff --git a/helpers/shell-archive b/helpers/shell-archive
index 3062e2aa..5c6c1fde 100755
--- a/helpers/shell-archive
+++ b/helpers/shell-archive
@@ -109,7 +109,8 @@ dump_bin() {
extract() {
mkdir "$2" || { error "failed to make '$2'"; return 1; }
- dump_bin "$1" | tar -Sxzf - -C "$2"
+ # Do not use tar [-S, --sparse] flag, see LP: #1757565
+ dump_bin "$1" | tar -xzf - -C "$2"
}
main() {
@@ -253,7 +254,8 @@ main() {
trap cleanup EXIT
local payload="${TEMP_D}/payload.tar.gz" md5=""
- tar -C "$archive_d" -Sczf "${payload}" . ||
+ # Do not use tar [-S, --sparse] flag, see LP: #1757565
+ tar -C "$archive_d" -czf "${payload}" . ||
{ error "failed to create archive from '${archive_d}'"; return 1; }
md5=$(md5sum < "$payload") ||