mirror of
https://github.com/cubefs/cubefs.git
synced 2026-08-02 02:00:56 +00:00
enhance:add enableBcache to mountoptions.
Signed-off-by: tianjiongzhang <236556116@qq.com>
This commit is contained in:
parent
0d28d123d4
commit
560516a8df
@ -696,7 +696,8 @@ func parseMountOption(cfg *config.Config) (*proto.MountOptions, error) {
|
||||
opt.ReadThreads = GlobalMountOptions[proto.ReadThreads].GetInt64()
|
||||
opt.WriteThreads = GlobalMountOptions[proto.WriteThreads].GetInt64()
|
||||
opt.BcacheDir = GlobalMountOptions[proto.BcacheDir].GetString()
|
||||
if _, err := os.Stat(bcache.UnixSocketPath); err == nil {
|
||||
opt.EnableBcache = GlobalMountOptions[proto.EnableBcache].GetBool()
|
||||
if _, err := os.Stat(bcache.UnixSocketPath); err == nil && !opt.EnableBcache {
|
||||
opt.EnableBcache = true
|
||||
}
|
||||
opt.BuffersTotalLimit = GlobalMountOptions[proto.BuffersTotalLimit].GetInt64()
|
||||
|
||||
Loading…
Reference in New Issue
Block a user