On 5/23/21 8:48 PM, Han Han wrote:
You can check the following:1. Make sure the ceph mon node are running on the localhost:6789
root@server ~# netstat -pan | grep 6789
tcp 0 0 10.0.0.5:6789 0.0.0.0:* LISTEN 2087/ceph-mon
2. Check if the ceph authorization is enabled on the ceph cluster. Check if authorization isused in rbd pool xml.You can provide more details on the rbd pool xml, ceph conf, and the version of librbd1(client side), ceph(server side).
root@server ~# ceph auth get client.libvirt
exported keyring for client.libvirt
[client.libvirt]
key = AQDtM6lgXXXXXXXXpebpIoIKaFXQSTAg==
caps mon = "profile rbd"
caps osd = "profile rbd pool=libvirt-pool"
root@server ~# virsh secret-list
UUID Usage
--------------------------------------------------------------------
f290cb3a-a9de-48d7-89ce-09311eadff4a ceph client.libvirt secret
root@server ~# virsh secret-dumpxml f290cb3a-a9de-48d7-89ce-09311eadff4a
<secret ephemeral='no' private='no'>
<uuid>f290cb3a-a9de-48d7-89ce-09311eadff4a</uuid>
<usage type='ceph'>
<name>client.libvirt secret</name>
</usage>
</secret>
root@server ~# virsh pool-dumpxml libvirt-pool
<pool type='rbd'>
<name>libvirt-pool</name>
<uuid>5ae8abb9-31ab-44c0-a708-072b95182018</uuid>
<capacity unit='bytes'>0</capacity>
<allocation unit='bytes'>0</allocation>
<available unit='bytes'>0</available>
<source>
<host name='localhost' port='6789'/>
<name>libvirt-pool</name>
<auth type='ceph' username='libvirt'>
<secret uuid='f290cb3a-a9de-48d7-89ce-09311eadff4a'/>
</auth>
</source>
</pool>
root@server ~# ceph versions
{
"mon": {
"ceph version 15.2.12 (ce065eabfa5ce81323b009786bdf5bb03127cbe1) octopus (stable)": 2
},
"mgr": {
"ceph version 15.2.12 (ce065eabfa5ce81323b009786bdf5bb03127cbe1) octopus (stable)": 2
},
"osd": {
"ceph version 15.2.12 (ce065eabfa5ce81323b009786bdf5bb03127cbe1) octopus (stable)": 2
},
"mds": {},
"rgw": {
"ceph version 15.2.12 (ce065eabfa5ce81323b009786bdf5bb03127cbe1) octopus (stable)": 1
},
"overall": {
"ceph version 15.2.12 (ce065eabfa5ce81323b009786bdf5bb03127cbe1) octopus (stable)": 7
}
}
root@server ~# pkgfile /usr/lib/librbd.so.1.12.0
community/ceph-libs
root@server ~# pacsearch ceph-libs
community/ceph-libs 15.2.12-1 [installed]
Distributed, fault-tolerant storage platform delivering object, block, and file system
Sorry I should have included this information in my original email. I followed this guide (https://blog.modest-destiny.com/posts/kvm-libvirt-add-ceph-rbd-pool/) to setup the above configuration and I also tried following the guide at https://docs.ceph.com/en/latest/rbd/libvirt/