-
Notifications
You must be signed in to change notification settings - Fork 4.2k
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
Vault does not always respond to SIGTERM #5026
Comments
How long are you waiting after sending the signal? How can one reliably reproduce this? |
I can reproduce it with these steps using
|
|
I thought you were referencing the Vault server initially; right now the CLI doesn't respond to Ctrl-C, only agent and server do. |
@jefferai, CLI should respond to Ctrl-C, this is default *nix utils behaviour. But the issue is primary about vault agent - right now we have to restart service with |
I'm not disagreeing, I'm just telling you that currently it does not. Next time agent is hung, please send a SIGQUIT to get a stack trace and I can see where it's hung. With agent we do cancel a context that the HTTP library uses when you hit Ctrl+C, so if the issue is that context being canceled isn't working immediately there may be nothing we can do as the Go library may still be in the middle of something. It would also help to know your agent config. |
Please respond once you have a stack trace and I'll reopen. |
@jefferai Sorry for late response. Please see log in the attachment: Service shutdown triggered at 09:56:48 (with SIGTERM), and Vault agent responded in log accordingly. SIGQUIT sent at 09:57:13. Another log (from 0.11.1 vault): My config: pid_file = "/var/run/vault-agent.pid"
auto_auth {
method "gcp" {
config = {
type = "iam"
role = "test-role"
// credentials = ""
service_account = "[email protected]"
project = "kitchen-test-211905"
}
}
sink "file" {
config = {
path = "/tmp/vault/.token"
}
}
} |
@jefferai Hi, would you reopen the issue? |
Probably fixed via #5507 |
I see, thanks |
When vault binary is making an http request or vault is running in agent mode and performs server call it seems to ignore SIGTERM signal.
Steps to reproduce the behaviour:
vault status
on some firewalled portOR
nohup vault agent -config ...
kill -SIGTERM <vault_pid>
Expected behavior
Vault should abort http request and exit
Environment:
vault status
): 0.10.4vault version
): 0.10.4The text was updated successfully, but these errors were encountered: