cephfs: fix subvolumegroup creation for multiple fs

In a cluster we can have multiple filesystem
for that we need to have a map of
subvolumegroups to check filesystem is created
nor not.

Signed-off-by: Madhu Rajanna <madhupr007@gmail.com>
This commit is contained in:
Madhu Rajanna
2022-09-07 11:46:22 +05:30
committed by mergify[bot]
parent 9d46478794
commit e56621cd66
3 changed files with 19 additions and 22 deletions

View File

@ -33,9 +33,7 @@ const (
var ErrSubVolMetadataNotSupported = errors.New("subvolume metadata operations are not supported")
func (s *subVolumeClient) supportsSubVolMetadata() bool {
if _, keyPresent := clusterAdditionalInfo[s.clusterID]; !keyPresent {
clusterAdditionalInfo[s.clusterID] = &localClusterState{}
}
newLocalClusterState(s.clusterID)
return clusterAdditionalInfo[s.clusterID].subVolMetadataState != unsupported
}