zoukankan      html  css  js  c++  java
  • 查看osdmap命令

    标签(空格分隔): ceph,ceph运维,osdmap


    方法一:

    最直接,简单的命令:

    [root@node3 ~]# ceph osd tree
    ID CLASS WEIGHT  TYPE NAME      STATUS REWEIGHT PRI-AFF 
    -1       0.05878 root default                           
    -3       0.01959     host node1                         
     0   hdd 0.00980         osd.0      up  1.00000 1.00000 
    -5       0.01959     host node2                         
     1   hdd 0.00980         osd.1      up  1.00000 1.00000 
    -7       0.01959     host node3                         
     2   hdd 0.00980         osd.2      up  1.00000 1.00000 
    

    这个命令获取的信息较为简单,下面的是获取详细信息的命令

    [root@node3 ~]# ceph osd dump
    osdmaptool: osdmap file 'osdmap'
    epoch 40
    fsid b8b4aa68-d825-43e9-a60a-781c92fec20e
    created 2017-10-16 15:51:13.675888
    modified 2017-10-16 16:14:25.041923
    flags sortbitwise,recovery_deletes,purged_snapdirs
    crush_version 13
    full_ratio 0.95
    backfillfull_ratio 0.9
    nearfull_ratio 0.85
    require_min_compat_client jewel
    min_compat_client jewel
    require_osd_release luminous
    
    pool 1 'rbd' replicated size 3 min_size 2 crush_rule 0 object_hash rjenkins pg_num 64 pgp_num 64 last_change 26 flags hashpspool stripe_width 0
    
    max_osd 3
    osd.0 up   in  weight 1 up_from 30 up_thru 38 down_at 28 last_clean_interval [5,29) 192.168.197.154:6801/7155 192.168.197.154:6809/1007155 192.168.197.154:6810/1007155 192.168.197.154:6811/1007155 exists,up 26c07bad-69d3-4c9f-80ee-9c0af7c9fc92
    osd.1 up   in  weight 1 up_from 35 up_thru 38 down_at 31 last_clean_interval [9,28) 192.168.197.156:6800/6496 192.168.197.156:6801/6496 192.168.197.156:6802/6496 192.168.197.156:6803/6496 exists,up 013fafd1-cfde-48e7-82ed-1e5c0d7c0b74
    osd.2 up   in  weight 1 up_from 35 up_thru 35 down_at 29 last_clean_interval [13,28) 192.168.197.157:6800/6433 192.168.197.157:6801/6433 192.168.197.157:6802/6433 192.168.197.157:6803/6433 exists,up f9c20128-2c2d-46ba-adfd-12e8263d3077
    

    这里的epoch 40表示的是osdmap的版本号,说明当前的osdmap的版本号为40

    方法二:

    1. 从集群获取osdmap:

    [root@node3 ~]# ceph osd getmap -o osdmap
    got osdmap epoch 40
    

    这里的epoch 40表示的是osdmap的版本号,说明当前的osdmap的版本号为40

    2. 查看上一步获取的osdmap:

    [root@node3 ~]# osdmaptool --print osdmap
    osdmaptool: osdmap file 'osdmap'
    epoch 40
    fsid b8b4aa68-d825-43e9-a60a-781c92fec20e
    created 2017-10-16 15:51:13.675888
    modified 2017-10-16 16:14:25.041923
    flags sortbitwise,recovery_deletes,purged_snapdirs
    crush_version 13
    full_ratio 0.95
    backfillfull_ratio 0.9
    nearfull_ratio 0.85
    require_min_compat_client jewel
    min_compat_client jewel
    require_osd_release luminous
    
    pool 1 'rbd' replicated size 3 min_size 2 crush_rule 0 object_hash rjenkins pg_num 64 pgp_num 64 last_change 26 flags hashpspool stripe_width 0
    
    max_osd 3
    osd.0 up   in  weight 1 up_from 30 up_thru 38 down_at 28 last_clean_interval [5,29) 192.168.197.154:6801/7155 192.168.197.154:6809/1007155 192.168.197.154:6810/1007155 192.168.197.154:6811/1007155 exists,up 26c07bad-69d3-4c9f-80ee-9c0af7c9fc92
    osd.1 up   in  weight 1 up_from 35 up_thru 38 down_at 31 last_clean_interval [9,28) 192.168.197.156:6800/6496 192.168.197.156:6801/6496 192.168.197.156:6802/6496 192.168.197.156:6803/6496 exists,up 013fafd1-cfde-48e7-82ed-1e5c0d7c0b74
    osd.2 up   in  weight 1 up_from 35 up_thru 35 down_at 29 last_clean_interval [13,28) 192.168.197.157:6800/6433 192.168.197.157:6801/6433 192.168.197.157:6802/6433 192.168.197.157:6803/6433 exists,up f9c20128-2c2d-46ba-adfd-12e8263d3077
    
  • 相关阅读:
    [置顶] Spring的自动装配
    BZOJ2831(小强的金字塔系列问题--区域整点数求法)
    国际跆拳道联盟
    Linux如何查找某个时间点后生成的空文件
    ORACLE中关于外键缺少索引的探讨和总结
    ORA-12514, TNS:listener does not currently know of service requested in connect descriptor案例2
    SQL Server 2005 sp_send_dbmail出现Internal error at FormatRowset (Reason: Not enough storage is available to complete this operation)
    SQL Server数据库邮件发送异常案例
    MySQL二进制日志总结
    OSWatcher使用过程中小问题解决方法
  • 原文地址:https://www.cnblogs.com/sisimi/p/7737177.html
Copyright © 2011-2022 走看看