You are viewing a plain text version of this content. The canonical link for it is here.
Posted to dev@hugegraph.apache.org by GitBox <gi...@apache.org> on 2022/08/30 03:25:35 UTC
[GitHub] [incubator-hugegraph-toolchain] dnsisme opened a new issue, #329: Failed to start hugeGraphServer,requires at least 128m free memory
dnsisme opened a new issue, #329:
URL: https://github.com/apache/incubator-hugegraph-toolchain/issues/329
### Bug Type (问题类型)
server status (启动/运行异常)
### Before submit
- [X] 我已经确认现有的 [Issues](https://github.com/hugegraph/hugegraph/issues) 与 [FAQ](https://hugegraph.github.io/hugegraph-doc/guides/faq.html) 中没有相同 / 重复问题
### Environment (环境信息)
- Server Version: hugegraph-tools-1.16.0
- Backend: RocksDB x nodes, HDD
- OS: 8 CPUs, 31 G, CentOS Linux release 7.6.1810
- Data Size: xx vertices, xx edges <!-- (like 1000W 点, 9000W 边) -->
### Expected & Actual behavior (期望与实际表现)
```
During my installation, I failed to start the service. The download address of the installation package is:
wget https://github.com/hugegraph/hugegraph-tools/releases/download/v1.6.0/hugegraph-tools-1.6.0.tar.gz --no-check-certificate
setup scripts:
1)wget https://github.com/hugegraph/hugegraph-tools/releases/download/v1.6.0/hugegraph-tools-1.6.0.tar.gz --no-check-certificate
2)tar zxvf hugegraph-tools-1.6.0.tar.gz
3)cd hugegraph-tools-1.6.0
4)bin/hugegraph deploy -v 0.6 -p services
Start command
bin/hugegraph deploy -v 0.6 -p services
Startup error
Warning: please set JAVA_HOME variable, otherwise some libraries related to https may be missing
Initing HugeGraph Store...
2022-08-29 11:21:48 671 [main] [INFO ] com.baidu.hugegraph.cmd.InitStore [] - Init graph with config file: conf/hugegraph.properties
2022-08-29 11:21:48 778 [main] [INFO ] com.baidu.hugegraph.HugeGraph [] - Opening backend store 'rocksdb' for graph 'hugegraph'
2022-08-29 11:21:48 815 [main] [INFO ] com.baidu.hugegraph.backend.store.rocksdb.RocksDBStore [] - Opening RocksDB with data path: rocksdb-data/schema
Exception in thread "main" java.lang.UnsatisfiedLinkError: /tmp/librocksdbjni5488875565228343916.so: /tmp/librocksdbjni5488875565228343916.so: cannot open shared object file: No such file or directory (Possible cause: can't load AMD 64-bit .so on a AARCH64-bit platform)
at java.lang.ClassLoader$NativeLibrary.load(Native Method)
at java.lang.ClassLoader.loadLibrary0(ClassLoader.java:1934)
at java.lang.ClassLoader.loadLibrary(ClassLoader.java:1817)
at java.lang.Runtime.load0(Runtime.java:809)
at java.lang.System.load(System.java:1086)
at org.rocksdb.NativeLibraryLoader.loadLibraryFromJar(NativeLibraryLoader.java:78)
at org.rocksdb.NativeLibraryLoader.loadLibrary(NativeLibraryLoader.java:56)
at org.rocksdb.RocksDB.loadLibrary(RocksDB.java:64)
at org.rocksdb.RocksDB.<clinit>(RocksDB.java:35)
at org.rocksdb.Options.<clinit>(Options.java:25)
at com.baidu.hugegraph.backend.store.rocksdb.RocksDBStdSessions.mergeOldCFs(RocksDBStdSessions.java:195)
at com.baidu.hugegraph.backend.store.rocksdb.RocksDBStdSessions.<init>(RocksDBStdSessions.java:87)
at com.baidu.hugegraph.backend.store.rocksdb.RocksDBStore.newSessions(RocksDBStore.java:212)
at com.baidu.hugegraph.backend.store.rocksdb.RocksDBStore.open(RocksDBStore.java:159)
at com.baidu.hugegraph.backend.store.rocksdb.RocksDBStore.open(RocksDBStore.java:140)
at com.baidu.hugegraph.backend.tx.AbstractTransaction.<init>(AbstractTransaction.java:72)
at com.baidu.hugegraph.backend.tx.IndexableTransaction.<init>(IndexableTransaction.java:30)
at com.baidu.hugegraph.backend.tx.SchemaTransaction.<init>(SchemaTransaction.java:54)
at com.baidu.hugegraph.backend.cache.CachedSchemaTransaction.<init>(CachedSchemaTransaction.java:49)
at com.baidu.hugegraph.HugeGraph.openSchemaTransaction(HugeGraph.java:199)
at com.baidu.hugegraph.HugeGraph.access$300(HugeGraph.java:74)
at com.baidu.hugegraph.HugeGraph$TinkerpopTransaction.schemaTransaction(HugeGraph.java:612)
at com.baidu.hugegraph.HugeGraph$TinkerpopTransaction.doOpen(HugeGraph.java:530)
at org.apache.tinkerpop.gremlin.structure.util.AbstractTransaction.open(AbstractTransaction.java:95)
at org.apache.tinkerpop.gremlin.structure.Transaction$READ_WRITE_BEHAVIOR$1.accept(Transaction.java:208)
at org.apache.tinkerpop.gremlin.structure.Transaction$READ_WRITE_BEHAVIOR$1.accept(Transaction.java:205)
at org.apache.tinkerpop.gremlin.structure.util.AbstractThreadLocalTransaction.doReadWrite(AbstractThreadLocalTransaction.java:92)
at org.apache.tinkerpop.gremlin.structure.util.AbstractTransaction.readWrite(AbstractTransaction.java:146)
at com.baidu.hugegraph.HugeGraph.initBackend(HugeGraph.java:178)
at com.baidu.hugegraph.cmd.InitStore.initGraph(InitStore.java:100)
at com.baidu.hugegraph.cmd.InitStore.main(InitStore.java:86)
Starting HugeGraphServer...
Connecting to HugeGraphServer (http://:8080/graphs)................The operation timed out when attempting to connect to http://:8080/graphs
See /data/work/hugegraph/hugegraph-tools-1.6.0/services/hugegraph-0.6.1/logs/hugegraph-server.log for HugeGraphServer log output.
Failed to start HugeGraphServer, please check the logs under '/data/work/hugegraph/hugegraph-tools-1.6.0/services/hugegraph-0.6.1/logs' for details
[root@ecs-56b9-0001 hugegraph-tools-1.6.0]# cat /data/work/hugegraph/hugegraph-tools-1.6.0/services/hugegraph-0.6.1/logs/hugegraph-server.log
Failed to start HugeGraphServer, requires at least 512m free memory
Failed to start HugeGraphServer, requires at least 256m free memory
Failed to start HugeGraphServer, requires at least 256m free memory
Failed to start HugeGraphServer, requires at least 128m free memory
After changing the MEM value according to the online tutorial, the same error will be reported
MIN_MEM=$((1*512))
MIN_MEM=$((1*256))
MIN_MEM=$((1*128))
hugegraph-server.sh context:
[root@ecs-56b9-0001 hugegraph-tools-1.6.0]# cat /data/work/hugegraph/hugegraph-tools-1.6.0/services/hugegraph-0.6.1/bin/hugegraph-server.sh
#!/bin/bash
abs_path() {
SOURCE="${BASH_SOURCE[0]}"
while [ -h "$SOURCE" ]; do
DIR="$( cd -P "$( dirname "$SOURCE" )" && pwd )"
SOURCE="$(readlink "$SOURCE")"
[[ $SOURCE != /* ]] && SOURCE="$DIR/$SOURCE"
done
echo "$( cd -P "$( dirname "$SOURCE" )" && pwd )"
}
BIN=`abs_path`
TOP="$(cd $BIN/../ && pwd)"
. $BIN/util.sh
# The maximum and minium heap memory that service can use
MAX_MEM=$[32*1024]
MIN_MEM=$((1*256))
EXPECT_JDK_VERSION=1.8
# ${BASH_SOURCE[0]} is the path to this file
SOURCE="${BASH_SOURCE[0]}"
# Set $BIN to the absolute, symlinkless path to $SOURCE's parent
while [ -h "$SOURCE" ]; do
BIN="$( cd -P "$( dirname "$SOURCE" )" && pwd )"
SOURCE="$(readlink "$SOURCE")"
[[ $SOURCE != /* ]] && SOURCE="$BIN/$SOURCE"
done
BIN="$( cd -P "$( dirname "$SOURCE" )" && pwd )"
# Set $CFG to $BIN/../conf/
cd -P $BIN/../conf
CFG=$(pwd)
# Set $LIB to $BIN/../lib
cd -P $BIN/../lib
LIB=$(pwd)
# Set $LIB to $BIN/../ext
cd -P $BIN/../ext
EXT=$(pwd)
# Initialize classpath to $CFG
CP="$CFG"
# Add the slf4j-log4j12 binding
CP="$CP":$(find -L $LIB -name 'slf4j-log4j12*.jar' | sort | tr '\n' ':')
# Add the jars in $BIN/../lib that start with "hugegraph"
CP="$CP":$(find -L $LIB -name 'hugegraph*.jar' | sort | tr '\n' ':')
# Add the remaining jars in $BIN/../lib.
CP="$CP":$(find -L $LIB -name '*.jar' \
\! -name 'hugegraph*' \
\! -name 'slf4j-log4j12*.jar' | sort | tr '\n' ':')
# Add the jars in $BIN/../ext (at any subdirectory depth)
CP="$CP":$(find -L $EXT -name '*.jar' | sort | tr '\n' ':')
# (Cygwin only) Use ; classpath separator and reformat paths for Windows ("C:\foo")
[[ $(uname) = CYGWIN* ]] && CP="$(cygpath -p -w "$CP")"
export CLASSPATH="${CLASSPATH:-}:$CP"
# Change to $BIN's parent
cd $BIN/..
export HUGEGRAPH_LOGDIR="$BIN/../logs"
if [ ! -d $HUGEGRAPH_LOGDIR ]; then
mkdir $HUGEGRAPH_LOGDIR
fi
# Find Java
if [ "$JAVA_HOME" = "" ] ; then
JAVA="java -server"
else
JAVA="$JAVA_HOME/bin/java -server"
fi
JAVA_VERSION=`$JAVA -version 2>&1 | awk 'NR==1{gsub(/"/,""); print $3}' \
| awk -F'_' '{print $1}'`
if [[ $? -ne 0 || $JAVA_VERSION < $EXPECT_JDK_VERSION ]]; then
echo "Please make sure that the JDK is installed and the version >= $EXPECT_JDK_VERSION" \
>> $HUGEGRAPH_LOGDIR/hugegraph-server.log
exit 1
fi
# Set Java options
if [ "$JAVA_OPTIONS" = "" ] ; then
XMX=`calc_xmx $MIN_MEM $MAX_MEM`
if [ $? -ne 0 ]; then
echo "Failed to start HugeGraphServer, requires at least ${MIN_MEM}m free memory" \
>> $HUGEGRAPH_LOGDIR/hugegraph-server.log
exit 1
fi
JAVA_OPTIONS="-Xms256m -Xmx${XMX}m -javaagent:$LIB/jamm-0.3.0.jar"
fi
# Execute the application and return its exit code
set -x
ARGS="$@"
if [ $# = 0 ] ; then
ARGS="conf/gremlin-server.yaml conf/rest-server.properties"
fi
exec $JAVA -Dname="HugeGraphServer" -Dhugegraph.logdir="HUGEGRAPH_LOGDIR" \
-Dlog4j.configurationFile=conf/graph-server-log4j.xml \
$JAVA_OPTIONS -cp $CP:$CLASSPATH com.baidu.hugegraph.dist.HugeGraphServer $ARGS
```
### Vertex/Edge example (问题点 / 边数据举例)
_No response_
### Schema [VertexLabel, EdgeLabel, IndexLabel] (元数据结构)
_No response_
--
This is an automated message from the Apache Git Service.
To respond to the message, please log on to GitHub and use the
URL above to go to the specific comment.
To unsubscribe, e-mail: dev-unsubscribe@hugegraph.apache.org.apache.org
For queries about this service, please contact Infrastructure at:
users@infra.apache.org
[GitHub] [incubator-hugegraph-toolchain] dnsisme commented on issue #329: Failed to start hugeGraphServer,requires at least 128m free memory
Posted by GitBox <gi...@apache.org>.
dnsisme commented on issue #329:
URL: https://github.com/apache/incubator-hugegraph-toolchain/issues/329#issuecomment-1232618214
@imbajin
after init hugegraph, start hugegraph succeed!thx
--
This is an automated message from the Apache Git Service.
To respond to the message, please log on to GitHub and use the
URL above to go to the specific comment.
To unsubscribe, e-mail: dev-unsubscribe@hugegraph.apache.org
For queries about this service, please contact Infrastructure at:
users@infra.apache.org
[GitHub] [incubator-hugegraph-toolchain] dnsisme commented on issue #329: Failed to start hugeGraphServer,requires at least 128m free memory
Posted by GitBox <gi...@apache.org>.
dnsisme commented on issue #329:
URL: https://github.com/apache/incubator-hugegraph-toolchain/issues/329#issuecomment-1231601296
@imbajin
Use the Source code compilation method to install the latest version of hugegraph-server. Failed to start the server.
![image](https://user-images.githubusercontent.com/88881577/187436269-4f649e7d-522c-4113-9f36-e26d2826ffe8.png)
error log
```
Starting HugeGraphServer...
Connecting to HugeGraphServer (http://ecs-56b9-0001:8080/graphs)....Starting HugeGraphServer failed
See /data/work/hugegraph-origin/hugegraph/hugegraph-0.13.0/logs/hugegraph-server.log for HugeGraphServer log output.
[root@ecs-56b9-0001 hugegraph-0.13.0]# cat /data/work/hugegraph-origin/hugegraph/hugegraph-0.13.0/logs/hugegraph-server.log
2022-08-30 20:26:51 [main] [INFO] c.b.h.s.RestServer - RestServer starting...
2022-08-30 20:26:53 [main] [INFO] c.b.h.u.ConfigUtil - Scanning option 'graphs' directory './conf/graphs'
2022-08-30 20:26:53 [main] [INFO] c.b.h.b.c.Cache - Init RamCache for 'users-hugegraph' with capacity 10240
2022-08-30 20:26:53 [main] [INFO] c.b.h.b.c.Cache - Init RamCache for 'users_pwd-hugegraph' with capacity 10240
2022-08-30 20:26:53 [main] [INFO] c.b.h.b.c.Cache - Init RamCache for 'token-hugegraph' with capacity 10240
2022-08-30 20:26:53 [main] [INFO] c.b.h.s.RestServer - Graph 'hugegraph' was successfully configured via './conf/graphs/hugegraph.properties'
2022-08-30 20:26:53 [main] [INFO] c.b.h.r.RpcServer - RpcServer config is empty, skip starting RpcServer
2022-08-30 20:26:54 [db-open-1] [INFO] c.b.h.b.s.r.RocksDBStore - Opening RocksDB with data path: rocksdb-data/m
2022-08-30 20:26:54 [db-open-1] [INFO] c.b.h.b.s.r.RocksDBStore - Failed to open RocksDB 'rocksdb-data/m' with database 'hugegraph', try to init CF later
2022-08-30 20:26:54 [main] [INFO] c.b.h.b.c.Cache - Init RamCache for 'schema-id-hugegraph' with capacity 10000
2022-08-30 20:26:54 [main] [INFO] c.b.h.b.c.Cache - Init RamCache for 'schema-name-hugegraph' with capacity 10000
2022-08-30 20:26:54 [db-open-1] [INFO] c.b.h.b.s.r.RocksDBStore - Opening RocksDB with data path: rocksdb-data/s
2022-08-30 20:26:55 [db-open-1] [INFO] c.b.h.b.s.r.RocksDBStore - Opening RocksDB with data path: rocksdb-data/g
2022-08-30 20:26:55 [main] [INFO] o.c.o.l.Uns - OHC using JNA OS native malloc/free
2022-08-30 20:26:55 [main] [INFO] c.b.h.b.c.Cache - Init LevelCache for 'vertex-hugegraph' with capacity 10000:10000000
2022-08-30 20:26:55 [main] [INFO] c.b.h.b.c.Cache - Init LevelCache for 'edge-hugegraph' with capacity 1000:1000000
2022-08-30 20:26:55 [main] [INFO] c.b.h.s.RestServer - Check backend version
2022-08-30 20:26:55 [main] [INFO] c.b.h.HugeGraph - Close graph standardhugegraph[hugegraph]
2022-08-30 20:26:55 [main] [INFO] c.b.h.r.RpcServer - RpcServer stop on port 8091
2022-08-30 20:26:55 [SOFA-RPC-ShutdownHook] [WARN] c.a.s.r.c.RpcRuntimeContext - SOFA RPC Framework catch JVM shutdown event, Run shutdown hook now.
2022-08-30 20:26:55 [main] [ERROR] c.b.h.d.HugeGraphServer - HugeRestServer start error:
com.baidu.hugegraph.backend.BackendException: The backend store of 'hugegraph' has not been initialized
at com.baidu.hugegraph.core.GraphManager.checkBackendVersionOrExit(GraphManager.java:416) ~[hugegraph-api-0.13.0.jar:0.69.0.0]
at com.baidu.hugegraph.core.GraphManager.init(GraphManager.java:118) ~[hugegraph-api-0.13.0.jar:0.69.0.0]
at com.baidu.hugegraph.server.ApplicationConfig$GraphManagerFactory$1.onEvent(ApplicationConfig.java:132) ~[hugegraph-api-0.13.0.jar:0.69.0.0]
at org.glassfish.jersey.server.internal.monitoring.CompositeApplicationEventListener.onEvent(CompositeApplicationEventListener.java:49) ~[jersey-server-3.0.3.jar:?]
at org.glassfish.jersey.server.internal.monitoring.MonitoringContainerListener.onStartup(MonitoringContainerListener.java:56) ~[jersey-server-3.0.3.jar:?]
at org.glassfish.jersey.server.ApplicationHandler.onStartup(ApplicationHandler.java:711) ~[jersey-server-3.0.3.jar:?]
at org.glassfish.jersey.grizzly2.httpserver.GrizzlyHttpContainer.start(GrizzlyHttpContainer.java:330) ~[jersey-container-grizzly2-http-3.0.3.jar:?]
at org.glassfish.grizzly.http.server.HttpHandlerChain.start(HttpHandlerChain.java:376) ~[grizzly-http-server-3.0.1.jar:3.0.1]
at org.glassfish.grizzly.http.server.HttpServer.setupHttpHandler(HttpServer.java:268) ~[grizzly-http-server-3.0.1.jar:3.0.1]
at org.glassfish.grizzly.http.server.HttpServer.start(HttpServer.java:245) ~[grizzly-http-server-3.0.1.jar:3.0.1]
at com.baidu.hugegraph.server.RestServer.start(RestServer.java:73) ~[hugegraph-api-0.13.0.jar:0.69.0.0]
at com.baidu.hugegraph.server.RestServer.start(RestServer.java:180) ~[hugegraph-api-0.13.0.jar:0.69.0.0]
at com.baidu.hugegraph.dist.HugeRestServer.start(HugeRestServer.java:34) ~[hugegraph-dist-0.13.0.jar:?]
at com.baidu.hugegraph.dist.HugeGraphServer.<init>(HugeGraphServer.java:62) ~[hugegraph-dist-0.13.0.jar:?]
at com.baidu.hugegraph.dist.HugeGraphServer.main(HugeGraphServer.java:122) ~[hugegraph-dist-0.13.0.jar:?]
2022-08-30 20:26:55 [main] [INFO] c.b.h.HugeGraph - HugeFactory shutdown
2022-08-30 20:26:55 [hugegraph-shutdown] [INFO] c.b.h.HugeGraph - HugeGraph is shutting down
```
Is it related to the env
```CentOS Linux release 7.6.1810 (AltArch)
```
```
Linux ecs-56b9-0001 4.18.0-80.7.2.el7.aarch64 #1 SMP Thu Sep 12 16:13:20 UTC 2019 aarch64 aarch64 aarch64 GNU/Linux
```
--
This is an automated message from the Apache Git Service.
To respond to the message, please log on to GitHub and use the
URL above to go to the specific comment.
To unsubscribe, e-mail: dev-unsubscribe@hugegraph.apache.org
For queries about this service, please contact Infrastructure at:
users@infra.apache.org
[GitHub] [incubator-hugegraph-toolchain] github-actions[bot] commented on issue #329: Failed to start hugeGraphServer,requires at least 128m free memory
Posted by GitBox <gi...@apache.org>.
github-actions[bot] commented on issue #329:
URL: https://github.com/apache/incubator-hugegraph-toolchain/issues/329#issuecomment-1248625050
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
--
This is an automated message from the Apache Git Service.
To respond to the message, please log on to GitHub and use the
URL above to go to the specific comment.
To unsubscribe, e-mail: dev-unsubscribe@hugegraph.apache.org
For queries about this service, please contact Infrastructure at:
users@infra.apache.org
[GitHub] [incubator-hugegraph-toolchain] imbajin commented on issue #329: Failed to start hugeGraphServer,requires at least 128m free memory
Posted by GitBox <gi...@apache.org>.
imbajin commented on issue #329:
URL: https://github.com/apache/incubator-hugegraph-toolchain/issues/329#issuecomment-1232522767
seems u don't init the graph well?
<img width="741" alt="image" src="https://user-images.githubusercontent.com/17706099/187609664-0851694c-0d29-4c1f-b24e-4dfbaeccca9a.png">
and the latest code support multi graph configs while server is running, so the configs will be a little different (refer [here](https://github.com/apache/incubator-hugegraph/issues/1940))
--
This is an automated message from the Apache Git Service.
To respond to the message, please log on to GitHub and use the
URL above to go to the specific comment.
To unsubscribe, e-mail: dev-unsubscribe@hugegraph.apache.org
For queries about this service, please contact Infrastructure at:
users@infra.apache.org
[GitHub] [incubator-hugegraph-toolchain] imbajin commented on issue #329: Failed to start hugeGraphServer,requires at least 128m free memory
Posted by GitBox <gi...@apache.org>.
imbajin commented on issue #329:
URL: https://github.com/apache/incubator-hugegraph-toolchain/issues/329#issuecomment-1231418399
first, don't use tool to install the server, it's outdated and will update in next release, just download the `V0.12` in server's [release page](https://github.com/apache/incubator-hugegraph/releases)
And thanks for report the tool's problem, I'll add it in TODO list
--
This is an automated message from the Apache Git Service.
To respond to the message, please log on to GitHub and use the
URL above to go to the specific comment.
To unsubscribe, e-mail: dev-unsubscribe@hugegraph.apache.org
For queries about this service, please contact Infrastructure at:
users@infra.apache.org
[GitHub] [incubator-hugegraph-toolchain] github-actions[bot] closed issue #329: Failed to start hugeGraphServer,requires at least 128m free memory
Posted by GitBox <gi...@apache.org>.
github-actions[bot] closed issue #329: Failed to start hugeGraphServer,requires at least 128m free memory
URL: https://github.com/apache/incubator-hugegraph-toolchain/issues/329
--
This is an automated message from the Apache Git Service.
To respond to the message, please log on to GitHub and use the
URL above to go to the specific comment.
To unsubscribe, e-mail: dev-unsubscribe@hugegraph.apache.org
For queries about this service, please contact Infrastructure at:
users@infra.apache.org