[SERVER-28404] Database Server has a lot of free ram but doen't use it Created: 21/Mar/17 Updated: 31/May/17 Resolved: 21/Mar/17 |
|
| Status: | Closed |
| Project: | Core Server |
| Component/s: | None |
| Affects Version/s: | None |
| Fix Version/s: | None |
| Type: | Question | Priority: | Major - P3 |
| Reporter: | Tobias S. Keller | Assignee: | Mark Agarunov |
| Resolution: | Done | Votes: | 0 |
| Labels: | None | ||
| Remaining Estimate: | Not Specified | ||
| Time Spent: | Not Specified | ||
| Original Estimate: | Not Specified | ||
| Participants: |
| Description |
|
We are running several aws ec2 servers with ubuntu 16.04 and mongodb that have all 2GB of ram, but the database does not use more than around 1GB even though the database itself is growing and growing in size. Is there any hidden setting that limits mongodb in the amount of ram it is allowed to use? |
| Comments |
| Comment by Mark Agarunov [ 21/Mar/17 ] |
|
Hello blinkit-tobi, Thank you for the report. Assuming you are using the WiredTiger storage engine, the default memory usage is 50% of RAM minus 1 GB, or 256MB, whichever is larger. This can be changed by setting the storage.wiredTiger.engineConfig.cacheSizeGB parameter in the configuration. Please note that SERVER project is for reporting bugs or feature suggestions for the MongoDB server. For MongoDB-related support discussion please post on the mongodb-user group or Stack Overflow with the mongodb tag. A question like this involving more discussion would be best posted on the mongodb-user group. Thanks, |