-
Notifications
You must be signed in to change notification settings - Fork 269
Bug 1854306: Set a 30s timeout for kubectl command in ovnkube-node #803
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
Bug 1854306: Set a 30s timeout for kubectl command in ovnkube-node #803
Conversation
|
@trozet @danwinship PTAL |
|
@pliurh: This pull request references Bugzilla bug 1854306, which is valid. The bug has been updated to refer to the pull request using the external bug tracker. 3 validation(s) were run on this bug
DetailsIn response to this:
Instructions for interacting with me using PR comments are available here. If you have questions or suggestions related to my behavior, please file an issue against the kubernetes/test-infra repository. |
|
/retest |
danwinship
left a comment
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
So under what circumstances is this a problem, and what exactly is the effect? If the apiserver eventually starts responding then won't the kubectl complete then? And if it doesn't eventually start responding then does it really matter if we bail out or keep waiting?
| while true; do | ||
| db_ip=$(kubectl get ep -n ${ovn_config_namespace} ovnkube-db -o jsonpath='{.subsets[0].addresses[0].ip}') | ||
| # wait 30s for kubectl get to return | ||
| # TODO: change to use '--request-timeout=30s', if https://github.com/kubernetes/kubernetes/issues/51952 is fixed. |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
oops, meant to comment here: the first part ("wait 30s for kubectl get to return") doesn't seem necessary (it's pretty obvious from either "timeout 30" or "--request-timeout=30s"). For the second part, that issue was closed as a duplicate of 49343, so link there instead?
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
fixed.
It happens during the SDN migration. After MCO trigger reboot, node come back with br-ex created, the ovnkube-node container will hang there for a long time with following logs. After the socket timeout in ~15mins, the pod will be restart, and then can work as expected. I suspect it was caused by the keepalived VIP floating. |
e499d20 to
d332515
Compare
By default the timeout of 'kubectl get' is infinity. If apiserver don't response, This command can take ~15min to fail(socket timeout). It's too long. This patch set a 30s timeout to 'kubectl get'.
d332515 to
454c986
Compare
|
/retest |
1 similar comment
|
/retest |
|
/retest |
|
/lgtm |
|
[APPROVALNOTIFIER] This PR is APPROVED This pull-request has been approved by: pliurh, trozet The full list of commands accepted by this bot can be found here. The pull request process is described here DetailsNeeds approval from an approver in each of these files:
Approvers can indicate their approval by writing |
|
/retest |
|
/retest Please review the full test history for this PR and help us cut down flakes. |
|
@pliurh: All pull requests linked via external trackers have merged:
Bugzilla bug 1854306 has been moved to the MODIFIED state. DetailsIn response to this:
Instructions for interacting with me using PR comments are available here. If you have questions or suggestions related to my behavior, please file an issue against the kubernetes/test-infra repository. |
By default the timeout of 'kubectl get' is infinity. If apiserver don't response,
This command can take ~15min to fail(socket timeout). It's too long. This patch
set a 30s timeout to 'kubectl get'.