diff options
author | Yue Tao <Yue.Tao@windriver.com> | 2018-05-25 10:48:08 +0800 |
---|---|---|
committer | Richard Purdie <richard.purdie@linuxfoundation.org> | 2018-05-29 21:07:17 +0100 |
commit | c9fc9110be33fe0f24bc3a7c242b584a4ca33e04 (patch) | |
tree | 87c157cda9aa6be1cea690183e8d44c1312d7c53 | |
parent | 5256f95d553fc561786dd04b2c07882943e94e5d (diff) | |
download | poky-c9fc9110be33fe0f24bc3a7c242b584a4ca33e04.tar.gz |
initscripts: Avoid starting rpcbind daemon twice
Check the status before start it to avoid duplicates.
(From OE-Core rev: ca3ef7d1ef9b1f0dc4d3170b1ad20d5f725872a1)
Signed-off-by: Yue Tao <Yue.Tao@windriver.com>
Signed-off-by: Robert Yang <liezhi.yang@windriver.com>
Signed-off-by: Jeff Polk <jeff.polk@windriver.com>
Signed-off-by: Richard Purdie <richard.purdie@linuxfoundation.org>
-rwxr-xr-x | meta/recipes-core/initscripts/initscripts-1.0/mountnfs.sh | 9 |
1 files changed, 6 insertions, 3 deletions
diff --git a/meta/recipes-core/initscripts/initscripts-1.0/mountnfs.sh b/meta/recipes-core/initscripts/initscripts-1.0/mountnfs.sh index fe6c19605f..be9f5970fa 100755 --- a/meta/recipes-core/initscripts/initscripts-1.0/mountnfs.sh +++ b/meta/recipes-core/initscripts/initscripts-1.0/mountnfs.sh | |||
@@ -67,9 +67,12 @@ if test "$rpcbind" = yes | |||
67 | then | 67 | then |
68 | if test -x /usr/sbin/rpcbind | 68 | if test -x /usr/sbin/rpcbind |
69 | then | 69 | then |
70 | echo -n "Starting rpcbind... " | 70 | service rpcbind status > /dev/null |
71 | start-stop-daemon --start --quiet --exec /usr/sbin/rpcbind | 71 | if [ $? != 0 ]; then |
72 | sleep 2 | 72 | echo -n "Starting rpcbind..." |
73 | start-stop-daemon --start --quiet --exec /usr/sbin/rpcbind | ||
74 | sleep 2 | ||
75 | fi | ||
73 | fi | 76 | fi |
74 | fi | 77 | fi |
75 | 78 | ||