Fixed
Created: Oct 3, 2013
Updated: Mar 5, 2016
Resolved Date: Dec 8, 2013
Previous ID: LIN5-6545, LIN6-3022
Found In Version: 6.0
Fix Version: 6.0
Severity: Severe
Applicable for: Wind River Linux 6
Component/s: Userspace
in wrlinux 5.0.1.
there is a bug in the nfs script for the create_directories function where the wrong state file is being checked
create_directories(){
echo -n 'creating NFS state directory: '
mkdir -p "$NFS_STATEDIR"
( cd "$NFS_STATEDIR"
umask 077
mkdir -p sm sm.bak
test -w sm/state || {
rm -f sm/state
:>sm/state
}
according to the sm-notify's man page:
FILES
/var/lib/nfs/sm directory containing monitor list
/var/lib/nfs/sm.bak directory containing notify list
/var/lib/nfs/state NSM state number for this host
also, the owner of the sm and sm.bak directories would need to be set as by default, the script creates the directories with root as owner.
It should be rpcuser
--- rootfs-orig/etc/init.d/nfscommon
+++ rootfs/etc/init.d/nfscommon
@@ -83,6 +83,7 @@ create_directories(){
umask 077
mkdir -p rpc_pipefs
mkdir -p sm sm.bak
+ chown rpcuser sm sm.bak
test -w sm/state || {
rm -f sm/state
:>sm/state
@@ -96,6 +97,7 @@ create_directories(){
}
done
)
+ chown rpcuser "$NFS_STATEDIR"
echo done
}
check nfscommon script