#!/bin/bash
. /etc/profile
. ~/.bash_profile
#crontab 每5分钟监控一次
#*/5 * * * * path/neo4j_database_monitor.sh
working_dir=basepath
cd ${working_dir}
lsof -i:7474
if [ $? -ne 0 ] #检测是否存在7474端口
then
./neo4j start
echo "`date` neo4j database is stopped. Now will start it" >> neo4j_monitor.log
fi
neo4j 数据库监控脚本
最新推荐文章于 2024-11-15 04:09:45 发布