Add info to local.myhoststartup or similar, idea is to record node start state and history information to aid diagnosis of issues etc.
Implementation is as follows:
Add a capped collection in local.startup_log of size 1MB to store the information for mongod with the following format:
{
"_id" : "Daniels-MacBook-Air-2.local-1357416138107", //hostname + ms since the epoch
"hostname" : "Daniels-MacBook-Air-2.local",
"startTime" : ISODate("2013-01-05T20:02:18Z"),
"startTimeLocal" : "Sat Jan 5 12:02:18.107",
"cmdLine" : {
"dbpath" : "/data/db/auth10",
"keyFile" : "jstests/libs/key1",
"port" : 30000
},
"pid" : 68783,
"buildinfo" : {
"version" : "2.3.2-pre-",
"gitVersion" : "941c5bd713c16ef82f2be71fcb3b6af19f414512",
"sysInfo" : "Darwin Daniels-MacBook-Air-2.local 11.4.2 Darwin Kernel Version 11.4.2: Thu Aug 23 16:25:48 PDT 2012; root:xnu-1699.32.7~1/RELEASE_X86_64 x86_64 BOOST_LIB_VERSION=1_49",
"loaderFlags" : "-fPIC -pthread -rdynamic",
"compilerFlags" : "-Wnon-virtual-dtor -Woverloaded-virtual -fPIC -fno-strict-aliasing -ggdb -pthread -Wall -Wsign-compare -Wno-unknown-pragmas -Winvalid-pch -O3",
"allocator" : "tcmalloc",
"versionArray" : [
2,
3,
2,
-100
],
"javascriptEngine" : "v8",
"bits" : 64,
"debug" : false,
"maxBsonObjectSize" : 16777216
}
}