In addition to Weibo, there is also WeChat
Please pay attention
WeChat public account
Shulou
2025-01-18 Update From: SLTechnology News&Howtos shulou NAV: SLTechnology News&Howtos > Development >
Share
Shulou(Shulou.com)06/01 Report--
This article mainly shows you "how to locate the file location in ceph", the content is easy to understand, clear, hope to help you solve your doubts, the following let the editor lead you to study and learn "how to locate the file location in ceph" this article.
Locate the file location
Upload files using rados put and view files using map
[root@osd2 software] # md5sum epel-release-6-8.noarch.rpm 2cd0ae668a585a14e07c2ea4f264d79b epel-release-6-8.noarch.rpm [root@osd2 software] # rados put-p myrbd epel.rpm. / epel-release-6-8.noarch.rpm [root@osd2 software] # ceph osdmap myrbd epel.rpmosdmap e88 pool 'myrbd' (4) object' epel.rpm'-> pg 4.e9ddf5be (4.be)-> up ([4jue 2], p4) acting ([4jue 2], p4)
View the location and verify:
[root@osd2 software] # ceph osd tree# id weight type name up/down reweight-1 10.92 root default-2 3.64 host mon00 1.82 osd.0 up 1 11.82 osd.1 up 1-3 3.64 host osd12 1.82 Osd.2 up 1 31.82 osd.3 up 1-4 3.64 host osd24 1.82 osd.4 up 1 51.82 osd.5 up 1 [root@osd2 software] # Cd / cephmp1/current/4.be_head/ [root @ osd2 4.be_head] # lsepel.rpm__head_E9DDF5BE__4 [root@osd2 4.be_head] # md5sum epel.rpm__head_E9DDF5BE__4 2cd0ae668a585a14e07c2ea4f264d79b epel.rpm__head_E9DDF5BE__4 [root@osd2 4.be_head] # ll-htotal 20KMurray 1 root root 15K Nov 4 17:59 epel.rpm__head_E9DDF5BE__4
Verify after uploading with rbd input:
[root@osd2 software] # touch hello.txt [root@osd2 software] # echo "hello world" > > hello.txt [root@osd2 software] # rbd import. / hello.txt myrbd/hello.txtImporting image: 100% complete...done. [root@osd2 software] # rbd info myrbd/hello.txtrbd image 'hello.txt': size 12 bytes in 1 objects order 22 (4096 kB objects) block_name_prefix: rb.0.1365.6b8b4567 format: 1 [root@osd2 software] # rados ls-p myrbdrbd_data.13446b8b4567.00000000000000barbd_directoryrbd_data.13446b8b4567.000000000000007drbd_data.13446b8b4567.000000000000007crbd_data.13446b8b4567.000000000000005drbd_data.13446b8b4567.000000000000007erbd_data.13446b8b4567.00000000000000ffrb.0.1365.6b8b4567.000000000000hello.txt.rbdrbd_data.13446b8b4567.00000000000000d9rbd_data.13446b8b4567.00000000000000f8rbd_data.13446b8b4567.000000000000009brbd_data.13446b8b4567.0000000000000001rbd_header.13446b8b4567epel.rpmrbd_data.13446b8b4567.000000000000001frbd_data.13446b8b4567.000000000000003erbd_id.rbd1rbd_data.13446b8b4567.0000000000000000# got it like this The location information is incorrect [root@osd2 software] # ceph osdmap myrbd hello.txtosdmap E88 pool 'myrbd' (4) object' hello.txt'-> pg 4.d92fd82b (4.2b)-> up ([4JE3] P4) acting ([4jue 3], p4) # needs to add .rbd [root@osd2 current] # ceph osdmap myrbd hello.txt.rbdosdmap e88 pool 'myrbd' (4) object' hello.txt.rbd'-> pg 4.9b9bf373 (4.73)-> up ([3jue 1], p3) acting ([3jue 1] P3) [root@osd2 current] # ssh osd1 [root@osd1 ~] # cd / cephmp2/current/4.73_head/ [root @ osd1 4.73_head] # ll-htotal 8.0K Murray RWFUR-1 root root 112 Nov 4 18:08 hello.txt.rbd__head_9B9BF373__4 [root@osd1 4.73_head] # cat hello.txt.rbd__head_9B9BF373__4 > rb.0.1365.6b8b4567RBD001.005# if it is an ordinary rbd block Format-1 type rbd block: # ceph osd map test test.img.rbd#format-2 type rbd block: # ceph osd map test rbd_id.test.img above is all the content of this article "how to locate a file location in ceph". Thank you for reading! I believe we all have a certain understanding, hope to share the content to help you, if you want to learn more knowledge, welcome to follow the industry information channel!
Welcome to subscribe "Shulou Technology Information " to get latest news, interesting things and hot topics in the IT industry, and controls the hottest and latest Internet news, technology news and IT industry trends.
Views: 0
*The comments in the above article only represent the author's personal views and do not represent the views and positions of this website. If you have more insights, please feel free to contribute and share.
Continue with the installation of the previous hadoop.First, install zookooper1. Decompress zookoope
"Every 5-10 years, there's a rare product, a really special, very unusual product that's the most un
© 2024 shulou.com SLNews company. All rights reserved.