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

[BUG]: Cert-csi modifies ephemeral.volumeAttributes fields causing test failure #1664

Closed
sakshi-garg1 opened this issue Jan 7, 2025 · 1 comment
Assignees
Labels
area/cert-csi Issues pertaining to Cert CSI type/bug Something isn't working. This is the default label associated with a bug issue.
Milestone

Comments

@sakshi-garg1
Copy link
Contributor

Bug Description

cert-csi reads data from the file specified by the --cert-config option in order to execute ephemeral volume testing.

It appears during this read operation, the child field names of ephemeral.volumeAttributes are being converted to lower-case. When the ephemeral volume is then created during the test, csi-powerflex fails to mount the volume because it is expecting the case-sensitive fields of volumeAttributes.

For example:

storageClasses:
  - name: vxflexos-cert-csi
    minSize: 8Gi
    rawBlock: true
    expansion: true
    clone: true
    snapshot: true
    RWX: false
    ephemeral:
      driver: csi-vxflexos.dellemc.com
      fstype: xfs
      volumeAttributes:
        volumeName: "my-ephemeral-vol"
        size: "8Gi"
        storagepool: "SP-SW_SSD-1"
        systemID: "af948d7db6f7160f"

The child fields of storageClasses[0].ephemeral.volumeAttributes are cased, but when cert-csi prompts the user to confirm the test cases are correct before starting the test run they are displayed as below with lower-cased field names.

[2024-12-19 16:07:53] INFO 9. EphemeralVolumeSuite {driver: csi-vxflexos.dellemc.com, podNumber: 2, volAttributes: map[size:8Gi storagepool:SP-SW_SSD-1 systemid:af948d7db6f7160f volumename:my-ephemeral-vol]}
This effects cert-csi v1.4.0 onward.

Logs

MountVolume.SetUp failed for volume "ephemeral-vol" : rpc error: code = Internal desc = Volume name not specified

time="2024-12-19T21:12:08Z" level=info msg="/csi.v1.Node/NodePublishVolume: REQ 1552: VolumeId=csi-53c717a021849e51a487ec4e700b834ea1dc8928a4c4addbca8994dd901bb2c9, TargetPath=/var/lib/kubelet/pods/468ec92a-99b4-4940-818b-27c09d7d8438/volumes/kubernetes.io~csi/ephemeral-vol/mount, VolumeCapability=mount:<fs_type:\"xfs\" > access_mode:<mode:SINGLE_NODE_MULTI_WRITER > , Readonly=false, VolumeContext=map[csi.storage.k8s.io/ephemeral:true csi.storage.k8s.io/pod.name:pod-ephemeral-test-svgcm csi.storage.k8s.io/pod.namespace:functional-test-69181fb6 csi.storage.k8s.io/pod.uid:468ec92a-99b4-4940-818b-27c09d7d8438 csi.storage.k8s.io/serviceAccount.name:default size:8Gi storagepool:SP-SW_SSD-1 systemid:af948d7db6f7160f volumename:my-ephemeral-vol], XXX_NoUnkeyedLiteral={}, XXX_sizecache=0"
time="2024-12-19T21:12:08Z" level=info msg="VolumeContext:"
time="2024-12-19T21:12:08Z" level=info msg="found in VolumeContext" storagepool=SP-SW_SSD-1
time="2024-12-19T21:12:08Z" level=info msg="found in VolumeContext" systemid=af948d7db6f7160f
time="2024-12-19T21:12:08Z" level=info msg="found in VolumeContext" size=8Gi
time="2024-12-19T21:12:08Z" level=info msg="found in VolumeContext" csi.storage.k8s.io/pod.namespace=functional-test-69181fb6
time="2024-12-19T21:12:08Z" level=info msg="found in VolumeContext" volumename=my-ephemeral-vol
time="2024-12-19T21:12:08Z" level=info msg="found in VolumeContext" csi.storage.k8s.io/pod.uid=468ec92a-99b4-4940-818b-27c09d7d8438
time="2024-12-19T21:12:08Z" level=info msg="found in VolumeContext" csi.storage.k8s.io/pod.name=pod-ephemeral-test-svgcm
time="2024-12-19T21:12:08Z" level=info msg="found in VolumeContext" csi.storage.k8s.io/serviceAccount.name=default
time="2024-12-19T21:12:08Z" level=info msg="found in VolumeContext" csi.storage.k8s.io/ephemeral=true
time="2024-12-19T21:12:08Z" level=error msg="Missing Parameter: volumeName must be specified in volume attributes section for ephemeral volumes"
time="2024-12-19T21:12:08Z" level=error msg="ephemeralNodePublish returned error: rpc error: code = Internal desc = Volume name not specified"
time="2024-12-19T21:12:08Z" level=info msg="/csi.v1.Node/NodePublishVolume: REP 1552: rpc error: code = Internal desc = Volume name not specified"

Screenshots

No response

Additional Environment Information

No response

Steps to Reproduce

run cert-csi for powerflex and unity driver

Expected Behavior

Cert-csi suite should pass successfully

CSM Driver(s)

powerflex , unity

Installation Type

NA

Container Storage Modules Enabled

NA

Container Orchestrator

NA

Operating System

NA

@sakshi-garg1 sakshi-garg1 added type/bug Something isn't working. This is the default label associated with a bug issue. area/cert-csi Issues pertaining to Cert CSI labels Jan 7, 2025
@sakshi-garg1 sakshi-garg1 self-assigned this Jan 7, 2025
@sakshi-garg1
Copy link
Contributor Author

link: ECS01A-32

@suryagupta4 suryagupta4 added this to the v1.13.0 milestone Jan 8, 2025
@hoppea2 hoppea2 changed the title [BUG]: cert-csi modifies ephemeral.volumeAttributes fields causing test failure [BUG]: Cert-csi modifies ephemeral.volumeAttributes fields causing test failure Jan 16, 2025
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
area/cert-csi Issues pertaining to Cert CSI type/bug Something isn't working. This is the default label associated with a bug issue.
Projects
None yet
Development

No branches or pull requests

2 participants