Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Container pilot should log failed health check #267

Closed
rickardrosen opened this issue Jan 11, 2017 · 3 comments
Closed

Container pilot should log failed health check #267

rickardrosen opened this issue Jan 11, 2017 · 3 comments

Comments

@rickardrosen
Copy link

We spent some time trying to figure out why containerpilot did not register our container with service discovery (consul).

Turned out that, for whatever reason, we had the wrong path for our health check...
Our bad, but we could not see anything logged from containerpilot regarding the initial failed health check, even after enabling debug logging.

Even though this was a configuration error, it would be great to be able to pick this kind of issue up immediately through CP logging, or did we overlook something here?

@tgross
Copy link
Contributor

tgross commented Jan 11, 2017

Yeah, you definitely should be seeing logs if the command has the wrong path. RunWithTimeout is what runs the commands in the health check. Assuming your logging in debug you should be seeing something like this in that situation:

2017/01/11 09:00:00 mycommand.RunWithTimeout start
2017/01/11 09:00:00 mycommand.Cmd.Start
2017/01/11 09:00:00 Unable to start mycommand: command not found: /usr/bin/nonexistingcommand

So either there's a bug or something not quite right in the config. Can you provide the version of ContainerPilot you're using and some details about your logging configuration?

@tgross
Copy link
Contributor

tgross commented Mar 23, 2017

Without more information I believe this is another case of #295, which I'll be opening a backported fix for shortly.

@tgross
Copy link
Contributor

tgross commented Mar 24, 2017

Released in https://github.com/joyent/containerpilot/releases/tag/2.7.1. I'm going to mark this as fixed and close this issue, but feel free to reopen if it looks like we missed something.

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

No branches or pull requests

2 participants