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

Fake docker-client assigns random IPs to containers #59832

Conversation

shyamjvs
Copy link
Member

@k8s-ci-robot
Copy link
Contributor

@shyamjvs: Adding do-not-merge/release-note-label-needed because the release note process has not been followed.

One of the following labels is required "release-note", "release-note-action-required", or "release-note-none".
Please see: https://git.k8s.io/community/contributors/devel/pull-requests.md#write-release-notes-if-needed.

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.

@k8s-ci-robot k8s-ci-robot added do-not-merge/release-note-label-needed Indicates that a PR should not merge because it's missing one of the release note labels. size/XS Denotes a PR that changes 0-9 lines, ignoring generated files. cncf-cla: yes Indicates the PR's author has signed the CNCF CLA. labels Feb 13, 2018
@shyamjvs shyamjvs added release-note-none Denotes a PR that doesn't merit a release note. and removed do-not-merge/release-note-label-needed Indicates that a PR should not merge because it's missing one of the release note labels. labels Feb 13, 2018
@shyamjvs
Copy link
Member Author

/test pull-kubernetes-kubemark-e2e-gce-big

To verify if we stop seeing those 422s for PUT endpoints calls.

@wojtek-t
Copy link
Member

@shyamjvs - two things:

  1. it seems it didn't really help
  2. bazel failure is a real one

@shyamjvs
Copy link
Member Author

shyamjvs commented Feb 14, 2018

I'll look into the bazel failure (which I guess is because of unit test failing).
And re "it didn't really help", it seems like there is a reduced no. of 422s (as compared to before when all updates starting form the 2nd one were returning 422s) - so it did help by some amount iiuc.

Let's wait for your run with debug statements to know more.

@wojtek-t
Copy link
Member

I'll look into the bazel failure (which I guess is because of unit test failing).

Yes - 2.3.4.5 is hardcoded somewhere.

And re "it didn't really help", it seems like there is a reduced no. of 422s (as compared to before when all updates starting form the 2nd one were returning 422s) - so it did help by some amount iiuc.

Agree - it helped somewhat, but I wouldn't expect any "BadRequest" errors coming from our components...

@wojtek-t
Copy link
Member

So what is happening is this:

AAA (Endpoints load-small-971-svc) subsets[0].addresses[0].ip: Invalid value: "127.68.255.188": may not be in the loopback range (127       .0.0.0/8)

You need to generate addresse that will pass this validation:
https://github.com/kubernetes/kubernetes/blob/master/pkg/apis/core/validation/validation.go#L4760

@wojtek-t
Copy link
Member

In particular, what you seem to break is this function:
https://github.com/kubernetes/kubernetes/blob/master/pkg/apis/core/validation/validation.go#L4782

@shyamjvs
Copy link
Member Author

Thanks a lot for looking into it @wojtek-t. I'll fix it by making the IP address always start with 10 (i.e 10.x.x.x) which should avoid all those failure conditions in that function.

@shyamjvs shyamjvs force-pushed the fix-fake-docker-client-ip-collision branch from 6296f07 to 113844f Compare February 14, 2018 12:47
@k8s-ci-robot k8s-ci-robot added size/S Denotes a PR that changes 10-29 lines, ignoring generated files. and removed size/XS Denotes a PR that changes 0-9 lines, ignoring generated files. labels Feb 14, 2018
@shyamjvs shyamjvs force-pushed the fix-fake-docker-client-ip-collision branch from 113844f to b54aa14 Compare February 14, 2018 12:53
@k8s-ci-robot k8s-ci-robot added size/M Denotes a PR that changes 30-99 lines, ignoring generated files. and removed size/S Denotes a PR that changes 10-29 lines, ignoring generated files. labels Feb 14, 2018
@shyamjvs
Copy link
Member Author

Fixed the unit test (hopefully) by using a deterministic random seed.
Also creating valid random IPs in the docker mock now.

@wojtek-t PTAL

@shyamjvs
Copy link
Member Author

/test pull-kubernetes-kubemark-e2e-gce-big

@shyamjvs shyamjvs force-pushed the fix-fake-docker-client-ip-collision branch from b54aa14 to 517301d Compare February 14, 2018 13:29
@wojtek-t
Copy link
Member

I verified the impact on: #59807
In short:

  • no more 422 errors
  • 2x+ more memory allocations (~100GB coming from serialization)
    Both are expected and so this issues seems to be fixed now.

/lgtm
/approve

@k8s-ci-robot k8s-ci-robot added the lgtm "Looks good to me", indicates that a PR is ready to be merged. label Feb 14, 2018
@k8s-ci-robot
Copy link
Contributor

[APPROVALNOTIFIER] This PR is APPROVED

This pull-request has been approved by: shyamjvs, wojtek-t

The full list of commands accepted by this bot can be found here.

The pull request process is described here

Needs approval from an approver in each of these OWNERS Files:

Approvers can indicate their approval by writing /approve in a comment
Approvers can cancel approval by writing /approve cancel in a comment

@k8s-ci-robot k8s-ci-robot added the approved Indicates a PR has been approved by an approver from all required OWNERS files. label Feb 14, 2018
@k8s-github-robot
Copy link

/test all [submit-queue is verifying that this PR is safe to merge]

@shyamjvs
Copy link
Member Author

Thanks @wojtek-t. To add to it, the aggregate.Errors() are no longer seen in the memory profile (so this change pretty much seems to reduce all of that alloc space). Ref - https://storage.googleapis.com/kubernetes-jenkins/pr-logs/pull/59807/pull-kubernetes-kubemark-e2e-gce-big/16/artifacts/profiles/ApiserverMemoryProfile_load.pdf

@k8s-ci-robot
Copy link
Contributor

k8s-ci-robot commented Feb 14, 2018

@shyamjvs: The following test failed, say /retest to rerun them all:

Test name Commit Details Rerun command
pull-kubernetes-kubemark-e2e-gce-big b54aa14e7a50acf58a9dc097ca8cf1c91be2bc31 link /test pull-kubernetes-kubemark-e2e-gce-big

Full PR test history. Your PR dashboard. Please help us cut down on flakes by linking to an open issue when you hit one in your PR.

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. I understand the commands that are listed here.

@k8s-github-robot
Copy link

Automatic merge from submit-queue. If you want to cherry-pick this change to another branch, please follow the instructions here.

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
approved Indicates a PR has been approved by an approver from all required OWNERS files. cncf-cla: yes Indicates the PR's author has signed the CNCF CLA. lgtm "Looks good to me", indicates that a PR is ready to be merged. release-note-none Denotes a PR that doesn't merit a release note. size/M Denotes a PR that changes 30-99 lines, ignoring generated files.
Projects
None yet
Development

Successfully merging this pull request may close these issues.

None yet

4 participants