Add retry to reading /proc/mounts
out of ListMounts() function
#246
Add this suggestion to a batch that can be applied as a single commit.
This suggestion is invalid because no changes were made to the code.
Suggestions cannot be applied while the pull request is closed.
Suggestions cannot be applied while viewing a subset of changes.
Only one suggestion per line can be applied in a batch.
Add this suggestion to a batch that can be applied as a single commit.
Applying suggestions on deleted lines is not supported.
You must change the existing code in this line in order to create a valid suggestion.
Outdated suggestions cannot be applied.
This suggestion has been applied or marked resolved.
Suggestions cannot be applied from pending reviews.
Suggestions cannot be applied on multi-line comments.
Suggestions cannot be applied while the pull request is queued to merge.
Suggestion cannot be applied right now. Please check back later.
Issue #, if available:
#174
Description of changes:
Since it's unclear why the driver cannot read /host/proc/mounts (with Karpenter) at the first time, retry to read /host/proc/mounts will success.
We've discussed in #229
Recently released v1.8 added retry in the
ListMounts() function
, however I tried the new release and got the same error message still cannot mount S3. I found that ifListMounts() function
ever return anil, error
it won't work.Just leave error handling in
parseProcMounts() function
and retry reading/proc/mounts
by callingListMounts() function
from other function, which will work.It may be somehow confusing about "retry", it may because other function/module refresh/restart which fix the issue (just like restart the pod).
Passed locally test
By submitting this pull request, I confirm that you can use, modify, copy, and redistribute this contribution, under the terms of your choice.