I am running in OpenVZ container with Ubuntu 14.04 LTS.
MongoDB version:
db version v3.0.4
git version: 0481c958daeb2969800511e7475dc66986fa9ed5
I use clean installation like described here - http://docs.mongodb.org/manual/tutorial/install-mongodb-on-ubuntu/
top
shows around 100% - 150% CPU
PID USER PR NI VIRT RES SHR S %CPU %MEM TIME+ COMMAND
30480 mongodb 20 0 548096 66920 39884 S 150.2 1.6 4:55.38 mongod
This is while nothing else is going on. Nothing else is running in the container. No queries, no connections.
I have tried lock file in this question: https://stackoverflow.com/questions/10747580/mongodb-service-at-100-cpu. It's not it.
Edit (Log file upon start)
2015-07-09T14:05:48.998+0200 I JOURNAL [initandlisten] journal dir=/var/lib/mongodb/journal
2015-07-09T14:05:48.998+0200 I JOURNAL [initandlisten] recover : no journal files present, no recovery needed
2015-07-09T14:05:49.061+0200 I JOURNAL [durability] Durability thread started
2015-07-09T14:05:49.061+0200 I JOURNAL [journal writer] Journal writer thread started
2015-07-09T14:05:49.062+0200 I CONTROL [initandlisten] MongoDB starting : pid=30480 port=27017 dbpath=/var/lib/mongodb 64-bit host=euler-dev
2015-07-09T14:05:49.062+0200 I CONTROL [initandlisten]
2015-07-09T14:05:49.062+0200 I CONTROL [initandlisten] ** WARNING: You are running in OpenVZ which can cause issues on versions of RHEL older than RHEL6.
2015-07-09T14:05:49.063+0200 I CONTROL [initandlisten]
2015-07-09T14:05:49.063+0200 I CONTROL [initandlisten] db version v3.0.4
2015-07-09T14:05:49.063+0200 I CONTROL [initandlisten] git version: 0481c958daeb2969800511e7475dc66986fa9ed5
2015-07-09T14:05:49.063+0200 I CONTROL [initandlisten] OpenSSL version: OpenSSL 1.0.1f 6 Jan 2014
2015-07-09T14:05:49.063+0200 I CONTROL [initandlisten] build info: Linux ip-10-45-73-23 3.13.0-24-generic #46-Ubuntu SMP Thu Apr 10 19:11:08 UTC 2014 x86_64 BOOST_LIB_VERSION=1_49
2015-07-09T14:05:49.063+0200 I CONTROL [initandlisten] allocator: tcmalloc
2015-07-09T14:05:49.063+0200 I CONTROL [initandlisten] options: { config: "/etc/mongod.conf", net: { bindIp: "127.0.0.1", port: 27017 }, storage: { dbPath: "/var/lib/mongodb" }, systemLog: { destination: "file", logAppend: true, path: "/var/log/mongodb/mongod.log" } }
2015-07-09T14:05:49.092+0200 I NETWORK [initandlisten] waiting for connections on port 27017
Edit2 more detailed logs
A log with journaling enabled: pastebin.com/kKx4SJ98
Journaling disabled: pastebin.com/s2GT71w7
With journaling disabled the CPU usage cuts in half (around 40% - 80%). This all when idle.
numactl
in OpenVZ box and also mongo doesn't issue any warning.