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

hyperv: Check for Get-Wmiobject err before parsing output #7867

Merged
merged 2 commits into from
Apr 24, 2020

Conversation

tstromberg
Copy link
Contributor

@tstromberg tstromberg commented Apr 23, 2020

Right after I merged #7790 I realized the PR didn't check for err first.

Also, update the error message handling because Get-Wmiobject only returns an error if it's unavailable to make a local RPC, rather than if the object is not found. Proof that this PR works, in lieu of working Hyper-V integration tests:

$ ./out/minikube.exe start
* minikube v1.10.0-beta.0 on Microsoft Windows 10 Pro 10.0.19041 Build 19041
* Automatically selected the hyperv driver
* Starting control plane node minikube in cluster minikube
* Creating hyperv VM (CPUs=2, Memory=6000MB, Disk=20000MB) ...
* Preparing Kubernetes v1.18.0 on Docker 19.03.8 ...
* Verifying Kubernetes components...
* Enabled addons: default-storageclass, storage-provisioner
* Done! kubectl is now configured to use "minikube"

@k8s-ci-robot k8s-ci-robot added the cncf-cla: yes Indicates the PR's author has signed the CNCF CLA. label Apr 23, 2020
@tstromberg tstromberg changed the title Check for Get-Wmiobject err before parsing output hyperv: Check for Get-Wmiobject err before parsing output Apr 23, 2020
@k8s-ci-robot k8s-ci-robot added the size/S Denotes a PR that changes 10-29 lines, ignoring generated files. label Apr 23, 2020
@k8s-ci-robot
Copy link
Contributor

[APPROVALNOTIFIER] This PR is APPROVED

This pull-request has been approved by: tstromberg

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

@k8s-ci-robot k8s-ci-robot added the approved Indicates a PR has been approved by an approver from all required OWNERS files. label Apr 23, 2020
@tstromberg
Copy link
Contributor Author

/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 Apr 23, 2020
@minikube-pr-bot
Copy link

kvm2 Driver
docker Driver

@minikube-pr-bot
Copy link

kvm2 Driver
Times for minikube: [65.447123905 66.379941643 68.001651202]
Average time for minikube: 66.60957225

Times for Minikube (PR 7867): [65.264037659 66.926832696 64.172406678]
Average time for Minikube (PR 7867): 65.45442567766668

Averages Time Per Log

+--------------------------------+-----------+--------------------+
|              LOG               | MINIKUBE  | MINIKUBE (PR 7867) |
+--------------------------------+-----------+--------------------+
| * minikube v1.10.0-beta.1 on   |  0.058299 |           0.059078 |
| Debian 9.11                    |           |                    |
| * Using the kvm2 driver based  |  0.020631 |           0.021046 |
| on existing profile            |           |                    |
| * Starting control plane node  |  0.003334 |           0.003487 |
| minikube in cluster minikube   |           |                    |
| * Creating kvm2 VM (CPUs=2,    | 41.487044 |          41.411888 |
| Memory=3700MB, Disk=20000MB)   |           |                    |
| ...                            |           |                    |
| * Preparing Kubernetes v1.18.0 | 22.663770 |          21.834807 |
| on Docker 19.03.8 ...          |           |                    |
| * Verifying Kubernetes         |  1.481860 |           1.804108 |
| components...                  |           |                    |
| * Enabled addons:              |  0.818752 |           0.241412 |
| default-storageclass,          |           |                    |
| storage-provisioner            |           |                    |
| * Done! kubectl is now         |  0.072731 |           0.074809 |
| configured to use "minikube"   |           |                    |
|                                |  0.003151 |           0.003793 |
+--------------------------------+-----------+--------------------+

docker Driver
Times for minikube: [26.73674339 27.246530462000003 27.284693852999997]
Average time for minikube: 27.08932256833333

Times for Minikube (PR 7867): [26.969211379 29.477531361 25.979742795]
Average time for Minikube (PR 7867): 27.475495178333333

Averages Time Per Log

+----------------------------------------+-----------+--------------------+
|                  LOG                   | MINIKUBE  | MINIKUBE (PR 7867) |
+----------------------------------------+-----------+--------------------+
| * minikube v1.10.0-beta.1 on           |  0.075512 |           0.077483 |
| Debian 9.11                            |           |                    |
| * Using the docker driver              |  0.002740 |           0.002565 |
| based on existing profile              |           |                    |
| * Starting control plane node          |  0.060341 |           0.058305 |
| minikube in cluster minikube           |           |                    |
| * Creating docker container            |  7.921210 |           7.693496 |
| (CPUs=2, Memory=3700MB) ...            |           |                    |
| * Preparing Kubernetes v1.18.0         |  0.000223 |           0.000232 |
| on Docker 19.03.2 ...                  |           |                    |
|   -                                    | 18.126316 |          18.320715 |
| kubeadm.pod-network-cidr=10.244.0.0/16 |           |                    |
| * Verifying Kubernetes                 |  0.832353 |           1.138058 |
| components...                          |           |                    |
| * Enabled addons:                      |  0.002919 |           0.115249 |
| default-storageclass,                  |           |                    |
| storage-provisioner                    |           |                    |
| * Done! kubectl is now                 |  0.063261 |           0.064604 |
| configured to use "minikube"           |           |                    |
|                                        |  0.004448 |           0.004788 |
+----------------------------------------+-----------+--------------------+

@tstromberg tstromberg merged commit 47b769b into master Apr 24, 2020
@medyagh medyagh deleted the hyperv-cleanup branch May 2, 2020 22:19
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. 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