>From 3454fc91f7b9a3c7e4f45d0ec18b6d06be659cc2 Mon Sep 17 00:00:00 2001 From: Michael Shigorin Date: Mon, 26 Aug 2013 13:19:17 +0300 Subject: [PATCH 1/4] mki-image-prepare: work around protected_hardlinks There's an issue with Linux 3.6+ feature controlled via /proc/sys/fs/protected_hardlinks that is now enabled by default and destroys the assumtion mkimage uses heavily: being able to hardlink to others' files to spare space within the filesystem where workdirs are situated. And the script is actually cleaner this way. --- tools/mki-image-prepare | 7 ++----- 1 file changed, 2 insertions(+), 5 deletions(-) diff --git a/tools/mki-image-prepare b/tools/mki-image-prepare index 63faf1a..83e2896 100755 --- a/tools/mki-image-prepare +++ b/tools/mki-image-prepare @@ -27,10 +27,7 @@ inode2="$(stat -c '%i' "$chroot/.image/.fakedata")" [ "$inode1" != "$inode2" ] || exit 0 -mki-run chmod 666 /.fakedata -cat "$chroot"/.image/.fakedata >> "$chroot"/.fakedata -mki-run chmod 644 /.fakedata +mki-run sh -c "cat /.image/.fakedata >> /.fakedata" rm -f -- "$chroot"/.image/.fakedata - -ln -- "$chroot"/.fakedata "$chroot"/.image/.fakedata +mki-run ln -- /.fakedata /.image/.fakedata -- 1.8.3.4