mirror of
https://github.com/seaweedfs/seaweedfs.git
synced 2024-01-19 02:48:24 +00:00
ignore "-peers" option if cluster is already bootstrapped
This commit is contained in:
parent
6cedaf4356
commit
fb75fe852c
|
@ -58,14 +58,13 @@ func NewRaftServer(r *mux.Router, version string, peers []string, httpAddr strin
|
|||
|
||||
if !s.raftServer.IsLogEmpty() {
|
||||
glog.V(0).Infoln("Cannot join with an existing log")
|
||||
} else {
|
||||
if err := s.Join(s.peers); err != nil {
|
||||
return nil
|
||||
}
|
||||
glog.V(0).Infoln("Joined cluster")
|
||||
}
|
||||
|
||||
if err := s.Join(s.peers); err != nil {
|
||||
return nil
|
||||
}
|
||||
|
||||
glog.V(0).Infoln("Joined cluster")
|
||||
|
||||
// Initialize the server by joining itself.
|
||||
} else if s.raftServer.IsLogEmpty() {
|
||||
glog.V(0).Infoln("Initializing new cluster")
|
||||
|
|
Loading…
Reference in a new issue