diff --git a/src/dnode/src/dnodeMain.c b/src/dnode/src/dnodeMain.c index 16f97d0eea8b12bd29d52ed77e9940cf54a5b3ac..c24eac84cf1796e05b2ee73e069067adbaf619a4 100644 --- a/src/dnode/src/dnodeMain.c +++ b/src/dnode/src/dnodeMain.c @@ -189,6 +189,11 @@ static void dnodeCheckDataDirOpenned(char *dir) { } static int32_t dnodeInitStorage() { + if (tsDiskCfgNum == 1 && dnodeCreateDir(tsDataDir) < 0) { + dError("failed to create dir: %s, reason: %s", tsDataDir, strerror(errno)); + return -1; + } + if (tfsInit(tsDiskCfg, tsDiskCfgNum) < 0) { dError("failed to init TFS since %s", tstrerror(terrno)); return -1;