## 常用shell脚本 **1. tomcat监控 自动重启 注意tomcat路径要根据实际情况更改** ```shell #!/bin/sh # 获取tomcat进程ID 注意tomcat路径要根据实际情况更改 TomcatID=$(ps -ef |grep '/root/tomcat/bin'|grep -v 'grep'| awk '{print $2}') # tomcat启动程序 注