aboutsummaryrefslogtreecommitdiffstats
path: root/meta/recipes-connectivity/nfs-utils/nfs-utils/nfscommon
diff options
context:
space:
mode:
authorChen Qi <Qi.Chen@windriver.com>2014-11-07 00:25:14 -0500
committerChen Qi <Qi.Chen@windriver.com>2014-11-07 16:40:55 +0800
commit41d6a35dac417bcca956d3d1e1959d01fd2729ea (patch)
treebf2152b81a98f55918173dc115d810573283530c /meta/recipes-connectivity/nfs-utils/nfs-utils/nfscommon
parentd7a277b35bcc67050046c76fb70412101679a545 (diff)
downloadopenembedded-core-contrib-ChenQi/nfs-utils-rpcuser.tar.gz
nfs-utils: change owner/group of directories in do_installChenQi/nfs-utils-rpcuser
Previously, the owners/groups of directories like /var/lib/nfs/statd are changed in the init script, /etc/init.d/nfscommon. This is actually a workaround. We need to change them at do_install time. This patch fixes the above problem by changing owners/groups at do_install time. Besides, configuration option '--with-staduser=nobody' is changed to be '--with-statduser=rpcuser'. And /var/lib/nfs/statd/state is modified to have permission 0644, just like other distros (ubuntu, fedora, etc.) do. Signed-off-by: Chen Qi <Qi.Chen@windriver.com>
Diffstat (limited to 'meta/recipes-connectivity/nfs-utils/nfs-utils/nfscommon')
-rw-r--r--meta/recipes-connectivity/nfs-utils/nfs-utils/nfscommon27
1 files changed, 0 insertions, 27 deletions
diff --git a/meta/recipes-connectivity/nfs-utils/nfs-utils/nfscommon b/meta/recipes-connectivity/nfs-utils/nfs-utils/nfscommon
index 65fdd1dd4f..992267d5a1 100644
--- a/meta/recipes-connectivity/nfs-utils/nfs-utils/nfscommon
+++ b/meta/recipes-connectivity/nfs-utils/nfs-utils/nfscommon
@@ -28,33 +28,7 @@ test -n "$NFS_STATEDIR" || NFS_STATEDIR=/var/lib/nfs
#----------------------------------------------------------------------
# Startup and shutdown functions.
# Actual startup/shutdown is at the end of this file.
-#directories
-create_directories(){
- echo -n 'creating NFS state directory: '
- mkdir -p "$NFS_STATEDIR"
- ( cd "$NFS_STATEDIR"
- umask 077
- mkdir -p rpc_pipefs
- mkdir -p sm sm.bak statd
- chown rpcuser:rpcuser sm sm.bak statd
- test -w statd/state || {
- rm -f statd/state
- :>statd/state
- }
- umask 022
- for file in xtab etab smtab rmtab
- do
- test -w "$file" || {
- rm -f "$file"
- :>"$file"
- }
- done
- )
- chown rpcuser:rpcuser "$NFS_STATEDIR"
- echo done
-}
-#statd
start_statd(){
echo -n "starting statd: "
start-stop-daemon --start --exec "$NFS_STATD" --pidfile "$STATD_PID"
@@ -74,7 +48,6 @@ stop_statd(){
#FIXME: need to create the /var/lib/nfs/... directories
case "$1" in
start)
- create_directories
start_statd;;
stop)
stop_statd;;