有些时候我们需要在服务器里设置一个脚本,让他一开机就自己启动.方法如下: cd /etc/init.dvi youshell.sh #将youshell.sh修改为你自己的脚本名编写自己的脚本后保存退出.在编写脚本的时候,请先加入以下注释 #add for chkconfig#chkconfig: 2345 70 30#description: the description of the shell #关于脚本的简短描述#processname: servicename
一.root权限编辑/etc/rc.d/rc.local su cd /etc/rc.d/ vi 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 S
webpack配置自动打包重新运行npm run dev出现报错 运行npm run dev出现如下报错 Listening at http://localhost:8080(node:2328) UnhandledPromiseRejectionWarning: Error: spawn cmd ENOENT at Process.ChildProcess._handle.onexit (internal/child_process.js:217:19) at onErrorNT (inter
在Ubuntu安装Tomcat7.0及开机自动运行 1.安装装Tomcat7.0 一般都是绿色版的,下载一个tomcat7.0解开到指定的目录上即可 然后进入tomcat目录的bin文件夹,执行 sudo ./startup.sh即可完成启动 2.开机自动运行tomcat7.0 用Root权限进入,进入并修改/etc/rc.local 如下: #!/bin/sh -e # # rc.local # # This script is executed at the end of each mult