CentOS 配置的开机自启动。

vim /etc/rc.local

#!/bin/sh
#
# This script will be executed *after* all the other init scripts.
# You can put your own initialization stuff in here if you don't
# want to do the full Sys V style init stuff.

touch /var/lock/subsys/local

echo never > /sys/kernel/mm/redhat_transparent_hugepage/enabled
ip route add default via 192.168.1.1 dev eth0
/opt/product/zookeeper/node-03/bin/zkServer.sh start
/opt/product/activemq/node-03/bin/activemq start
redis-server /etc/redis.conf
/opt/product/mongodb/bin/mongod --port 25019 --dbpath /data/db/ &
/opt/product/dubbo-admin-tomcat/bin/startup.sh

 

相关文章:

  • 2022-12-23
  • 2021-07-16
  • 2021-11-04
  • 2022-02-10
  • 2022-12-23
  • 2022-12-23
  • 2022-12-23
  • 2021-09-12
猜你喜欢
  • 2022-12-23
  • 2021-06-19
  • 2021-11-28
  • 2021-12-28
  • 2021-09-03
相关资源
相似解决方案