|
@@ -302,7 +302,11 @@ configGenCmd() {
|
|
|
validate_configuration
|
|
|
configcmd="${configgen_path}/configgen -env ${envfile} -od ${runtime} -id ${componentFile} -c ${compName}"
|
|
|
log "$configcmd"
|
|
|
- su ${user} -c "$configcmd" 2>/dev/null
|
|
|
+ if [ "${USER}" != "${user}" ]; then
|
|
|
+ su ${user} -c "$configcmd" 2>/dev/null
|
|
|
+ else
|
|
|
+ ${configcmd} 2>/dev/null
|
|
|
+ fi
|
|
|
rc=$?
|
|
|
if [[ $rc -ne 0 ]]; then
|
|
|
log "configGenCmd(): failure in configgen call"
|
|
@@ -335,6 +339,7 @@ createRuntime() {
|
|
|
chown -c $user:$group ${lock} 1> /dev/null 2>/dev/null
|
|
|
chown -c $user:$group ${log} 1> /dev/null 2>/dev/null
|
|
|
|
|
|
+ [ -z "$compName" ] && return
|
|
|
|
|
|
# Creating Component Specific directories
|
|
|
# Creating pidfile specific directory and changing its owner permissions
|
|
@@ -549,6 +554,8 @@ startCmd() {
|
|
|
stop_component() {
|
|
|
printf "Stopping %-21s" "${compName}... "
|
|
|
|
|
|
+ cd ${compPath}
|
|
|
+
|
|
|
####
|
|
|
## This is handling for when daemon is running as an orphan daemon. That is process is
|
|
|
## not running but associated pidfile and/or lockfiles do exist.
|