當前位置:編程學習大全網 - 源碼下載 - python mongodb 怎麽執行 db.serverstatus 命令

python mongodb 怎麽執行 db.serverstatus 命令

> db.serverStatus();

{

"host" : "localhost.localdomain", --hostname

"version" : "2.4.9", --版本

"process" : "mongod", --進程名稱

"pid" : 5099, --進程ID

"uptime" : 1595, --啟動時間(單位:S)

"uptimeMillis" : NumberLong(1595123),

"uptimeEstimate" : 1577, --基於MongoDB內部粗粒度定時器的運行時間

"localTime" : ISODate("2014-04-17T06:55:44.924Z"),--server的本地時間

"asserts" : {

"regular" : 0, --server啟動以來拋出正規斷言(assert 類似於異常處理的形式)總數目

"warning" : 0, --server啟動以來拋出的告警總數目

"msg" : 0, --消息斷言數目。服務器內部定義的良好字符串錯誤

"user" : 3, --用戶斷言數目。用戶產生的錯誤,譬如:磁盤空間滿;重復鍵。

"rollovers" : 0 --server啟動以來,assert counters have rolled over的次數

},

"backgroundFlushing" : {

"flushes" : 26, --數據庫刷新寫到磁盤的次數

"total_ms" : 67, --數據庫刷新數據到磁盤花費的微秒數

"average_ms" : 2.576923076923077,--執行單次刷新花費的平均微秒數

"last_ms" : 2, --最後壹次執行完成刷新數據到磁盤花費的微秒數

"last_finished" : ISODate("2014-04-17T06:55:09.819Z")--當最後壹次刷新數據完成時的時間戳

},

"connections" : {

"current" : 8, --當前活動連接量。連接到server的當前活躍連接數目

"available" : 72, --剩余空閑連接量。剩余的可用連接數目

"totalCreated" : NumberLong(754)

},

"cursors" : {

"totalOpen" : 0, --server為client保持的遊標(cursor)總數

"clientCursors_size" : 0,

"timedOut" : 0 --server啟動以來遊標(cursor)超時的總數

},

"dur" : {

"commits" : 30, --上壹間隔journal日誌發生commit的次數

"journaledMB" : 0, --上壹間隔寫到journal日誌的數據量(單位:MB)

"writeToDataFilesMB" : 0, --上壹間隔journal日誌寫到數據文件的數據量(單位:MB)

"compression" : 0, --

"commitsInWriteLock" : 0, --寫鎖期間發生commits的次數

"earlyCommits" : 0, --schedule時間前請求commit的次數

"timeMs" : {

"dt" : 3064,

"prepLogBuffer" : 0, --準備寫journal日誌花費的時間

"writeToJournal" : 0, --寫journal日誌花費的實際時間

"writeToDataFiles" : 0, --journal日誌後寫數據文件花費的時間

"remapPrivateView" : 0 --The amount of time spent remapping copy-on-write memory mapped views

}

},

"extra_info" : {

"note" : "fields vary by platform",

"heap_usage_bytes" : 3838448, --此過程中所有的堆字節數目。僅適用於Linux

"page_faults" : 31058356 --此過程中訪問內存中頁面失敗的總次數。僅適用於Linux

},

"globalLock" : {

"totalTime" : 1238418105923, --全局鎖創建的時間(單位:ms 微秒)

"lockTime" : 75055831911, --全局鎖保持的時間(單位:ms 微秒)

"ratio" : 0.06060621332329477, --lockTime和totalTime的比

"currentQueue" : {

"total" : 0, --等待全局鎖的隊列中操作數目

"readers" : 0, --等待讀鎖的隊列中操作數目

"writers" : 0 --等待寫鎖的隊列中操作數目

},

"activeClients" : {

"total" : 1, --連接到server的當前活動client數目

"readers" : 1, --執行讀操作的當前活動client數目

"writers" : 0 --執行寫操作的當前活動client數目

}

},

"indexCounters" : {

"accesses" : 196, --Btree索引的訪問次數(索引被訪問量)

"hits" : 196, --內存中的Btree頁的數目。(索引命中量)

"misses" : 0, --內存中不存在的Btree也數目。(索引偏差量)(索引內存訪問失敗次數)

"resets" : 0, --索引計數器被重置為0的次數

"missRatio" : 0 --索引偏差率(未命中率)

},

"locks" : {

"." : {

"timeLockedMicros" : {

"R" : NumberLong(39089),

"W" : NumberLong(43649)

},

"timeAcquiringMicros" : {

"R" : NumberLong(36077),

"W" : NumberLong(5232)

}

},

"admin" : {

"timeLockedMicros" : {

"r" : NumberLong(818),

"w" : NumberLong(0)

},

"timeAcquiringMicros" : {

"r" : NumberLong(70),

"w" : NumberLong(0)

}

},

"local" : {

"timeLockedMicros" : {

"r" : NumberLong(3414),

"w" : NumberLong(0)

},

"timeAcquiringMicros" : {

"r" : NumberLong(352),

"w" : NumberLong(0)

}

},

"WORKING_COLLECTION" : {

"timeLockedMicros" : {

"r" : NumberLong(1921),

"w" : NumberLong(0)

},

"timeAcquiringMicros" : {

"r" : NumberLong(138),

"w" : NumberLong(0)

}

},

"mydb" : {

"timeLockedMicros" : {

"r" : NumberLong(737),

"w" : NumberLong(0)

},

"timeAcquiringMicros" : {

"r" : NumberLong(92),

"w" : NumberLong(0)

}

},

"test" : {

"timeLockedMicros" : {

"r" : NumberLong(959),

"w" : NumberLong(0)

},

"timeAcquiringMicros" : {

"r" : NumberLong(81),

"w" : NumberLong(0)

}

},

"mdsp" : {

"timeLockedMicros" : {

"r" : NumberLong(261031),

"w" : NumberLong(6093)

},

"timeAcquiringMicros" : {

"r" : NumberLong(4956),

"w" : NumberLong(206)

}

}

},

"network" : {

"bytesIn" : NumberLong("1929833164782"), --發送到數據庫的數據總量(bytes)

"bytesOut" : 553137147925, --數據庫發出的數據總量(bytes)

"numRequests" : 2475184328 --發送到數據庫的請求量

},

"opcounters" : {

"insert" : 687531883, --server啟動以來總的insert數據量

"query" : 711010343, --server啟動以來總的query數據量

"update" : 0, --server啟動以來總的update數據量

"delete" : 0, --server啟動以來總的delete數據量

"getmore" : 6484, --server啟動以來調用任何遊標的getMore總次數

"command" : 1287537 --server啟動以來執行其他命令的總次數

},

"opcountersRepl" : {

"insert" : 0,

"query" : 0,

"update" : 0,

"delete" : 0,

"getmore" : 0,

"command" : 0

},

"recordStats" : {

"accessesNotInMemory" : 6,

"pageFaultExceptionsThrown" : 5,

"WORKING_COLLECTION" : {

"accessesNotInMemory" : 0,

"pageFaultExceptionsThrown" : 0

},

"admin" : {

"accessesNotInMemory" : 0,

"pageFaultExceptionsThrown" : 0

},

"local" : {

"accessesNotInMemory" : 0,

"pageFaultExceptionsThrown" : 0

},

"mdsp" : {

"accessesNotInMemory" : 6,

"pageFaultExceptionsThrown" : 5

},

"mydb" : {

"accessesNotInMemory" : 0,

"pageFaultExceptionsThrown" : 0

},

"test" : {

"accessesNotInMemory" : 0,

"pageFaultExceptionsThrown" : 0

}

},

"writeBacksQueued" : false,

"mem" : {

"bits" : 64,

"resident" : 43,

"virtual" : 2326,

"supported" : true,

"mapped" : 992,

"mappedWithJournal" : 1984

},

"metrics" : {

"document" : {

"deleted" : NumberLong(0),

"inserted" : NumberLong(10),

"returned" : NumberLong(1067),

"updated" : NumberLong(20)

},

"getLastError" : {

"wtime" : {

"num" : 0,

"totalMillis" : 0

},

"wtimeouts" : NumberLong(0)

},

"operation" : {

"fastmod" : NumberLong(13),

"idhack" : NumberLong(118),

"scanAndOrder" : NumberLong(122)

},

"queryExecutor" : {

"scanned" : NumberLong(10262)

},

"record" : {

"moves" : NumberLong(0)

},

"repl" : {

"apply" : {

"batches" : {

"num" : 0,

"totalMillis" : 0

},

"ops" : NumberLong(0)

},

"buffer" : {

"count" : NumberLong(0),

"maxSizeBytes" : 268435456,

"sizeBytes" : NumberLong(0)

},

"network" : {

"bytes" : NumberLong(0),

"getmores" : {

"num" : 0,

"totalMillis" : 0

},

"ops" : NumberLong(0),

"readersCreated" : NumberLong(0)

},

"oplog" : {

"insert" : {

"num" : 0,

"totalMillis" : 0

},

"insertBytes" : NumberLong(0)

},

"preload" : {

"docs" : {

"num" : 0,

"totalMillis" : 0

},

"indexes" : {

"num" : 0,

"totalMillis" : 0

}

}

},

"ttl" : {

"deletedDocuments" : NumberLong(0),

"passes" : NumberLong(26)

}

},

"ok" : 1

}

  • 上一篇:無基礎,如何學好Python?
  • 下一篇:足跡源代碼
  • copyright 2024編程學習大全網