Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Connect to docker/ceph #15

Closed
wcchh opened this issue Mar 19, 2015 · 4 comments
Closed

Connect to docker/ceph #15

wcchh opened this issue Mar 19, 2015 · 4 comments

Comments

@wcchh
Copy link

wcchh commented Mar 19, 2015

Hi, I got a docker/ceph cluster and it's "ceph.conf" is strange as below, and seems I can not connect to it through node-rados:

fsid = f9be0dfe-f839-4ebd-9c1b-ccabf96a1bef
mon initial members = mon_0
mon host = 192.168.23.130
auth cluster required = cephx
auth service required = cephx
auth client required = cephx

Any suggestions?

@siboulet
Copy link
Contributor

That ceph.conf configuration look pretty simple. How are you connecting (code) and what error are you getting? Did you try the ceph command line tool, are you having problems with these too?

@wcchh
Copy link
Author

wcchh commented Mar 20, 2015

  1. How ~ connecting:
    The cluster (docker/ceph) is built on 192.168.23.130, and my node-rados is running on another machine. (My node-rados can connect to other normal way built ceph cluster on other IP successfully with their "ceph.conf" file)
    I use the connecting method of sample code :
    var err = cluster.connect();
    And only got the return code (err) with value 2.
  2. What error I got is error code : 2
  3. Ceph command line tool : I don't know how to connect ceph cluster remotely in my case. I can do this (ceph command line tool) in that target 192.168.23.130, and "chep -s" show its health is ok. I can add pool and put object correctlly.

The IP "192.168.23.130" is public for my intranet, and using docker run with "--net=host" then bind it to ceph mon, so I can ping to it and there's no port relative issue.

@ksperis
Copy link
Owner

ksperis commented Mar 20, 2015

Hi,
The error code 2 should be a "no such file".
Could you verify that you have the rights to read the file /etc/ceph/ceph.client.admin.keyring ?

@wcchh
Copy link
Author

wcchh commented Nov 11, 2016

It works! Thank you very mush!
So we need two files to build the connection: "ceph.conf" and "ceph.client.admin.keyring".

@wcchh wcchh closed this as completed Nov 11, 2016
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

No branches or pull requests

3 participants