diff options
Diffstat (limited to 'main/busybox/busybox.post-upgrade')
-rw-r--r-- | main/busybox/busybox.post-upgrade | 11 |
1 files changed, 8 insertions, 3 deletions
diff --git a/main/busybox/busybox.post-upgrade b/main/busybox/busybox.post-upgrade index b478cbe0cb7..66fd1c49325 100644 --- a/main/busybox/busybox.post-upgrade +++ b/main/busybox/busybox.post-upgrade @@ -1,4 +1,4 @@ -#!/bin/sh +#!/bin/busybox sh # remove links that has been relocated or removed # - generate a list of all symlinks in bin dirs and a list with all busybox @@ -14,7 +14,6 @@ # - use sed to strip the leading and training ' chars # - finally pass the list to rm for removing the symlinks that points to # busybox but does not exist in the `busybox --list-all` list -cd / ( find bin sbin usr/bin usr/sbin -maxdepth 1 -type l; busybox --list-all) \ | sort | uniq -u \ | xargs -r stat -c "%N" 2>/dev/null \ @@ -29,4 +28,10 @@ for link in /bin/ping /bin/ping6; do done # We need the symlinks early -exec /bin/busybox --install -s +/bin/busybox --install -s || exit 1 + +# can't be in pre-upgrade since adduser/group may not available then +addgroup -S klogd 2>/dev/null +adduser -S -D -H -h /dev/null -s /sbin/nologin -G klogd -g klogd klogd 2>/dev/null + +exit 0 |