Skip to content
This repository has been archived by the owner on Sep 17, 2021. It is now read-only.

Supervisorctl fails immediately on start #23

Closed
chadmay opened this issue Jul 14, 2014 · 8 comments
Closed

Supervisorctl fails immediately on start #23

chadmay opened this issue Jul 14, 2014 · 8 comments

Comments

@chadmay
Copy link

chadmay commented Jul 14, 2014

The supervisord process stays up with no issue, but when going to the next step in the quickstart "sudo -E supervisorctl -c security_monkey.ini", it fails every time. I am not an expert in Python, so getting a resolution here has been challenging. If you need further information, let me know.

2014-07-14 14:39:26,993 INFO exited: securitymonkey (exit status 1; not expected)
2014-07-14 14:39:26,993 DEBG received SIGCLD indicating a child quit
2014-07-14 14:39:27,994 INFO gave up: securitymonkey entered FATAL state, too many start retries too quickly
2014-07-14 14:39:28,997 INFO spawned: 'securitymonkeyscheduler' with pid 24468
2014-07-14 14:39:29,855 DEBG 'securitymonkeyscheduler' stderr output:
INFO:apscheduler.scheduler:Scheduler has been shut down

@tghaas
Copy link

tghaas commented Jul 15, 2014

Anyone find a fix for this? I'm getting similar errors:

2014-07-15 20:58:32,007 INFO: Scheduler started [in build/bdist.linux-x86_64/egg/apscheduler/scheduler.py:574]
2014-07-15 20:58:32,008 DEBUG: Looking for jobs to run [in build/bdist.linux-x86_64/egg/apscheduler/scheduler.py:579]
2014-07-15 20:58:32,008 DEBUG: No jobs left; shutting down scheduler [in build/bdist.linux-x86_64/egg/apscheduler/scheduler.py:595]
2014-07-15 20:58:32,008 INFO: Scheduler has been shut down [in build/bdist.linux-x86_64/egg/apscheduler/scheduler.py:606]

@scriptsrc
Copy link
Contributor

Supervisord launches two things. 1) securitymonkey and 2) securitymonkeyscheduler

The first runs the Flask web application. If you have that up, you can connect to the web interface and add a new account in the settings page (as long as you don't run into #16). Once you have added an account, the scheduler should have jobs to perform. You may need to restart the scheduler after adding the account.

@chadmay
Copy link
Author

chadmay commented Jul 16, 2014

I guess that's my problem after digging deeper. The #1 step isn't launching the web application. It's essentially failing here:
python /home/ubuntu/security_monkey/manage.py run_api_server
Traceback (most recent call last):
File "/home/ubuntu/security_monkey/manage.py", line 227, in
manager.run()
File "/usr/local/lib/python2.7/dist-packages/flask_script/init.py", line 412, in run
result = self.handle(sys.argv[0], sys.argv[1:])
File "/usr/local/lib/python2.7/dist-packages/flask_script/init.py", line 383, in handle
res = handle(_args, *_config)
File "/usr/local/lib/python2.7/dist-packages/flask_script/commands.py", line 216, in call
return self.run(_args, *_kwargs)
File "/usr/local/lib/python2.7/dist-packages/flask_script/commands.py", line 223, in run
raise NotImplementedError
NotImplementedError

@chadmay
Copy link
Author

chadmay commented Jul 17, 2014

Any help you can provide here, would be extremely appreciated, as I can't get past this issue or #24. I think both are related to run_api_server part failing, when starting supervisord.
python /home/ubuntu/security_monkey/manage.py run_api_server

@voiseyr
Copy link

voiseyr commented Oct 1, 2014

I don't think the 'Scheduler has been shut down' is an issue as i see that all the time and yet all my accounts are being scanned. I do need to restart the securitymonkey and securitymonkeyscheduler when i add a new account, but it does eventually start scanning.

@scriptsrc
Copy link
Contributor

We've moved to the system supervisor and the scanning starts immed. after starting up. There is no longer a 15 minute delay. Closing this issue. Any problems can be reopened in a new issue.

@hridyeshpant
Copy link

i am trying to setup security_monkey using https://github.com/Netflix-Skunkworks/zerotodocker/wiki/Security-Monkey link
but when running the final command
"docker run -i -d --name security_monkey-scheduler --link security_monkey-postgres:postgres -v pwd/boto.cfg:/etc/boto.cfg:ro netflixoss/security_monkey-scheduler:0.2.0"
i am getting error

INFO:apscheduler.scheduler:Scheduler has been shut down

Am i missing somethings here ?

@hridyeshpant
Copy link

when i am running "/usr/local/src/security_monkey/scripts/scheduler-start.sh" inside the container, below is the logs

2015-12-24 13:04:53,682 INFO: Scheduler started [in build/bdist.linux-x86_64/egg/apscheduler/scheduler.py:574]
2015-12-24 13:04:53,682 DEBUG: Looking for jobs to run [in build/bdist.linux-x86_64/egg/apscheduler/scheduler.py:579]
2015-12-24 13:04:53,683 DEBUG: No jobs left; shutting down scheduler [in build/bdist.linux-x86_64/egg/apscheduler/scheduler.py:595]
2015-12-24 13:04:53,683 INFO: Scheduler has been shut down [in build/bdist.linux-x86_64/egg/apscheduler/scheduler.py:606]

Sign up for free to subscribe to this conversation on GitHub. Already have an account? Sign in.
Labels
None yet
Projects
None yet
Development

No branches or pull requests

5 participants