Mongodb – How to avoid warning with file system cache in mongodb

mongodbmongodb-3.6powershell

OS Windows 10 x64. Version of MongoDB 3.6.5

When I'm starting mongo process, I'm always getting:
enter image description here
MongoDB shell version v3.6.5 connecting to: mongodb://127.0.0.1:27017/
MongoDB server version: 3.6.5 Server has startup warnings: 2018-07-02T20:56:09.470+0300 I CONTROL [initandlisten] 2018-07-02T20:56:09.470+0300 I CONTROL [initandlisten] ** WARNING: The file system cache of this machine is configured to be greater than 40% of the total memory. This can lead to increased memory pressure and poor performance. 2018-07-02T20:56:09.470+0300 I CONTROL [initandlisten] See http://dochub.mongodb.org/core/wt-windows-system file-cache 2018-07-02T20:56:09.470+0300 I CONTROL [initandlisten]

Probably, same issue was here, but there isn't normal solution. I suppose that I need to add something in config file, for example – https://docs.mongodb.com/manual/reference/configuration-options/#storage-inmemory-options.

Now I have in config:

systemLog:
    destination: file
    logAppend: true
    path: c:\data\log\mongod.log
storage:
    dbPath: c:\data\db
    journal:
        enabled: true
replication:
   replSetName: "rs0"
net:
   bindIp: 127.0.0.1
   port: 27017
security:
     authorization: enabled

If I'm trying to add snippet:

inMemory:
      engineConfig:
         inMemorySizeGB: 10

The whole config looks like:

systemLog:
    destination: file
    logAppend: true
    path: c:\data\log\mongod.log
storage:
    dbPath: c:\data\db
    inMemory:
        engineConfig:
                inMemorySizeGB: 10
    journal:
        enabled: true
replication:
   replSetName: "rs0"
net:
   bindIp: 127.0.0.1
   port: 27017
security:
     authorization: enabled

Then getting the error Unrecognized option: storage.inMemory.engineConfig.inMemorySizeGB
enter image description here

P.S. I didn't use tab.

Any ideas how to avoid warning? Thanks.

Best Answer

Any ideas how to avoid warning?

This warning was added for some older implementations of MongoDB's WiredTiger storage engine, but is longer relevant in MongoDB 3.6. The warning has been removed in MongoDB 4.0 and the removal has been backported for the upcoming MongoDB 3.6.6 server release. See SERVER-33706 for more background.

You can ignore this warning until you upgrade to a version of MongoDB newer than 3.6.5.

Then getting the error Unrecognized option: storage.inMemory.engineConfig.inMemorySizeGB

This configuration option is for the In-Memory Storage Engine which is included in MongoDB Enterprise, and not relevant to the filesystem cache warning. The option will not be recognized unless you are running MongoDB Enterprise server.