how to add an existing garbd server ?

Comments

4 comments

  • Avatar
    Art van Scheppingen

    Hi Levieux,

    At this moment there is no UI component that can import an existing garbd node, however the backend does support this.

    There are two ways to trigger this in the backend and that is by either sending the command to the backend manually or inserting the job into the cmon database.

    Backend command: 
    curl -X POST -H "Content-Type: application/json" -d ' { "token":"xunXe5u5t55dtqWN", "operation": "createJob", "job": {"command": "registernode", "job_data": { "component": "garbd","hostname": "10.10.16.10","cmdline":"/usr/bin/garbd --cfg /etc/garbd.cnf --daemon"} } }' http://localhost:9500/22/job

    I will assume here that your clusterid is 22 and the Garbd host is 10.10.16.10, so you may want to change that to your own clusterid. Also the hostname and token needs to be adjusted to your Garbd host and the token in /etc/cmon.d/cmon_22.cnf

    The insert command: 
    insert into cmon_job(cid,jobspec) values(22, '{"command":"registernode", "job_data": { "component": "garbd","hostname": "10.10.16.10","cmdline":"/usr/bin/garbd --cfg /etc/garbd.cnf --daemon"}}');

    And the same here: you need to change the identifier (22) and ip address for your cluster and Garbd node.

    In both cases a new job will be created in cmon and the Garbd node will be added immediately.

    Best regards,

    Art

  • Avatar
    levieux stephane

    Thanks for your answer,  i try the curl method but it seems the token have to be changed also ?

    "errorString": "Access denied (invalid authentication token)", 

  • Avatar
    levieux stephane

    i uses the SQL method, my garbd appears  now in my cluster control , i had to copy the ssh key also.

    Thanks for your help 

  • Avatar
    Art van Scheppingen

    Hi Levieux,

    Yes you have to change the authentication token as well as they differ per cluster.

    But great to hear you managed to get it working using the SQL method.

    Best regards,

    Art

Please sign in to leave a comment.

Powered by Zendesk