MongoDB best configuration for a Forum with more than 100k users and 200k topics.
-
Now I fixed the auth issue, but the problem remains with the command
> MongoDB shell version: 2.6.5 connecting to: test > use nodebb switched to db nodebb > db.auth('myuser','mypass') 1 > db.collection.totalIndexSize() > db.collection.stats() { "ok" : 0, "errmsg" : "Collection [nodebb.collection] not found." }
-
Ok. The problem was the .collection
> db.stats() { "db" : "nodebb", "collections" : 5, "objects" : 10950579, "avgObjSize" : 559.5723418825617, "dataSize" : 6127641136, "storageSize" : 7159541760, "numExtents" : 28, "indexes" : 9, "indexSize" : 2563102416, "fileSize" : 10666115072, "nsSizeMB" : 16, "dataFileVersion" : { "major" : 4, "minor" : 6 }, "extentFreeList" : { "num" : 0, "totalSize" : 0 }, "ok" : 1 }
-
The problem is on the Category cause I have a lot of them.
What about the other issue with the cluster=8?
-
@baris mmm I'm using mongo.
I have to configure also redis together with mongo?
There is some more extensive docs about it specific to nodebb?
I found this https://github.com/deedw/mong.socket.io but it is already inside the nodebb packages or I have to install it and then put the configuration inside the nodebb config.json?
-
@andreapernici Officially, socket.io contains only an in-memory session adapter (which for obv. reasons won't work with a clustered setup), and a redis session adapter.
So if you're clustering w/ Mongo, you'll have to set up Redis alongside, and have both
mongo
andredis
configuration hashes in yourconfig.json
-
Ok. I understand.
I think it's correct. One of the thing I thought about NodeBB was that a good approach was to use Redis for notification etcetc and Mongo for the rest.
In this case to make a summary:
- install nodebb on Mongo.
- create a Redis instance.
- configure the json file with both mongo and redis references.
If you have some example feel free to share
-
This post is deleted!