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

Bugfix/csi default fs type #65499

Merged

Conversation

krunaljain
Copy link
Contributor

@krunaljain krunaljain commented Jun 26, 2018

This PR address the issue mentioned in the following ticket #65122
The FSType string will now not be defaulted to ext4. Removes defaulting of CSI file system type to ext4. CSI plugins that depended on this default need to be updated as the fsType would remain an empty string if not provided and would not default to ext4. CSI spec allows for an empty fstype string. This is intended for non-block plugins like nfs and gluster where filesystems are not separately created on the volume. But currently the default file system is overridden to ext4 which makes the above case redundant. This commit prevents such an overridding.

ACTION REQUIRED: Removes defaulting of CSI file system type to ext4. All the production drivers listed under https://kubernetes-csi.github.io/docs/Drivers.html were inspected and should not be impacted after this change. If you are using a driver not in that list, please test the drivers on an updated test cluster first. ```

@k8s-ci-robot k8s-ci-robot added size/XS Denotes a PR that changes 0-9 lines, ignoring generated files. 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 Jun 26, 2018
@k8s-ci-robot
Copy link
Contributor

Thanks for your pull request. Before we can look at your pull request, you'll need to sign a Contributor License Agreement (CLA).

📝 Please follow instructions at https://git.k8s.io/community/CLA.md#the-contributor-license-agreement to sign the CLA.

It may take a couple minutes for the CLA signature to be fully registered; after that, please reply here with a new comment and we'll verify. Thanks.


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-ci-robot k8s-ci-robot added cncf-cla: no Indicates the PR's author has not signed the CNCF CLA. needs-ok-to-test Indicates a PR that requires an org member to verify it is safe to test. labels Jun 26, 2018
@k8s-ci-robot k8s-ci-robot added cncf-cla: yes Indicates the PR's author has signed the CNCF CLA. and removed cncf-cla: no Indicates the PR's author has not signed the CNCF CLA. labels Jun 26, 2018
@msau42
Copy link
Member

msau42 commented Jun 26, 2018

/ok-to-test

@k8s-ci-robot k8s-ci-robot removed the needs-ok-to-test Indicates a PR that requires an org member to verify it is safe to test. label Jun 26, 2018
Copy link
Member

@msau42 msau42 left a comment

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

A release note should be added that FSType is not defaulted anymore.

Also, I think the comment in pkg/apis/core/types.go and staging/src/k8s.io/api/core/v1/types.go need to be updated (and run make update to regenerate all the documentation)


//Test the default value of file system type is not overriden
if len(csiMounter.spec.PersistentVolume.Spec.CSI.FSType) != 0 {
t.Fatalf("default value of file system type was overriden by type %s" , csiMounter.spec.PersistentVolume.Spec.CSI.FSType)
Copy link
Member

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

This could just be Errorf instead of Fatalf. Fatalf will exit and not run the remainder of the test.

@@ -34,7 +34,7 @@ import (
"k8s.io/kubernetes/pkg/volume/util"
)

const defaultFSType = "ext4"
const defaultFSType = ""
Copy link
Member

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

I would remove this whole variable

@msau42
Copy link
Member

msau42 commented Jun 26, 2018

Also, it would be good to put the generated files into a separate commit.

@k8s-ci-robot k8s-ci-robot added release-note-none Denotes a PR that doesn't merit a release note. size/S Denotes a PR that changes 10-29 lines, ignoring generated files. 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. size/XS Denotes a PR that changes 0-9 lines, ignoring generated files. labels Jun 26, 2018
@jsafrane
Copy link
Member

Please squash the commits. And should it include removal of "Implicitly inferred to be "ext4" if unspecified." in types.go?

@msau42
Copy link
Member

msau42 commented Jun 27, 2018

In addition to updating the comments in types.go, can you also say in the release note "ACTION REQUIRED: Removes defaulting of CSI fsType to ext4. CSI plugins that depended on this default need to be updated"

@saad-ali
Copy link
Member

/assign @vladimirvivien

@k8s-github-robot k8s-github-robot added the kind/api-change Categorizes issue or PR as related to adding, removing, or otherwise changing an API label Jun 27, 2018
@k8s-ci-robot k8s-ci-robot added release-note-action-required Denotes a PR that introduces potentially breaking changes that require user action. and removed release-note-none Denotes a PR that doesn't merit a release note. labels Jun 27, 2018
@msau42
Copy link
Member

msau42 commented Jun 27, 2018

You also need to update staging/src/k8s.io/api/core/v1/types.go, and then run make update to regenerate the documentation (please put the autogenerated files in a separate commit)

@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 Jun 27, 2018
@lpabon
Copy link
Contributor

lpabon commented Jul 9, 2018

Hi guys. Just wanted to point out that this change will not affect the Portworx CSI driver. It currently uses the storage class fs value as stated here.

/cc @msau42

@k8s-ci-robot k8s-ci-robot requested a review from msau42 July 9, 2018 18:18
@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. release-note-action-required Denotes a PR that introduces potentially breaking changes that require user action. and removed release-note-action-required Denotes a PR that introduces potentially breaking changes that require user action. 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 Jul 9, 2018
@msau42
Copy link
Member

msau42 commented Jul 9, 2018

/retest

@msau42
Copy link
Member

msau42 commented Jul 9, 2018

Release note has been updated, and all known production csi drivers have been checked.

@msau42
Copy link
Member

msau42 commented Jul 9, 2018

Also, email has been sent to kubernetes-sig-storage

@vladimirvivien
Copy link
Member

@msau42 thanks for doing that research !!

@liggitt
Copy link
Member

liggitt commented Jul 10, 2018

/hold cancel

thanks. this seems worthwhile (and safe, given the research done) to pick back to maintenance branches.

@k8s-ci-robot k8s-ci-robot removed the do-not-merge/hold Indicates that a PR should not merge because someone has issued a /hold command. label Jul 10, 2018
@k8s-github-robot
Copy link

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

@k8s-github-robot
Copy link

Automatic merge from submit-queue (batch tested with PRs 55023, 65499). If you want to cherry-pick this change to another branch, please follow the instructions here.

@liggitt
Copy link
Member

liggitt commented Jul 10, 2018

@krunaljain thanks, can you pick to 1.11 as well?

@k8s-ci-robot
Copy link
Contributor

k8s-ci-robot commented Jul 10, 2018

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

Test name Commit Details Rerun command
pull-kubernetes-e2e-gce-100-performance fb28a1d link /test pull-kubernetes-e2e-gce-100-performance

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 pushed a commit that referenced this pull request Jul 12, 2018
…5499-upstream-release-1.11

Automatic merge from submit-queue.

Automated cherry pick of #65499: Removes defaulting of CSI fsType to ext4

Cherry pick of #65499 on release-1.11.

#65499: Removes defaulting of CSI fsType to ext4
k8s-github-robot pushed a commit that referenced this pull request Jul 13, 2018
…5499-upstream-release-1.10

Automatic merge from submit-queue.

Automated cherry pick of #65499: Removes defaulting of CSI fsType to ext4

Cherry pick of #65499 on release-1.10.

#65499: Removes defaulting of CSI fsType to ext4
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. kind/api-change Categorizes issue or PR as related to adding, removing, or otherwise changing an API lgtm "Looks good to me", indicates that a PR is ready to be merged. release-note-action-required Denotes a PR that introduces potentially breaking changes that require user action. sig/storage Categorizes an issue or PR as relevant to SIG Storage. 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

9 participants