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 Node Driver Crash Caused by Auto-Select Protocol #421

Open
wants to merge 15 commits into
base: main
Choose a base branch
from

Conversation

sakshi-garg1
Copy link
Contributor

@sakshi-garg1 sakshi-garg1 commented Jan 27, 2025

Description

This PR addresses the issue of the node pod crashing when the X_CSI_TRANSPORT_PROTOCOL is empty in the powermax-array-config. The fix ensures that when the protocol is unspecified, the driver will prioritize available protocols in the following order:

  • NVMe/TCP
  • FC
  • iSCSI

The driver will automatically select the first available and working protocol from this list, establishing a connection based on these preferences.

GitHub Issues

List the GitHub issues impacted by this PR:

GitHub Issue #
dell/csm#1689
dell/csm#1725

Checklist:

  • Have you run format,vet & lint checks against your submission?
  • Have you made sure that the code compiles?
  • Did you run the unit & integration tests successfully?
  • Have you maintained at least 90% code coverage?
  • Have you commented your code, particularly in hard-to-understand areas
  • Have you done corresponding changes to the documentation
  • Did you run tests in a real Kubernetes cluster?
  • Backward compatibility is not broken

How Has This Been Tested?

Please describe the tests that you ran to verify your changes. Please also list any relevant details for your test configuration

  • X_CSI_TRANSPORT_PROTOCOL empty with NVMe/TCP configured/ driver installed and running successfully + cert-csi
  • X_CSI_TRANSPORT_PROTOCOL empty with FC configured/ driver installed and running successfully + cert-csi
  • X_CSI_TRANSPORT_PROTOCOL empty with iSCSI configured/ driver installed and running successfully + cert-csi

@rishabhatdell rishabhatdell changed the title [WIP] fix_1689_auto_transport_protocol Fix Node Driver Crash Caused by Auto-Select Protocol Feb 6, 2025
rishabhatdell
rishabhatdell previously approved these changes Feb 11, 2025
@@ -735,7 +738,7 @@ Feature: PowerMax CSI interface
Then 0 nvmetcp targets are returned

@v1.4.0
Scenario: Validate nodeHostSetup with temporary failure
Scenario: Validate nodeHostSetup with temporary fc failure

Choose a reason for hiding this comment

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

Fc -> FC ?

@v2.13.0
Scenario: Validate nodeHostSetup with temporary nvme failure
Given a PowerMax service
And I set transport protocol to "NVME"

Choose a reason for hiding this comment

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

NVMe and iSCSI ?

Choose a reason for hiding this comment

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

Applicable in all other files as well.

Copy link
Contributor

Choose a reason for hiding this comment

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

Switch case has this:

case "ISCSI":

@adarsh-dell
Copy link

@rishabhatdell @sakshi-garg1 , have we documented it properly in csm-doc that what is the priority order in case of Auto mode selection? If yes, please share the link of that section, would like to review that section to make sure that doc aligns with the code logic written here.
Thanks

@adarsh-dell
Copy link

Please update the copyright year as well for all files that are being modified in this PR.

@rishabhatdell
Copy link
Contributor

@rishabhatdell @sakshi-garg1 , have we documented it properly in csm-doc that what is the priority order in case of Auto mode selection? If yes, please share the link of that section, would like to review that section to make sure that doc aligns with the code logic written here. Thanks

Added: dell/csm-docs#1450

switch tp {
case "FIBRE":
return "FC"
case "FC", "ISCSI", "NVMETCP", "":

Choose a reason for hiding this comment

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

This is nice.

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

Successfully merging this pull request may close these issues.

3 participants