It took me a while to figure out the callout script since it wasn't documented anywhere easy. This is what I wrote down, it could be helpful to you or others:
Add the hook script to the ceph.conf file of each OSD
osd crush location hook = /path/to/script
Install the script at the defined location that accepts the following arguments (where the cluster name is typically 'ceph', the id is the daemon identifier (the OSD number), and the daemon type is typically 'osd')
$ ceph-crush-location --cluster CLUSTER --id ID --type TYPE
The script needs to output on a single line the key/value pairs of the location such as
host=osdhost rack=rack5 row=row8 section=sec2 datacenter=provo region=na-west root=default
On Wed, Dec 31, 2014 at 5:26 AM, Lindsay Mathieson <lindsay.mathieson@xxxxxxxxx> wrote:
On Wed, 31 Dec 2014 11:09:35 AM you wrote:
> I believe that the upstart scripts will do this by default, they call out to
> a bash script (I can't remember precisely what that is off the top of my
> head) which then returns the crush rule, which will default to host=X osd=X
> unless it's overridden somewhere (ceph.conf).
>
> If memory serves there's the ability to provide your own script to call out
> to in order to provide the crush rule.
Good to know, thanks.
--
Lindsay
_______________________________________________
ceph-users mailing list
ceph-users@xxxxxxxxxxxxxx
http://lists.ceph.com/listinfo.cgi/ceph-users-ceph.com
_______________________________________________ ceph-users mailing list ceph-users@xxxxxxxxxxxxxx http://lists.ceph.com/listinfo.cgi/ceph-users-ceph.com