ユーザ用ツール

サイト用ツール


utvpn自動起動

/etc/init.d にスクリプトを配置

utvpnserver

#!/bin/sh
# chkconfig: 2345 92 01 
# description: UT-VPN Server
DAEMON=/usr/bin/utvpnserver
LOCK=/var/lock/subsys/utvpnserver
test -x $DAEMON || exit 0
case "$1" in
start)
  $DAEMON start
  touch $LOCK
  ;;
  stop)
    $DAEMON stop
    rm $LOCK
  ;;
  restart)
    $DAEMON stop
    sleep 3
    $DAEMON start
  ;;
  *)
    echo "Usage: $0 {start|stop|restart}"
    exit 1
esac
exit 0

chmod 755 utvpnserver

utvpnclient

#!/bin/sh
# chkconfig: 2345 96 01
# description: UT-VPN Client
DAEMON=/usr/bin/utvpnclient
LOCK=/var/lock/subsys/utvpnclient
test -x $DAEMON || exit 0
case "$1" in
  start)
    $DAEMON start
    touch $LOCK
  ;;
  stop)
    $DAEMON stop
    rm $LOCK
  ;;
  restart)
    $DAEMON stop
    sleep 3
    $DAEMON start
  ;;
  *)
    echo "Usage: $0 {start|stop|restart}"
    exit 1
esac
exit 0

chmod 755 utvpnclient

chkconfigに追加

chkconfig --add utvpnserver
chkconfig --add utvpnclient
utvpn自動起動.txt · 最終更新: 2019/06/30 12:22 by 127.0.0.1