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

Remove mount cache for cephfs #825

Merged
merged 2 commits into from
Feb 11, 2020
Merged

Conversation

Madhu-1
Copy link
Collaborator

@Madhu-1 Madhu-1 commented Feb 10, 2020

PR #282 introduces the mount cache to solve cephfs fuse mount issue when cephfs plugin pod
restarts. This is not working as intended. This PR removes the code for maintainability.

Signed-off-by: Madhu Rajanna madhupr007@gmail.com

Related issues

Mention any github issues relevant to this PR. Adding below line
will help to auto close the issue once the PR is merged.

Updates #824

PR ceph#282 introduces the mount cache to
solve cephfs fuse mount issue when cephfs plugin pod
restarts .This is not working as intended. This PR removes
the code for maintainability.
Signed-off-by: Madhu Rajanna <madhupr007@gmail.com>
Copy link
Contributor

@ShyamsundarR ShyamsundarR left a comment

Choose a reason for hiding this comment

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

As the commit has "Fixes" keyword for the issue, it will close it automatically, we may want to track the issue to remove the deprecated option in the next release. I would suggest "Updates" as the keyword referencing the issue hence.

@humblec
Copy link
Collaborator

humblec commented Feb 11, 2020

As the commit has "Fixes" keyword for the issue, it will close it automatically, we may want to track the issue to remove the deprecated option in the next release. I would suggest "Updates" as the keyword referencing the issue hence.

@Madhu-1 can you address this ? rest looks good to me. Thanks !

@Madhu-1
Copy link
Collaborator Author

Madhu-1 commented Feb 11, 2020

@humblec done

@mergify mergify bot merged commit 034b123 into ceph:master Feb 11, 2020
@jianglingxia
Copy link

can somebody see the issue #836
that v1.2.0 csi version used the cephfs and the mount-cache-dir function why only remounted one volume when csiplugin existed? but in the minion has many mountpath,thanks all!

@jianglingxia
Copy link

@Madhu-1
can you help me ? now i found that when plugin restart the remountCachedVolumes function only remount one volume,cause the monion mount path transport endpoint is not connected

the code bug that follow
func (nc *NodeCache) ForAll(pattern string, destObj interface{}, f ForAllFunc) error {
err := nc.EnsureCacheDirectory(nc.CacheDir)
if err != nil {
return errors.Wrap(err, "node-cache: couldn't ensure cache directory exists")
}
files, err := ioutil.ReadDir(path.Join(nc.BasePath, nc.CacheDir))
if err != nil {
return errors.Wrapf(err, "node-cache: failed to read %s folder", nc.BasePath)
}
cachePath := path.Join(nc.BasePath, nc.CacheDir)
for _, file := range files {
err = decodeObj(cachePath, pattern, file, destObj)
if err == errDec {
continue
} else if err == nil {
if err = f(strings.TrimSuffix(file.Name(), filepath.Ext(file.Name()))); err != nil {
return err
}
}
return err ----?this line?

}
return nil

}

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

Successfully merging this pull request may close these issues.

4 participants