mirror of
https://github.com/minio/minio.git
synced 2025-02-04 02:15:59 -05:00
parent
d8660b30cc
commit
9be7066715
@ -234,8 +234,6 @@ func (s *xlSets) monitorAndConnectEndpoints(monitorInterval time.Duration) {
|
|||||||
|
|
||||||
func (s *xlSets) GetLockers(setIndex int) func() []dsync.NetLocker {
|
func (s *xlSets) GetLockers(setIndex int) func() []dsync.NetLocker {
|
||||||
return func() []dsync.NetLocker {
|
return func() []dsync.NetLocker {
|
||||||
s.xlDisksMu.Lock()
|
|
||||||
defer s.xlDisksMu.Unlock()
|
|
||||||
lockers := make([]dsync.NetLocker, s.drivesPerSet)
|
lockers := make([]dsync.NetLocker, s.drivesPerSet)
|
||||||
copy(lockers, s.xlLockers[setIndex])
|
copy(lockers, s.xlLockers[setIndex])
|
||||||
return lockers
|
return lockers
|
||||||
@ -1301,7 +1299,9 @@ func (s *xlSets) ReloadFormat(ctx context.Context, dryRun bool) (err error) {
|
|||||||
s.format = refFormat
|
s.format = refFormat
|
||||||
|
|
||||||
// Close all existing disks and reconnect all the disks.
|
// Close all existing disks and reconnect all the disks.
|
||||||
|
s.xlDisksMu.Lock()
|
||||||
s.xlDisks.Close()
|
s.xlDisks.Close()
|
||||||
|
s.xlDisksMu.Unlock()
|
||||||
s.connectDisks()
|
s.connectDisks()
|
||||||
|
|
||||||
// Restart monitoring loop to monitor reformatted disks again.
|
// Restart monitoring loop to monitor reformatted disks again.
|
||||||
@ -1488,7 +1488,9 @@ func (s *xlSets) HealFormat(ctx context.Context, dryRun bool) (res madmin.HealRe
|
|||||||
s.format = refFormat
|
s.format = refFormat
|
||||||
|
|
||||||
// Disconnect/relinquish all existing disks, lockers and reconnect the disks, lockers.
|
// Disconnect/relinquish all existing disks, lockers and reconnect the disks, lockers.
|
||||||
|
s.xlDisksMu.Lock()
|
||||||
s.xlDisks.Close()
|
s.xlDisks.Close()
|
||||||
|
s.xlDisksMu.Unlock()
|
||||||
s.connectDisks()
|
s.connectDisks()
|
||||||
|
|
||||||
// Restart our monitoring loop to start monitoring newly formatted disks.
|
// Restart our monitoring loop to start monitoring newly formatted disks.
|
||||||
|
Loading…
x
Reference in New Issue
Block a user