-
Notifications
You must be signed in to change notification settings - Fork 113
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
feat(path-filter): Filter blockdevice using custom udev rules #670
feat(path-filter): Filter blockdevice using custom udev rules #670
Conversation
Signed-off-by: Abhishek Agarwal <[email protected]>
Signed-off-by: Abhishek Agarwal <[email protected]>
Signed-off-by: Abhishek Agarwal <[email protected]>
Codecov Report
@@ Coverage Diff @@
## develop #670 +/- ##
===========================================
+ Coverage 44.83% 45.33% +0.50%
===========================================
Files 79 79
Lines 3970 3990 +20
===========================================
+ Hits 1780 1809 +29
+ Misses 2023 2012 -11
- Partials 167 169 +2
Continue to review full report at Codecov.
|
@akhilerm could you review this PR? |
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.
@Ab-hishek I have one comment on the fetching from udev. Everything else looks good.
Signed-off-by: Abhishek Agarwal <[email protected]>
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.
LGTM
Changes looks good. @Ab-hishek please add the necessary tests also with the new changes.
Signed-off-by: Abhishek Agarwal [email protected]
Why is this PR required? What issue does it fix?:
This PR fixes the issue - openebs/openebs#3491
What this PR does?:
This PR adds extra dev links(apart from
by-id
and by-path) info which we get from the
udev` probe. This are useful to filter out bds when a disk is configured with some custom udev rules and uses those rules inside the path filter config of ndm.Does this PR require any upgrade changes?:
No
If the changes in this PR are manually verified, list down the scenarios covered::
KERNEL=="sdb1",SYMLINK+="openebs_storage_02"
udevadm control --reload
a. Exclude the disk with symlink:
/dev/openebs_storage_02
using exclude path filter:OUTPUT
: Listing bds withkubectl get bd -n openebs
doesn't list the above disk.b. Include the disk with symlink:
/dev/openebs_storage_02
using include path filter:OUTPUT
: Listing bds withkubectl get bd -n openebs
does list the above disk.blockdevice-0db0a0b21ddbc52266b551d2d1c53791 abhishek-mayadata 7812939776 Unclaimed Active 4s
is the one having the custom udev ruleAny additional information for your reviewer? :
Mention if this PR is part of any design or a continuation of previous PRs
Checklist:
<type>(<scope>): <subject>