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

Can not list spaces with docker deployment #5026

Open
caton-hpg opened this issue Jun 2, 2022 · 13 comments
Open

Can not list spaces with docker deployment #5026

caton-hpg opened this issue Jun 2, 2022 · 13 comments
Assignees
Labels
affects/master PR/issue: this bug affects master version. type/question Type: question about the product

Comments

@caton-hpg
Copy link
Contributor

./nebula-console-linux-amd64-v3.0.0 -addr=192.168.8.240 -port 9669 -u root -p nebula

(root@nebula) [(none)]> show meta leader
+---------------+---------------------------+
| Meta Leader   | secs from last heart beat |
+---------------+---------------------------+
| "metad0:9559" | 9                         |
+---------------+---------------------------+
Got 1 rows (time spent 443/1492 us)

LOG:

I0602 10:40:13.180270 23678 MetaClient.cpp:204] Send request to meta \"192.168.8.240\":9559
E0602 10:40:13.181121 23678 MetaClient.cpp:211] Send request to meta\"192.168.8.240\":9559 failed
E0602 10:40:13.181367 23613 MetaClient.cpp:82] List space failed
E0602 10:40:13.181386 23613 MetaClient.cpp:33] load data failed
E0602 10:40:13.181433 23613 MetaClient.cpp:42] Get space id for 美职篮球员 failed
@Sophie-Xie Sophie-Xie added the type/bug Type: something is unexpected label Nov 30, 2022
@HarrisChu HarrisChu added affects/none PR/issue: this bug affects none version. severity/none Severity of bug labels Dec 1, 2022
@jinyingsunny jinyingsunny added severity/minor Severity of bug affects/master PR/issue: this bug affects master version. and removed severity/none Severity of bug affects/none PR/issue: this bug affects none version. labels Dec 7, 2022
@jinyingsunny
Copy link

nebula-cpp 3.0

@Shylock-Hg
Copy link
Contributor

Is this issue of nebula-cpp?

@caton-hpg
Copy link
Contributor Author

It's been a while.
I remembered, it's a docker environment. Its meta address is meta0, so the meta API cannot be called.
Maybe it's caused by a docker environment, not a nebula-cpp issue.

@Shylock-Hg
Copy link
Contributor

It's been a while. I remembered, it's a docker environment. Its meta address is meta0, so the meta API cannot be called. Maybe it's caused by a docker environment, not a nebula-cpp issue.

Move this issue to its own repo.

@caton-hpg caton-hpg transferred this issue from vesoft-inc/nebula-cpp Dec 9, 2022
@Sophie-Xie Sophie-Xie added this to the v3.4.0 milestone Dec 9, 2022
@Shylock-Hg
Copy link
Contributor

I think it's maybe a network problem. Try to ping meta host in graph host.

@Sophie-Xie Sophie-Xie added the need info Solution: need more information (ex. can't reproduce) label Dec 12, 2022
@caton-hpg
Copy link
Contributor Author

But I used NebulaGraph in NebulaAnalytics. NebulaAnalytics is not in graph host.

@Sophie-Xie Sophie-Xie removed the need info Solution: need more information (ex. can't reproduce) label Dec 27, 2022
@caton-hpg
Copy link
Contributor Author

I reproduced this problem on version 3.3.0.

  1. First, NebulaAnalytics will execute show meta leader and get meta address.
+---------------+---------------------------+
| Meta Leader     | secs from last heart beat    |
+---------------+---------------------------+
| "metad1:9559" | 2                                            |
+---------------+---------------------------+
  1. Then, Get nebula partitions through meta address.

The metad1 is not real host name. So, Cannot get nebula partitions through "metad1:9559"

@Shylock-Hg
Copy link
Contributor

I reproduced this problem on version 3.3.0.

  1. First, NebulaAnalytics will execute show meta leader and get meta address.
+---------------+---------------------------+
| Meta Leader     | secs from last heart beat    |
+---------------+---------------------------+
| "metad1:9559" | 2                                            |
+---------------+---------------------------+
  1. Then, Get nebula partitions through meta address.

The metad1 is not real host name. So, Cannot get nebula partitions through "metad1:9559"

As I known, docker compose will set host name to metad1

@Shylock-Hg
Copy link
Contributor

I reproduced this problem on version 3.3.0.

  1. First, NebulaAnalytics will execute show meta leader and get meta address.
+---------------+---------------------------+
| Meta Leader     | secs from last heart beat    |
+---------------+---------------------------+
| "metad1:9559" | 2                                            |
+---------------+---------------------------+
  1. Then, Get nebula partitions through meta address.

The metad1 is not real host name. So, Cannot get nebula partitions through "metad1:9559"

Try to ping metad1.

@Shylock-Hg
Copy link
Contributor

I can't reproduce with docker-compose cluster:

➜  nebula-console git:(master) ✗ ./nebula-console -u root -p nebula --address 127.0.0.1 --port 9661

Welcome to Nebula Graph!

(root@nebula) [(none)]> show spaces
+------+
| Name |
+------+
+------+
Empty set (time spent 2085/3857 us)

Wed, 04 Jan 2023 11:50:36 CST

(root@nebula) [(none)]>

Please verify your hostname settings.

@wey-gu
Copy link
Contributor

wey-gu commented Jan 4, 2023

I guess @caton-hpg meant he cannot use metaclient(cpp) to list spaces from the analytics process, where, the analytics process is sitting outside of the docker-compose network, thus it cannot resolve the metad0, metad1, metad2 hostname.

@wey-gu
Copy link
Contributor

wey-gu commented Jan 4, 2023

I guess @caton-hpg meant he cannot use metaclient(cpp) to list spaces from the analytics process, where, the analytics process is sitting outside of the docker-compose network, thus it cannot resolve the metad0, metad1, metad2 hostname.

If my guess is true, this is exactly the same issue we have when it comes to spark utils + containerized deployment of NebulaGraph.

https://github.com/vesoft-inc/nebula-cloud-platform/issues/141

cc @MuYiYong @HarrisChu @MegaByte875 @nianiaJR

And it's actually related to how we discover/identify service instances(with their configured my_ip+port), when meta/storage deamon need to be accessed by meta/storage clients outside of the cluster, the internal-only address will have issues, we need to revisit this(introduce a mapping mechanism? or introduce client side configurable meta-list/storage-list, which is against the cloud pattern though) or hack(as I provided in above issues: k8s, docker-compose or k8s+apigateway), or enable storage datascan via/proxied-from graphD

@Shylock-Hg
Copy link
Contributor

Shylock-Hg commented Jan 4, 2023

Yes, deploy nebula by nebula-docker-compose, meta won't expose its port to host. So it can't be accessed outside docker network.

@Shylock-Hg Shylock-Hg reopened this Jan 4, 2023
@Shylock-Hg Shylock-Hg removed type/bug Type: something is unexpected severity/minor Severity of bug labels Jan 4, 2023
@Shylock-Hg Shylock-Hg added the type/question Type: question about the product label Jan 4, 2023
@Sophie-Xie Sophie-Xie removed this from the v3.4.0 milestone Jan 29, 2023
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
affects/master PR/issue: this bug affects master version. type/question Type: question about the product
Projects
None yet
Development

No branches or pull requests

6 participants