[SERVER-4407] Log warnings on startup if (hard) rlimits are no good Created: 01/Dec/11 Updated: 03/Jun/19 Resolved: 17/May/12 |
|
| Status: | Closed |
| Project: | Core Server |
| Component/s: | Logging |
| Affects Version/s: | None |
| Fix Version/s: | 2.1.2 |
| Type: | Improvement | Priority: | Minor - P4 |
| Reporter: | Richard Kreuter (Inactive) | Assignee: | Kevin Matulef |
| Resolution: | Done | Votes: | 0 |
| Labels: | None | ||
| Remaining Estimate: | Not Specified | ||
| Time Spent: | Not Specified | ||
| Original Estimate: | Not Specified | ||
| Issue Links: |
|
||||||||||||||||||||
| Participants: | |||||||||||||||||||||
| Description |
|
Some Linux distros have unusably low limits for things like number of processes or file descriptors. It would be handy if we checked the rlimits on startup and complained if the limits were too low for typical MongoDB uses. |
| Comments |
| Comment by Kevin Matulef [ 07/Mar/12 ] |
|
I moved the rlimit check so that it happens in a much saner place, along with other checks that happen at startup. However, the check is currently only performed on certain platforms. I need to do some research to figure out how to perform the check on the other platforms (i.e. windows), so I'm leaving this ticket open for now, but will reschedule it for the next version. |
| Comment by auto [ 07/Mar/12 ] |
|
Author: {u'login': u'matulef', u'name': u'Kevin Matulef', u'email': u'matulef@gmail.com'}Message: |
| Comment by Richard Kreuter (Inactive) [ 09/Feb/12 ] |
|
Please add a test for this. Something like ulimit <something low> |
| Comment by Richard Kreuter (Inactive) [ 09/Feb/12 ] |
|
The rlimit warnings are being printed at the beginning of main(), before argument parsing and logpath setup, and so (a) they're cluttering up the --version output, and, more importantly (b) they won't end up in the user's log file. Cf. $ ./mongod --logpath /tmp/log --fork |
| Comment by auto [ 21/Dec/11 ] |
|
Author: {u'login': u'matulef', u'name': u'Kevin Matulef', u'email': u'matulef@gmail.com'}Message: |