1dfc5606dSYehuda SadehWhat: /sys/bus/rbd/ 2dfc5606dSYehuda SadehDate: November 2010 355b00baeSSage WeilContact: Yehuda Sadeh <yehuda@newdream.net>, 4dfc5606dSYehuda Sadeh Sage Weil <sage@newdream.net> 5dfc5606dSYehuda SadehDescription: 6dfc5606dSYehuda Sadeh 7dfc5606dSYehuda SadehBeing used for adding and removing rbd block devices. 8dfc5606dSYehuda Sadeh 9dfc5606dSYehuda SadehUsage: <mon ip addr> <options> <pool name> <rbd image name> [snap name] 10dfc5606dSYehuda Sadeh 11dfc5606dSYehuda Sadeh $ echo "192.168.0.1 name=admin rbd foo" > /sys/bus/rbd/add 12dfc5606dSYehuda Sadeh 13dfc5606dSYehuda SadehThe snapshot name can be "-" or omitted to map the image read/write. A <dev-id> 14dfc5606dSYehuda Sadehwill be assigned for any registered block device. If snapshot is used, it will 15dfc5606dSYehuda Sadehbe mapped read-only. 16dfc5606dSYehuda Sadeh 17dfc5606dSYehuda SadehRemoval of a device: 18dfc5606dSYehuda Sadeh 19dfc5606dSYehuda Sadeh $ echo <dev-id> > /sys/bus/rbd/remove 20dfc5606dSYehuda Sadeh 219b60e70bSIlya DryomovWhat: /sys/bus/rbd/add_single_major 229b60e70bSIlya DryomovDate: December 2013 239b60e70bSIlya DryomovKernelVersion: 3.14 249b60e70bSIlya DryomovContact: Sage Weil <sage@inktank.com> 259b60e70bSIlya DryomovDescription: Available only if rbd module is inserted with single_major 269b60e70bSIlya Dryomov parameter set to true. 279b60e70bSIlya Dryomov Usage is the same as for /sys/bus/rbd/add. If present, 289b60e70bSIlya Dryomov should be used instead of the latter: any attempts to use 299b60e70bSIlya Dryomov /sys/bus/rbd/add if /sys/bus/rbd/add_single_major is 309b60e70bSIlya Dryomov available will fail for backwards compatibility reasons. 319b60e70bSIlya Dryomov 329b60e70bSIlya DryomovWhat: /sys/bus/rbd/remove_single_major 339b60e70bSIlya DryomovDate: December 2013 349b60e70bSIlya DryomovKernelVersion: 3.14 359b60e70bSIlya DryomovContact: Sage Weil <sage@inktank.com> 369b60e70bSIlya DryomovDescription: Available only if rbd module is inserted with single_major 379b60e70bSIlya Dryomov parameter set to true. 389b60e70bSIlya Dryomov Usage is the same as for /sys/bus/rbd/remove. If present, 399b60e70bSIlya Dryomov should be used instead of the latter: any attempts to use 409b60e70bSIlya Dryomov /sys/bus/rbd/remove if /sys/bus/rbd/remove_single_major is 419b60e70bSIlya Dryomov available will fail for backwards compatibility reasons. 429b60e70bSIlya Dryomov 43dfc5606dSYehuda SadehEntries under /sys/bus/rbd/devices/<dev-id>/ 44dfc5606dSYehuda Sadeh-------------------------------------------- 45dfc5606dSYehuda Sadeh 46005a07bfSIlya Dryomovclient_addr 47005a07bfSIlya Dryomov 48005a07bfSIlya Dryomov The ceph unique client entity_addr_t (address + nonce). 49005a07bfSIlya Dryomov The format is <address>:<port>/<nonce>: '1.2.3.4:1234/5678' or 50005a07bfSIlya Dryomov '[1:2:3:4:5:6:7:8]:1234/5678'. (August 2016, since 4.9.) 51005a07bfSIlya Dryomov 52dfc5606dSYehuda Sadehclient_id 53dfc5606dSYehuda Sadeh 54dfc5606dSYehuda Sadeh The ceph unique client id that was assigned for this specific session. 55dfc5606dSYehuda Sadeh 56*267fb90bSMike Christiecluster_fsid 57*267fb90bSMike Christie 58*267fb90bSMike Christie The ceph cluster UUID. (August 2016, since 4.9.) 59*267fb90bSMike Christie 6034b13184SAlex Elderfeatures 6134b13184SAlex Elder 6234b13184SAlex Elder A hexadecimal encoding of the feature bits for this image. 6334b13184SAlex Elder 64dfc5606dSYehuda Sadehmajor 65dfc5606dSYehuda Sadeh 66dfc5606dSYehuda Sadeh The block device major number. 67dfc5606dSYehuda Sadeh 68dd82fff1SIlya Dryomovminor 69dd82fff1SIlya Dryomov 70dd82fff1SIlya Dryomov The block device minor number. (December 2013, since 3.14.) 71dd82fff1SIlya Dryomov 72dfc5606dSYehuda Sadehname 73dfc5606dSYehuda Sadeh 74dfc5606dSYehuda Sadeh The name of the rbd image. 75dfc5606dSYehuda Sadeh 76589d30e0SAlex Elderimage_id 77589d30e0SAlex Elder 78589d30e0SAlex Elder The unique id for the rbd image. (For rbd image format 1 79589d30e0SAlex Elder this is empty.) 80589d30e0SAlex Elder 81dfc5606dSYehuda Sadehpool 82dfc5606dSYehuda Sadeh 839bb2f334SAlex Elder The name of the storage pool where this rbd image resides. 849bb2f334SAlex Elder An rbd image name is unique within its pool. 859bb2f334SAlex Elder 869bb2f334SAlex Elderpool_id 879bb2f334SAlex Elder 889bb2f334SAlex Elder The unique identifier for the rbd image's pool. This is 899bb2f334SAlex Elder a permanent attribute of the pool. A pool's id will never 909bb2f334SAlex Elder change. 91dfc5606dSYehuda Sadeh 92dfc5606dSYehuda Sadehsize 93dfc5606dSYehuda Sadeh 94dfc5606dSYehuda Sadeh The size (in bytes) of the mapped block device. 95dfc5606dSYehuda Sadeh 96dfc5606dSYehuda Sadehrefresh 97dfc5606dSYehuda Sadeh 98dfc5606dSYehuda Sadeh Writing to this file will reread the image header data and set 99dfc5606dSYehuda Sadeh all relevant datastructures accordingly. 100dfc5606dSYehuda Sadeh 101dfc5606dSYehuda Sadehcurrent_snap 102dfc5606dSYehuda Sadeh 103dfc5606dSYehuda Sadeh The current snapshot for which the device is mapped. 104dfc5606dSYehuda Sadeh 10586b00e0dSAlex Elderparent 10686b00e0dSAlex Elder 107ff96128fSIlya Dryomov Information identifying the chain of parent images in a layered rbd 108ff96128fSIlya Dryomov image. Entries are separated by empty lines. 109