-
Notifications
You must be signed in to change notification settings - Fork 72
Add Node-Deployment Mode for High-Performance LocalPV Provisioning #306
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
base: develop
Are you sure you want to change the base?
Conversation
tiagolobocastro
left a comment
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.
Awesome, just a few questions!
Solve xfs/ext projId Issues
Could you fix this for the helperPod variant as well? And if we could share some of that code that would be great.
Solve race conditions Issues
Is this only solved in new daemonset mode?
| base="%s" | ||
| # check fs type first | ||
| fs=$(stat -f -c %%T $base 2>/dev/null) | ||
| if [ "$fs" = "xfs" ]; then |
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.
Is nothing needed for ext4?
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.
Yes, I saw there will be some leftovers, I'll fix it
*** Report for project quotas on device /dev/loop0
Block grace time: 7days; Inode grace time: 7days
Block limits File limits
Project used soft hard grace used soft hard grace
----------------------------------------------------------------------
#0 -- 20 0 0 3 0 0
#1 -- 4 112640 122880 1 0 0
#2 -- 4 112640 122880 1 0 0
#3 -- 4 112640 122880 1 0 0
#4 -- 4 112640 122880 1 0 0
➜ pv-test git:(main) ✗ km pod --all && km pvc --all
...
➜ pv-test git:(main) ✗ repquota -P /root/openebs/local
*** Report for project quotas on device /dev/loop0
Block grace time: 7days; Inode grace time: 7days
Block limits File limits
Project used soft hard grace used soft hard grace
----------------------------------------------------------------------
#0 -- 20 0 0 3 0 0
➜ pv-test git:(main) ✗ repquota -avugP
*** Report for project quotas on device /dev/loop0
Block grace time: 7days; Inode grace time: 7days
Block limits File limits
Project used soft hard grace used soft hard grace
----------------------------------------------------------------------
#0 -- 20 0 0 3 0 0
#1 -- 0 112640 122880 0 0 0
#2 -- 0 112640 122880 0 0 0
#3 -- 0 112640 122880 0 0 0
#4 -- 0 112640 122880 0 0 0
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.
Related issues #155
| script := fmt.Sprintf(` | ||
| set -e | ||
| # Find the actual mount point for the path using host's mount info |
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.
Do we need this fix on the helper pod variant?
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.
yeah, It will be fixed in the previous commit. I forgot to synchronize it when the commit was rolled back. I will fix it.
| func (vm *LocalVolumeManager) applyQuotaByFilesystem(ctx context.Context, parentDir, volumeDir, softLimitGrace, hardLimitGrace string) error { | ||
| // Create a shell script to detect filesystem and apply quota | ||
| // We need to find the actual XFS mount point since parentDir might be a bind mount | ||
| script := fmt.Sprintf(` |
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.
Is there some way to share this with the helper pod variant?
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.
This is not suitable for sharing
|
@laik please take a look at the test failure |
Signed-off-by: laik <laik.lj@me.com>
ok , let me check |
yeah, Helper pod belongs to the asynchronous mode at the pod level. If necessary, you may need to create a file to lock it. |
You mean using |
|
Codecov Report✅ All modified and coverable lines are covered by tests. Additional details and impacted files@@ Coverage Diff @@
## develop #306 +/- ##
===========================================
+ Coverage 37.91% 39.18% +1.26%
===========================================
Files 36 1 -35
Lines 3373 684 -2689
===========================================
- Hits 1279 268 -1011
+ Misses 2012 407 -1605
+ Partials 82 9 -73
Flags with carried forward coverage won't be shown. Click here to find out more. ☔ View full report in Codecov by Sentry. 🚀 New features to boost your workflow:
|
Yes, I checked the documentation about flock and it should be possible. |
tiagolobocastro
left a comment
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.
@niladrih do we update the changelog here or would you update it on release?
| config.taints = pOpts.selectedNodeTaints | ||
|
|
||
| config.pOpts.cmdsForPath = append(config.pOpts.cmdsForPath, filepath.Join("/data/", config.volumeDir)) | ||
| // check if path is xfs quota enabled and remove quota projid |
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.
this is the fix for the non-distributed cleanup right? Could you place this on a separate commit?
| setquota -P $ID 0 0 0 0 $base 2>/dev/null || true | ||
| fi | ||
| fi | ||
| rm -rf $d |
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.
Is there any safety check against this not being the base path for example?
| e2fsprogs \ | ||
| xfsprogs \ | ||
| xfsprogs-extra \ |
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.
are all these required?
This PR introduces a node-deployment mode for the OpenEBS Dynamic LocalPV
Provisioner, addressing performance bottlenecks identified in openebs/openebs#4050.
Key Changes:
--node-deployment=trueflag to run provisioner as DaemonSet on each nodeBenefits:
Solve xfs/ext projId Issues
Solve race conditions Issues
#289
#290