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

[Question] 底层Cassandra迁移之后hugegraph无法启动 #2705

Closed
1 task done
liaobing opened this issue Dec 10, 2024 · 4 comments
Closed
1 task done

[Question] 底层Cassandra迁移之后hugegraph无法启动 #2705

liaobing opened this issue Dec 10, 2024 · 4 comments
Labels
cassandra Cassandra backend inactive question Further information is requested

Comments

@liaobing
Copy link

Problem Type (问题类型)

other exception / error (其他异常报错)

Before submit

  • 我已经确认现有的 IssuesFAQ 中没有相同 / 重复问题 (I have confirmed and searched that there are no similar problems in the historical issue and documents)

Environment (环境信息)

  • Server Version: 0.11.2(Apache Release Version)
  • Cassandra 3.11.9
  • Backend: RocksDB x nodes, HDD or SSD
  • OS: xx CPUs, xx G RAM, Ubuntu 2x.x / CentOS 7.x
  • Data Size: xx vertices, xx edges

Your Question (问题描述)

1.底层存储的Cassandra发生迁移之后,访问的地址不变
2.迁移之后底层的表目前都存在 库名:cassandra01
3.启动hugegraph连着Cassandra无法启动
4.详细报错如下:Dec 10, 2024 6:27:28 AM org.glassfish.grizzly.http.server.NetworkListener shutdownNow
INFO: Stopped listener bound to [0.0.0.0:8080]
2024-12-10 06:27:28 6591 [main] [ERROR] com.baidu.hugegraph.dist.HugeGraphServer [] - HugeRestServer start error:
com.baidu.hugegraph.backend.BackendException: The backend store of 'cassandra01' has not been initialized
at com.baidu.hugegraph.core.GraphManager.checkBackendVersionOrExit(GraphManager.java:217) ~[hugegraph-api-0.11.2.jar:0.58.0.0]
at com.baidu.hugegraph.core.GraphManager.(GraphManager.java:77) ~[hugegraph-api-0.11.2.jar:0.58.0.0]
at com.baidu.hugegraph.server.ApplicationConfig$GraphManagerFactory$1.onEvent(ApplicationConfig.java:108) ~[hugegraph-api-0.11.2.jar:0.58.0.0]
at org.glassfish.jersey.server.internal.monitoring.CompositeApplicationEventListener.onEvent(CompositeApplicationEventListener.java:74) ~[jersey-server-2.25.1.jar:?]
at org.glassfish.jersey.server.internal.monitoring.MonitoringContainerListener.onStartup(MonitoringContainerListener.java:81) ~[jersey-server-2.25.1.jar:?]
at org.glassfish.jersey.server.ApplicationHandler.onStartup(ApplicationHandler.java:1180) ~[jersey-server-2.25.1.jar:?]
at org.glassfish.jersey.grizzly2.httpserver.GrizzlyHttpContainer.start(GrizzlyHttpContainer.java:357) ~[jersey-container-grizzly2-http-2.25.1.jar:?]
at org.glassfish.grizzly.http.server.HttpHandlerChain.start(HttpHandlerChain.java:398) ~[grizzly-http-server-2.4.4.jar:2.4.4]
at org.glassfish.grizzly.http.server.HttpServer.setupHttpHandler(HttpServer.java:293) ~[grizzly-http-server-2.4.4.jar:2.4.4]
at org.glassfish.grizzly.http.server.HttpServer.start(HttpServer.java:269) ~[grizzly-http-server-2.4.4.jar:2.4.4]
at com.baidu.hugegraph.server.RestServer.start(RestServer.java:64) ~[hugegraph-api-0.11.2.jar:0.58.0.0]
at com.baidu.hugegraph.server.RestServer.start(RestServer.java:133) ~[hugegraph-api-0.11.2.jar:0.58.0.0]
at com.baidu.hugegraph.dist.HugeRestServer.start(HugeRestServer.java:58) ~[hugegraph-dist-0.11.2.jar:?]
at com.baidu.hugegraph.dist.HugeGraphServer.(HugeGraphServer.java:55) [hugegraph-dist-0.11.2.jar:?]
at com.baidu.hugegraph.dist.HugeGraphServer.main(HugeGraphServer.java:100) [hugegraph-dist-0.11.2.jar:?]
2024-12-10 06:27:28 6605 [main] [INFO ] org.apache.tinkerpop.gremlin.server.GremlinServer [] - Shutting down OpProcessor[]
2024-12-10 06:27:28 6605 [main] [INFO ] org.apache.tinkerpop.gremlin.server.GremlinServer [] - Shutting down OpProcessor[session]
2024-12-10 06:27:28 6606 [main] [INFO ] org.apache.tinkerpop.gremlin.server.GremlinServer [] - Shutting down OpProcessor[traversal]
2024-12-10 06:27:28 6607 [main] [INFO ] org.apache.tinkerpop.gremlin.server.GremlinServer [] - Shutting down thread pools.
2024-12-10 06:27:28 6608 [gremlin-server-stop] [INFO ] org.apache.tinkerpop.gremlin.server.GremlinServer [] - Executing shutdown LifeCycleHook
2024-12-10 06:27:28 6608 [gremlin-server-stop] [INFO ] org.apache.tinkerpop.gremlin.server.GremlinServer [] - Executed once at shutdown of Gremlin Server.
.2024-12-10 06:27:30 8810 [gremlin-server-stop] [INFO ] com.baidu.hugegraph.HugeGraph [] - Close graph standardhugegraph[cassandra01]
2024-12-10 06:27:30 8832 [gremlin-server-stop] [WARN ] org.apache.tinkerpop.gremlin.server.GremlinServer [] - Exception while closing Graph instance [hugegraph]
java.lang.IllegalStateException: Ensure tx closed in all threads when closing graph 'cassandra01'
at com.google.common.base.Preconditions.checkState(Preconditions.java:531) ~[guava-25.1-jre.jar:?]
at com.baidu.hugegraph.util.E.checkState(E.java:68) ~[hugegraph-common-1.8.1.jar:1.8.1.0]
at com.baidu.hugegraph.StandardHugeGraph.close(StandardHugeGraph.java:816) ~[hugegraph-core-0.11.2.jar:0.11.2.0]
at org.apache.tinkerpop.gremlin.server.GremlinServer.lambda$null$7(GremlinServer.java:298) ~[gremlin-server-3.4.3.jar:3.4.3]
at java.util.concurrent.ConcurrentHashMap$KeySetView.forEach(ConcurrentHashMap.java:4649) ~[?:1.8.0_292]
at org.apache.tinkerpop.gremlin.server.GremlinServer.lambda$stop$8(GremlinServer.java:295) ~[gremlin-server-3.4.3.jar:3.4.3]
at java.lang.Thread.run(Thread.java:748) [?:1.8.0_292]
2024-12-10 06:27:30 8832 [gremlin-server-stop] [INFO ] org.apache.tinkerpop.gremlin.server.GremlinServer [] - Closed Graph instance [hugegraph]
2024-12-10 06:27:30 8832 [gremlin-server-stop] [INFO ] org.apache.tinkerpop.gremlin.server.GremlinServer [] - Gremlin Server - shutdown complete
Exception in thread "main" com.baidu.hugegraph.backend.BackendException: The backend store of 'cassandra01' has not been initialized
at com.baidu.hugegraph.core.GraphManager.checkBackendVersionOrExit(GraphManager.java:217)
at com.baidu.hugegraph.core.GraphManager.(GraphManager.java:77)
at com.baidu.hugegraph.server.ApplicationConfig$GraphManagerFactory$1.onEvent(ApplicationConfig.java:108)
at org.glassfish.jersey.server.internal.monitoring.CompositeApplicationEventListener.onEvent(CompositeApplicationEventListener.java:74)
at org.glassfish.jersey.server.internal.monitoring.MonitoringContainerListener.onStartup(MonitoringContainerListener.java:81)
at org.glassfish.jersey.server.ApplicationHandler.onStartup(ApplicationHandler.java:1180)
at org.glassfish.jersey.grizzly2.httpserver.GrizzlyHttpContainer.start(GrizzlyHttpContainer.java:357)
at org.glassfish.grizzly.http.server.HttpHandlerChain.start(HttpHandlerChain.java:398)
at org.glassfish.grizzly.http.server.HttpServer.setupHttpHandler(HttpServer.java:293)
at org.glassfish.grizzly.http.server.HttpServer.start(HttpServer.java:269)
at com.baidu.hugegraph.server.RestServer.start(RestServer.java:64)
at com.baidu.hugegraph.server.RestServer.start(RestServer.java:133)
at com.baidu.hugegraph.dist.HugeRestServer.start(HugeRestServer.java:58)
at com.baidu.hugegraph.dist.HugeGraphServer.(HugeGraphServer.java:55)
at com.baidu.hugegraph.dist.HugeGraphServer.main(HugeGraphServer.java:100)
The operation timed out when attempting to connect to http://0.0.0.0:8080/graphs

Vertex/Edge example (问题点 / 边数据举例)

No response

Schema [VertexLabel, EdgeLabel, IndexLabel] (元数据结构)

No response

@dosubot dosubot bot added cassandra Cassandra backend question Further information is requested labels Dec 10, 2024
Copy link

dosubot bot commented Dec 10, 2024

@liaobing 你好!我是Dosu。我是一个可以帮助你解决 bug、回答问题,并成为贡献者的机器人。我会在这里帮助你,等待人类维护者的到来。

The error you're encountering, where HugeGraph is unable to start after migrating the underlying Cassandra, is likely due to the backend store 'cassandra01' not being initialized. This is a common issue when the database is not properly initialized after migration.

To resolve this, you need to initialize the backend store using the init-store.sh script. Here are the steps you should follow:

  1. Navigate to the HugeGraph directory:

    cd *hugegraph-${version}
  2. Run the initialization script:

    bin/init-store.sh

This script will set up the necessary backend store for HugeGraph to connect to Cassandra. Additionally, ensure that your hugegraph.properties file is correctly configured with the appropriate Cassandra settings, such as cassandra.host and cassandra.port, to match your new Cassandra setup [1].

If you need further details on configuring the hugegraph.properties file, you can refer to the specific settings required for connecting to a Cassandra backend [2].

To continue talking to Dosu, mention @dosu.


Help Dosu learn! Give it feedback: Great Response | Irrelevant Answer | Incorrect Sources | Too Verbose | Hallucination | Other

@imbajin
Copy link
Member

imbajin commented Dec 10, 2024

@liaobing @dosu

Community support in legacy version < 1.0 (non-apache version) has been discontinued.

Please consider using toolchain's tools tool to export data and reload it into the latest version 1.5.0 (which is a data structure stable version)

@imbajin imbajin closed this as completed Dec 10, 2024

This comment was marked as off-topic.

Copy link

Due to the lack of activity, the current issue is marked as stale and will be closed after 20 days, any update will remove the stale label

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
cassandra Cassandra backend inactive question Further information is requested
Projects
None yet
Development

No branches or pull requests

2 participants