HADOOP-14343. Wrong pid file name in error message when starting secure daemon

Signed-off-by: Allen Wittenauer <aw@apache.org>
This commit is contained in:
Andras Bokor 2017-07-31 20:03:43 -07:00 committed by Allen Wittenauer
parent 1a78c0ff01
commit abbf4129a2
No known key found for this signature in database
GPG Key ID: E01B34FBE846DF38
1 changed files with 2 additions and 4 deletions

View File

@ -1873,11 +1873,9 @@ function hadoop_start_secure_daemon_wrapper
(( counter++ )) (( counter++ ))
done done
# this is for the daemon pid creation
#shellcheck disable=SC2086 #shellcheck disable=SC2086
echo $! > "${jsvcpidfile}" 2>/dev/null if ! echo $! > "${jsvcpidfile}"; then
if [[ $? -gt 0 ]]; then hadoop_error "ERROR: Cannot write ${daemonname} pid ${jsvcpidfile}."
hadoop_error "ERROR: Cannot write ${daemonname} pid ${daemonpidfile}."
fi fi
sleep 1 sleep 1