mirror of https://github.com/milvus-io/milvus.git
Create dir if mmap enabled for validating path (#25750)
Signed-off-by: yah01 <yang.cen@zilliz.com>pull/25774/head
parent
172db82b23
commit
361db51337
|
@ -353,10 +353,19 @@ func (node *QueryNode) Start() error {
|
|||
|
||||
paramtable.SetCreateTime(time.Now())
|
||||
paramtable.SetUpdateTime(time.Now())
|
||||
mmapDirPath := paramtable.Get().QueryNodeCfg.MmapDirPath.GetValue()
|
||||
mmapEnabled := len(mmapDirPath) > 0
|
||||
if mmapEnabled {
|
||||
err := os.MkdirAll(mmapDirPath, 0666)
|
||||
if err != nil {
|
||||
panic(err)
|
||||
}
|
||||
}
|
||||
node.UpdateStateCode(commonpb.StateCode_Healthy)
|
||||
log.Info("query node start successfully",
|
||||
zap.Int64("queryNodeID", paramtable.GetNodeID()),
|
||||
zap.String("Address", node.address),
|
||||
zap.Bool("mmapEnabled", mmapEnabled),
|
||||
)
|
||||
})
|
||||
|
||||
|
|
Loading…
Reference in New Issue