MongoDB 启动数据库实例报错Requested option conflicts with current storage engine option

38 阅读1分钟

1. 报错信息

{"t":{"$date":"2025-02-10T11:56:10.351+08:00"},"s":"E",  "c":"CONTROL",  "id":20557,   "ctx":"initandlisten","msg":"DBException in initAndListen, terminating","attr":{"error":"InvalidOptions: Requested option conflicts with current storage engine option for directoryPerDB; you requested false but the current server storage is already set to true and cannot be changed"}}

2. 解决方式

2.1 删除原有数据库目录下的 storage.bson 文件

image.png