1 2 3 4 5 6 7 8 9 10 11 12 13 14 15 16 17 18 19 20 21 22 23 24 25 26 27 28 29 30 31 32 33 34 35 36 37 38 39 40
|
--- a/modules.d/95nfs/nfs-start-rpc.sh
+++ b/modules.d/95nfs/nfs-start-rpc.sh
@@ -9,7 +9,7 @@
command -v portmap > /dev/null && [ -z "$(pidof portmap)" ] && portmap
if command -v rpcbind > /dev/null && [ -z "$(pidof rpcbind)" ]; then
mkdir -p /run/rpcbind
- chown rpc:rpc /run/rpcbind
+ chown _rpc:root /run/rpcbind
rpcbind
fi
--- a/modules.d/95nfs/parse-nfsroot.sh
+++ b/modules.d/95nfs/parse-nfsroot.sh
@@ -124,5 +124,5 @@
echo '[ -e $NEWROOT/proc ]' > "$hookdir"/initqueue/finished/nfsroot.sh
mkdir -p /var/lib/rpcbind
-chown rpc:rpc /var/lib/rpcbind
+chown _rpc:root /var/lib/rpcbind
chmod 770 /var/lib/rpcbind
--- a/modules.d/95nfs/module-setup.sh
+++ b/modules.d/95nfs/module-setup.sh
@@ -125,14 +125,14 @@
# Rather than copy the passwd file in, just set a user for rpcbind
# We'll save the state and restart the daemon from the root anyway
- grep -E '^nfsnobody:|^rpc:|^rpcuser:' "$dracutsysrootdir"/etc/passwd >> "$initdir/etc/passwd"
+ grep -E '^nfsnobody:|^_rpc:|^rpcuser:' "$dracutsysrootdir"/etc/passwd >> "$initdir/etc/passwd"
grep -E '^nogroup:|^rpc:|^nobody:' "$dracutsysrootdir"/etc/group >> "$initdir/etc/group"
# rpc user needs to be able to write to this directory to save the warmstart
# file
chmod 770 "$initdir/var/lib/rpcbind"
- grep -q '^rpc:' "$dracutsysrootdir"/etc/passwd \
- && grep -q '^rpc:' "$dracutsysrootdir"/etc/group
+ grep -q '^_rpc:' "$dracutsysrootdir"/etc/passwd \
+ && grep -q '^root:' "$dracutsysrootdir"/etc/group
dracut_need_initqueue
}
|