summaryrefslogtreecommitdiff
diff options
context:
space:
mode:
authorRaphaël Hertzog <hertzog@debian.org>2018-02-24 17:04:04 +0100
committerRaphaël Hertzog <hertzog@debian.org>2018-02-24 17:04:04 +0100
commit842e971a65edf049a33dbba738d30c8c7edb85bc (patch)
tree8fc0b89be023112bd118401710385e8384d4c723
parentee8d06c46cfa30fb0c7d43fde5d4f8dfef3967c4 (diff)
downloadvyos-live-build-842e971a65edf049a33dbba738d30c8c7edb85bc.tar.gz
vyos-live-build-842e971a65edf049a33dbba738d30c8c7edb85bc.zip
Run mksquashfs with nice -n 19 to not overload the system
Machines tend to become unresponsive during the mksquashfs step. Avoid this by lowering the priority of the process. Thanks: Ronny Standtke for the patch. Closes: #867539
-rwxr-xr-xscripts/build/binary_rootfs4
1 files changed, 2 insertions, 2 deletions
diff --git a/scripts/build/binary_rootfs b/scripts/build/binary_rootfs
index 6c797acb3..d50cf3b43 100755
--- a/scripts/build/binary_rootfs
+++ b/scripts/build/binary_rootfs
@@ -352,7 +352,7 @@ case "${LB_CHROOT_FILESYSTEM}" in
fi
# Create image
- Chroot chroot "mksquashfs chroot filesystem.squashfs ${MKSQUASHFS_OPTIONS}"
+ Chroot chroot "nice -n 19 mksquashfs chroot filesystem.squashfs ${MKSQUASHFS_OPTIONS}"
rm -f chroot/chroot/excludes
@@ -413,7 +413,7 @@ case "${LB_CHROOT_FILESYSTEM}" in
MKSQUASHFS_OPTIONS="${MKSQUASHFS_OPTIONS} -wildcards -ef config/rootfs/excludes"
fi
- mksquashfs chroot binary/${INITFS}/filesystem.squashfs ${MKSQUASHFS_OPTIONS}
+ nice -n 19 mksquashfs chroot binary/${INITFS}/filesystem.squashfs ${MKSQUASHFS_OPTIONS}
du -B 1 -s chroot | cut -f1 > binary/${INITFS}/filesystem.size
;;