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

Fix long lines in lastStart.txt not outputting in log outputs #19740

Merged
merged 1 commit into from
Oct 2, 2024

Conversation

spowelljr
Copy link
Member

Problem

bufio.NewScanner has a max token length of 64KB link, sudo runc list -f json was sometimes generating an output greater than 64KB, causing the following error when running minikube logs:

failed to output last start logs: failed to read file /home/jenkins/minikube-integration/19736-7672/.minikube/logs/lastStart.txt: bufio.Scanner: token too long

Changed to bufio.NewReader to handle reading the lastStart.txt file as there is no max token size.

Thanks to @prezha for helping debug!

@k8s-ci-robot k8s-ci-robot added the cncf-cla: yes Indicates the PR's author has signed the CNCF CLA. label Oct 1, 2024
@k8s-ci-robot k8s-ci-robot requested review from medyagh and prezha October 1, 2024 22:12
@k8s-ci-robot k8s-ci-robot added approved Indicates a PR has been approved by an approver from all required OWNERS files. size/S Denotes a PR that changes 10-29 lines, ignoring generated files. labels Oct 1, 2024
@medyagh
Copy link
Member

medyagh commented Oct 1, 2024

/ok-to-test

@k8s-ci-robot k8s-ci-robot added the ok-to-test Indicates a non-member PR verified by an org member that is safe to test. label Oct 1, 2024
@minikube-pr-bot
Copy link

kvm2 driver with docker runtime

+----------------+----------+---------------------+
|    COMMAND     | MINIKUBE | MINIKUBE (PR 19740) |
+----------------+----------+---------------------+
| minikube start | 48.1s    | 48.7s               |
| enable ingress | 15.2s    | 15.9s               |
+----------------+----------+---------------------+

Times for minikube start: 51.3s 46.0s 45.6s 49.6s 48.1s
Times for minikube (PR 19740) start: 51.7s 45.6s 46.2s 50.3s 49.5s

Times for minikube ingress: 14.5s 16.0s 15.0s 15.5s 15.0s
Times for minikube (PR 19740) ingress: 15.4s 15.0s 15.0s 14.5s 19.5s

docker driver with docker runtime

+----------------+----------+---------------------+
|    COMMAND     | MINIKUBE | MINIKUBE (PR 19740) |
+----------------+----------+---------------------+
| minikube start | 22.8s    | 23.0s               |
| enable ingress | 13.1s    | 12.7s               |
+----------------+----------+---------------------+

Times for minikube ingress: 13.3s 12.8s 13.3s 12.8s 13.3s
Times for minikube (PR 19740) ingress: 13.3s 12.3s 12.8s 11.3s 13.8s

Times for minikube start: 24.4s 24.7s 21.1s 22.0s 21.9s
Times for minikube (PR 19740) start: 23.4s 24.7s 23.4s 22.1s 21.4s

docker driver with containerd runtime

+----------------+----------+---------------------+
|    COMMAND     | MINIKUBE | MINIKUBE (PR 19740) |
+----------------+----------+---------------------+
| minikube start | 21.6s    | 21.9s               |
| enable ingress | 26.2s    | 30.2s               |
+----------------+----------+---------------------+

Times for minikube (PR 19740) start: 22.8s 22.2s 22.7s 20.6s 21.0s
Times for minikube start: 22.7s 19.5s 19.6s 23.8s 22.6s

Times for minikube ingress: 22.8s 23.8s 22.8s 38.8s 22.8s
Times for minikube (PR 19740) ingress: 22.8s 39.3s 38.8s 26.8s 23.3s

@minikube-pr-bot
Copy link

Here are the number of top 10 failed tests in each environments with lowest flake rate.

Environment Test Name Flake Rate
KVM_Linux (1 failed) TestNoKubernetes/serial/StartNoArgs(gopogh) 2.40% (chart)

Besides the following environments also have failed tests:

To see the flake rates of all tests by environment, click here.

@medyagh
Copy link
Member

medyagh commented Oct 2, 2024

/lgtm

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

[APPROVALNOTIFIER] This PR is APPROVED

This pull-request has been approved by: medyagh, spowelljr

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 files:

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

@medyagh
Copy link
Member

medyagh commented Oct 2, 2024

I did not find "bufio.Scanner: token too long" in the kvm linux crio, which is good ! thank you both @prezha and @spowelljr

@medyagh medyagh merged commit 9d3094c into kubernetes:master Oct 2, 2024
23 of 38 checks passed
@spowelljr spowelljr deleted the fixLastStartLogs branch October 21, 2024 17:20
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. ok-to-test Indicates a non-member PR verified by an org member that is safe to test. size/S Denotes a PR that changes 10-29 lines, ignoring generated files.
Projects
None yet
Development

Successfully merging this pull request may close these issues.

4 participants