-
Notifications
You must be signed in to change notification settings - Fork 262
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 volume creation for PVC #1709
Conversation
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.
@dsimansk: 0 warnings.
In response to this:
Description
When initializing volumes for flag usage like in E2E
--mount /mydir5=pvc:test-pvc
. We shouldn't probably enforcereadOnly: true
on the created volume PVC. We may end up with service stuck in initialization phase, because of underlying storage config, e.g. some volumes are being formatted first.Error from volume init:
Warning FailedMount 1s (x4 over 7s) kubelet MountVolume.MountDevice failed for volume "pvc-1577f113-81c1-44f9-861f-5def40d13e8b" : cannot mount unformatted disk /dev/nvme2n1 as we are manipulating it in read-only mode
Former behavior:
volumes: - name: mydir5-aa14be68 persistentVolumeClaim: claimName: test-pvc readOnly: true
Changes
- Fix volume creation for PVC
Reference
Fixes #
Release Note
Fix mounted PVC not to be create as read-only
/kind bug
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.
Codecov Report
@@ Coverage Diff @@
## main #1709 +/- ##
=======================================
Coverage 79.91% 79.91%
=======================================
Files 174 174
Lines 13515 13515
=======================================
Hits 10800 10800
Misses 1978 1978
Partials 737 737
Continue to review full report at Codecov.
|
Looks good to me to change the default to not provide But would it make sense to allow options to be specified for a mount ? (like with appending a /approve |
[APPROVALNOTIFIER] This PR is APPROVED This pull-request has been approved by: dsimansk, rhuss 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 |
@rhuss I think I added the |
IMO it probably slipped through review. We had a few places that specified volumes as readOnly because of Secrets and ConfigMaps being a primary target previously. Indeed we should look at adding readOnly to a volume config flag to cover that case. However, most of the time I'd expect PVC needs to writable. |
Do you know whether we have opened an issue for that ? If not, we should. |
Here: #1712 /unhold |
/cherry-pick release-1.6 |
@dsimansk: #1709 failed to apply on top of branch "release-1.6":
In 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. |
/cherry-pick release-1.6 |
@dsimansk: new pull request created: #1723 In 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. |
Description
When initializing volumes for flag usage like in E2E
--mount /mydir5=pvc:test-pvc
. We shouldn't probably enforcereadOnly: true
on the created volume PVC. We may end up with service stuck in initialization phase, because of underlying storage config, e.g. some volumes are being formatted first.Error from volume init:
Former behavior:
/cc @vyasgun @rhuss @skonto
Changes
Reference
Fixes #
Release Note
/kind bug