diff options
author | Daniel Baumann <daniel.baumann@progress-linux.org> | 2024-04-21 11:54:28 +0000 |
---|---|---|
committer | Daniel Baumann <daniel.baumann@progress-linux.org> | 2024-04-21 11:54:28 +0000 |
commit | e6918187568dbd01842d8d1d2c808ce16a894239 (patch) | |
tree | 64f88b554b444a49f656b6c656111a145cbbaa28 /src/test/cli/osdmaptool/create-print.t | |
parent | Initial commit. (diff) | |
download | ceph-e6918187568dbd01842d8d1d2c808ce16a894239.tar.xz ceph-e6918187568dbd01842d8d1d2c808ce16a894239.zip |
Adding upstream version 18.2.2.upstream/18.2.2
Signed-off-by: Daniel Baumann <daniel.baumann@progress-linux.org>
Diffstat (limited to 'src/test/cli/osdmaptool/create-print.t')
-rw-r--r-- | src/test/cli/osdmaptool/create-print.t | 97 |
1 files changed, 97 insertions, 0 deletions
diff --git a/src/test/cli/osdmaptool/create-print.t b/src/test/cli/osdmaptool/create-print.t new file mode 100644 index 000000000..9d745b82f --- /dev/null +++ b/src/test/cli/osdmaptool/create-print.t @@ -0,0 +1,97 @@ + $ osdmaptool --createsimple 3 myosdmap --with-default-pool + osdmaptool: osdmap file 'myosdmap' + osdmaptool: writing epoch 1 to myosdmap + + $ osdmaptool --export-crush oc myosdmap + osdmaptool: osdmap file 'myosdmap' + osdmaptool: exported crush map to oc + $ crushtool --decompile oc + # begin crush map + tunable choose_local_tries 0 + tunable choose_local_fallback_tries 0 + tunable choose_total_tries 50 + tunable chooseleaf_descend_once 1 + tunable chooseleaf_vary_r 1 + tunable chooseleaf_stable 1 + tunable straw_calc_version 1 + tunable allowed_bucket_algs 54 + + # devices + device 0 osd.0 + device 1 osd.1 + device 2 osd.2 + + # types + type 0 osd + type 1 host + type 2 chassis + type 3 rack + type 4 row + type 5 pdu + type 6 pod + type 7 room + type 8 datacenter + type 9 zone + type 10 region + type 11 root + + # buckets + host localhost { + \tid -2\t\t# do not change unnecessarily (esc) + \t# weight 3.00000 (esc) + \talg straw2 (esc) + \thash 0\t# rjenkins1 (esc) + \titem osd.0 weight 1.00000 (esc) + \titem osd.1 weight 1.00000 (esc) + \titem osd.2 weight 1.00000 (esc) + } + rack localrack { + \tid -3\t\t# do not change unnecessarily (esc) + \t# weight 3.00000 (esc) + \talg straw2 (esc) + \thash 0\t# rjenkins1 (esc) + \titem localhost weight 3.00000 (esc) + } + root default { + \tid -1\t\t# do not change unnecessarily (esc) + \t# weight 3.00000 (esc) + \talg straw2 (esc) + \thash 0\t# rjenkins1 (esc) + \titem localrack weight 3.00000 (esc) + } + + # rules + rule replicated_rule { + \tid 0 (esc) + \ttype replicated (esc) + \tstep take default (esc) + \tstep chooseleaf firstn 0 type host (esc) + \tstep emit (esc) + } + + # end crush map + $ osdmaptool --print myosdmap + osdmaptool: osdmap file 'myosdmap' + epoch 1 + fsid [0-9a-f]{8}-[0-9a-f]{4}-[0-9a-f]{4}-[0-9a-f]{4}-[0-9a-f]{12} (re) + created \d{4}-\d{2}-\d{2}T\d{2}:\d{2}:\d{2}\.\d+.\d\d\d\d (re) + modified \d{4}-\d{2}-\d{2}T\d{2}:\d{2}:\d{2}\.\d+.\d\d\d\d (re) + flags + crush_version 1 + full_ratio 0 + backfillfull_ratio 0 + nearfull_ratio 0 + min_compat_client jewel + stretch_mode_enabled false + + pool 1 'rbd' replicated size 3 min_size 2 crush_rule 0 object_hash rjenkins pg_num 192 pgp_num 192 autoscale_mode on last_change 0 flags hashpspool stripe_width 0 application rbd + + max_osd 3 + + $ osdmaptool --clobber --createsimple 3 --with-default-pool myosdmap + osdmaptool: osdmap file 'myosdmap' + osdmaptool: writing epoch 1 to myosdmap + $ osdmaptool --print myosdmap | grep 'pool 1' + osdmaptool: osdmap file 'myosdmap' + pool 1 'rbd' replicated size 3 min_size 2 crush_rule 0 object_hash rjenkins pg_num 192 pgp_num 192 autoscale_mode on last_change 0 flags hashpspool stripe_width 0 application rbd + $ rm -f myosdmap |