h2
h2 可以以 4 种模式运行:
基于内存、基于文件、基于服务器、混合模式(内存 + 服务器)
以下提供以服务器启动的脚本
#!/bin/sh
# 声明为当前运行脚本路径,高版本需要添加 -ifNotExists 来创建数据库,否则无法连接
dir=$(dirname "$0")
nohup /usr/mpsp/java/java-se-8u42-ri/bin/java -cp "$dir/h2-2.1.214.jar:$H2DRIVERS:$CLASSPATH" org.h2.tools.Server -baseDir /usr/mpsp/hpay-skywalking/h2/bin -tcpAllowOthers -webAllowOthers -webPort 18081 -webAdminPassword 123 -ifNotExists"$@