SVN服务器 Linux 开机自动启动代码
Posted
tags:
篇首语:本文由小常识网(cha138.com)小编为大家整理,主要介绍了SVN服务器 Linux 开机自动启动代码相关的知识,希望对你有一定的参考价值。
~ ll /etc/rc.d/rc.local -rwxr-xr-x 1 root root 810 Oct 9 09:30 /etc/rc.d/rc.local ~ cat /etc/rc.d/rc.local #!/bin/bash # THIS FILE IS ADDED FOR COMPATIBILITY PURPOSES # # It is highly advisable to create own systemd services or udev rules # to run scripts during boot instead of using this file. # # In contrast to previous versions due to parallel execution during boot # this script will NOT be run after all other services. # # Please note that you must run ‘chmod +x /etc/rc.d/rc.local‘ to ensure # that this script will be executed during boot. touch /var/lock/subsys/local #add_S by chunli, for autostart svnserve! while true do sleep 1 ps -ef > /tmp/tmp_svnserve cat /tmp/tmp_svnserve | grep ‘/usr/bin/svnserve -d‘ if [ $? -eq 0 ] then rm -rf /tmp/tmp_svnserve exit else /usr/bin/svnserve -d -r /home/svn/ fi done #add_E by chunli, for autostart svnserve! ~
本文出自 “李春利” 博客,转载请与作者联系!
以上是关于SVN服务器 Linux 开机自动启动代码的主要内容,如果未能解决你的问题,请参考以下文章