Bug 1016986 - Can not start openshift-node-web-proxy service on node
Summary: Can not start openshift-node-web-proxy service on node
Keywords:
Status: CLOSED CURRENTRELEASE
Alias: None
Product: OpenShift Online
Classification: Red Hat
Component: Containers
Version: 2.x
Hardware: Unspecified
OS: Unspecified
medium
medium
Target Milestone: ---
: ---
Assignee: Jhon Honce
QA Contact: libra bugs
URL:
Whiteboard:
Depends On:
Blocks:
TreeView+ depends on / blocked
 
Reported: 2013-10-09 06:06 UTC by Ma xiaoqiang
Modified: 2016-07-04 00:44 UTC (History)
1 user (show)

Fixed In Version:
Doc Type: Bug Fix
Doc Text:
Clone Of:
Environment:
Last Closed: 2013-10-17 13:34:14 UTC
Target Upstream Version:


Attachments (Terms of Use)

Description Ma xiaoqiang 2013-10-09 06:06:09 UTC
Description of problem:
Can not start openshift-node-web-proxy service on node


Version-Release number of selected component (if applicable):
devenv_3874


How reproducible:
always

Steps to Reproduce:
1.restart openshift-node-web-proxy service on node
#/etc/init.d/openshift-node-web-proxy restart
2.check the status of the service
#/etc/init.d/openshift-node-web-proxy status


Actual results:
Output:
web-proxy dead but pid file exists

# vim /usr/sbin/oo-diagnostics 
lines 38-43
 38 start() {
 39     echo -n $"Starting node-web-proxy: "
 40     chown apache.apache /var/log/node-web-proxy/*.log >/dev/null 2>&1 || :
 41     export NODE_PATH="$nodesysmodulespath"
 42     nohup scl enable nodejs010 "$cmd" &> $logfile &
 43     pgrep -u 0 -f bin/node-supervisor > $pidfile
 44     retval=$?
 45     [ $retval -eq 0 ] && touch $lockfile && echo_success
 46     echo
Progress "node-supervisor" need some times to start in the line 42 , so program can not get correct pid in the line 43


Expected results:
The service should be running normally

Additional info:

Comment 1 openshift-github-bot 2013-10-09 20:45:02 UTC
Commit pushed to master at https://github.com/openshift/origin-server

https://github.com/openshift/origin-server/commit/08d2f89c7bdba339f9adab08757610992c0a2f9d
Bug 1016986 - Wait for node-web-proxy startup

* SCL version of nodejs introduced a delay in starting the supervisor

Comment 2 Ma xiaoqiang 2013-10-10 04:23:02 UTC
checked on devenv 3879
# /etc/init.d/openshift-node-web-proxy status
web-proxy (pid  1780) is running...
# /etc/init.d/openshift-node-web-proxy status
web-proxy (pid  1780) is running...
# /etc/init.d/openshift-node-web-proxy restart
Stopping node-web-proxy:                                   [  OK  ]
Starting node-web-proxy:                                   [  OK  ]
# /etc/init.d/openshift-node-web-proxy status 
web-proxy (pid  2856) is running...

check the code:
    nohup scl enable nodejs010 "$cmd" &> $logfile &

    for i in {1..30}; do
      pgrep -u 0 -f bin/node-supervisor > $pidfile
      retval=$?
      [ $retval -eq 0 ] && break
      sleep 1
    done

    [ $retval -eq 0 ] && touch $lockfile && echo_success


Note You need to log in before you can comment on or make changes to this bug.