TiKV不支持ZFS系统部署?

在尝试将TiDB部署在单机系统上时,发现当TiKV的data目录为zfs时,tikv启动会报错,同样配置文件,放到ext4或者xfs时就正常。zfs报错内容为:

failed to open raft engine: Other("[components/raft_log_engine/src/engine.rs:464]: IO Error: fallocate")] [backtrace=   0: tikv_util::set_panic_hook::{{closure}}
             at /home/jenkins/agent/workspace/build-common/go/src/github.com/pingcap/tikv/components/tikv_util/src/lib.rs:490:18
   1: std::panicking::rust_panic_with_hook
             at /rust/toolchains/nightly-2022-02-14-x86_64-unknown-linux-gnu/lib/rustlib/src/rust/library/std/src/panicking.rs:702:17
   2: std::panicking::begin_panic_handler::{{closure}}
             at /rust/toolchains/nightly-2022-02-14-x86_64-unknown-linux-gnu/lib/rustlib/src/rust/library/std/src/panicking.rs:588:13
   3: std::sys_common::backtrace::__rust_end_short_backtrace
             at /rust/toolchains/nightly-2022-02-14-x86_64-unknown-linux-gnu/lib/rustlib/src/rust/library/std/src/sys_common/backtrace.rs:138:18
   4: rust_begin_unwind
             at /rust/toolchains/nightly-2022-02-14-x86_64-unknown-linux-gnu/lib/rustlib/src/rust/library/std/src/panicking.rs:584:5
   5: core::panicking::panic_fmt
             at /rust/toolchains/nightly-2022-02-14-x86_64-unknown-linux-gnu/lib/rustlib/src/rust/library/core/src/panicking.rs:143:14
   6: core::result::unwrap_failed
             at /rust/toolchains/nightly-2022-02-14-x86_64-unknown-linux-gnu/lib/rustlib/src/rust/library/core/src/result.rs:1749:5
   7: core::result::Result<T,E>::expect
             at /rust/toolchains/nightly-2022-02-14-x86_64-unknown-linux-gnu/lib/rustlib/src/rust/library/core/src/result.rs:1022:23
      <raft_log_engine::engine::RaftLogEngine as server::server::ConfiguredRaftEngine>::build
             at /home/jenkins/agent/workspace/build-common/go/src/github.com/pingcap/tikv/components/server/src/server.rs:1434:13
      server::server::TiKvServer<CER>::init_raw_engines
             at /home/jenkins/agent/workspace/build-common/go/src/github.com/pingcap/tikv/components/server/src/server.rs:1468:27
   8: server::server::run_impl
             at /home/jenkins/agent/workspace/build-common/go/src/github.com/pingcap/tikv/components/server/src/server.rs:129:35
      server::server::run_tikv
             at /home/jenkins/agent/workspace/build-common/go/src/github.com/pingcap/tikv/components/server/src/server.rs:163:5
   9: tikv_server::main
             at /home/jenkins/agent/workspace/build-common/go/src/github.com/pingcap/tikv/cmd/tikv-server/src/main.rs:189:5
  10: core::ops::function::FnOnce::call_once
             at /rust/toolchains/nightly-2022-02-14-x86_64-unknown-linux-gnu/lib/rustlib/src/rust/library/core/src/ops/function.rs:227:5
      std::sys_common::backtrace::__rust_begin_short_backtrace
             at /rust/toolchains/nightly-2022-02-14-x86_64-unknown-linux-gnu/lib/rustlib/src/rust/library/std/src/sys_common/backtrace.rs:122:18
  11: main
  12: __libc_start_main
  13: <unknown>

生产环境建议用ext4,其可靠性、安全性、稳定性已经在大量线上场景中得到证实。

这个是测试环境,本来是准备用ZFS的snapshot & rollback做测试环境的回滚方案

目前还没见过有用zfs文件系统的案例,tug大佬们讨论过这个问题
https://asktug.com/t/topic/153608

不是ZFS兼容问题,同样的Ubuntu版本、同样的zfs版本、同样的TiDB配置、同样的TiDB版本,在阿里云能正常搭建,在腾讯云搭建就报上边错误了,估计是腾讯云的内核进行魔改了。

此话题已在最后回复的 60 天后被自动关闭。不再允许新回复。