mirror of https://github.com/minio/minio.git
isEndpointConnected should take local disk inputs (#9803)
PR #9801 while it is correct, the loop isEndpointConnected() was changed to rely on endpoint.String() which has the host information as well, which is not correct value as input to detect if the disk is down or up, if endpoint is local use its local path value instead.
This commit is contained in:
parent
b1845c6c83
commit
ff94b1b0a9
|
@ -190,7 +190,11 @@ func (s *xlSets) connectDisks() {
|
||||||
var wg sync.WaitGroup
|
var wg sync.WaitGroup
|
||||||
diskMap := s.getDiskMap()
|
diskMap := s.getDiskMap()
|
||||||
for _, endpoint := range s.endpoints {
|
for _, endpoint := range s.endpoints {
|
||||||
if isEndpointConnected(diskMap, endpoint.String()) {
|
diskPath := endpoint.String()
|
||||||
|
if endpoint.IsLocal {
|
||||||
|
diskPath = endpoint.Path
|
||||||
|
}
|
||||||
|
if isEndpointConnected(diskMap, diskPath) {
|
||||||
continue
|
continue
|
||||||
}
|
}
|
||||||
wg.Add(1)
|
wg.Add(1)
|
||||||
|
|
Loading…
Reference in New Issue