Skip to content

HTTPS clone URL

Subversion checkout URL

You can clone with HTTPS or Subversion.

Download ZIP
Mongostat for the ObjectRocket platform. Based on the original python mongostat implementation
Python

Merge pull request #20 from objectrocket/use_local_timestamps

Adds an option to compute stats based on local timestamps.
latest commit 79eb2c5a6f
@dbmurphy dbmurphy authored

README.md

Overview

Rocketstat is essentially a copy of the original python 'mongostat' utility written by Kenny Gorman in 2010, however it's designed to utilize the ObjectRocket public API as a data source. The functionality should roughly mirror the 10gen utility called 'mongostat' where it makes sense. Some stats don't translate to the ObjectRocket cloud service and thus are omitted. A guideline of the values reported can be found in the 10gen docs.

Requires: python 2.7.x

Usage

In order to use rocketstat you will need an ObjectRocket API Key. You will need to signup for a Objectrocket account, create an instance, then select the API tab under your instance. Copy/Paste the API key to the command line below.

Rocketstat reports aggregate stats across your entire instance. That means that your data is summated across all the shards. You are seeing total overall statistics about your MongoDB instance on ObjectRocket.

usage: rocketstat [-h] -a API_KEY [-H HOSTNAME]

ObjectRocket stat utility. See www.objectrocket.com for an account.

optional arguments:
  -h, --help            show this help message and exit
  -a API_KEY, --api_key API_KEY
                        ObjectRocket API key.
  -H HOSTNAME, --hostname HOSTNAME
                        hostname to connect to.

$>python rocketstat --api_key=your_api_key
  instance                  time     query    insert    update    delete     aconn     lock%    queued    active    idxacc    idxhit   idxmiss      idx%
test         31-07-2012.09:35:20     35684        96     74488         0       372       0.0         0         2         0         0         0       0.0
test         31-07-2012.09:35:30         1         0         3         0       372       0.0         0         2         0         0         0       0.0

License

Copyright 2012 ObjectRocket Inc.

Licensed under the Apache License, Version 2.0 (the "License"); you may not use this file except in compliance with the License. You may obtain a copy of the License at

http://www.apache.org/licenses/LICENSE-2.0

Unless required by applicable law or agreed to in writing, software distributed under the License is distributed on an "AS IS" BASIS, WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. See the License for the specific language governing permissions and limitations under the License.

Something went wrong with that request. Please try again.