zoukankan      html  css  js  c++  java
  • mongodb的db.stats

    glc-test:PRIMARY>  db.stats()
    {
            "db" : "eagle",
            "collections" : 9,
            "views" : 0,
            "objects" : 97609717,
            "avgObjSize" : 1081.2369183797553,
            "dataSize" : 105539229613,
            "storageSize" : 40286806016,
            "numExtents" : 0,
            "indexes" : 32,
            "indexSize" : 8504152064,
            "fsUsedSize" : 2066056126464,
            "fsTotalSize" : 2797758251008,
            "ok" : 1,
            "operationTime" : Timestamp(1606379817, 1),
            "$clusterTime" : {
                    "clusterTime" : Timestamp(1606379817, 1),
                    "signature" : {
                            "hash" : BinData(0,"6PcBNtC1REHC2tcgLx+UaD2oVww="),
                            "keyId" : NumberLong("6856584343653974019")
                    }
            }
    }
    glc-test:PRIMARY> show dbs
    admin          0.000GB
    ai_open_caps   0.000GB
    apple          0.045GB
    config         0.000GB
    eagle         45.440GB
    gallery        3.234GB
    google         0.000GB
    local         39.088GB
    pbm            0.000GB
    test           0.000GB
    glc-test:PRIMARY> 105539229613/1024/1024/1024
    98.29106704611331
    glc-test:PRIMARY> 40286806016/1024/1024/1024
    37.52001190185547
    glc-test:PRIMARY> 8504152064/1024/1024/1024
    7.920108795166016
    glc-test:PRIMARY> 

    数据大小约为:storageSize

    索引占用大小约为:indexSize

    当前数据库:eagle

    当前数据库的集合个数:collections

    当前数据库所有集合的行数:objects

    #############################################

  • 相关阅读:
    mybatis入门-1
    try-with-resources 在捕获异常之后自动释放资源 try(){}
    mybatis配置logback
    使用原生的jdbc连接数据库进行查询
    java中的反射
    ajax实现搜索自动补全
    java IO-1 File 2019-07-24
    VMware历史版本
    Centos8.3-NIS
    用户管理
  • 原文地址:https://www.cnblogs.com/igoodful/p/14043097.html
Copyright © 2011-2022 走看看