Last active
January 25, 2019 19:12
-
-
Save chanlettuce/d9bedcbf42726caf090506b2fa8889e4 to your computer and use it in GitHub Desktop.
SoftEther
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
# userでログイン | |
[user@localhost ~]$ su - | |
[root@localhost ~]# yum - y update | |
[root@localhost ~]# yum groupinstall "Development tools" | |
[root@localhost ~]# yum -y install wget | |
# SoftEtherのダウンロード | |
[root@localhost ~]# wget https://github.com/SoftEtherVPN/SoftEtherVPN_Stable/releases/download/v4.28 -9669-beta/softether-vpnserver-v4.28-9669-beta-2018.09.11-linux-x64-64bit.tar.gz | |
[root@localhost ~]# tar xzvf softether-vpnserver-v4.28-9669-beta-2018.09.11-linux-x64-64bit.tar.gz | |
# SoftEtherビルド | |
[root@localhost ~]# cd vpnserver/ | |
[root@localhost vpnserver]# make | |
Do you want to read the License Agreement for this software ? | |
1. Yes | |
2. No | |
Please choose one of above number: | |
1 # ←入力 | |
Did you read and understand the License Agreement ? | |
(If you couldn't read above text, Please read 'ReadMeFirst_License.txt' | |
file with any text editor.) | |
1. Yes | |
2. No | |
Please choose one of above number: | |
1 # ←入力 | |
Did you agree the License Agreement ? | |
1. Agree | |
2. Do Not Agree | |
Please choose one of above number: | |
1 # ←入力 | |
[root@localhost vpnserver]# cd .. | |
# SoftEther設置 | |
[root@localhost ~]# mv vpnserver /usr/local | |
[root@localhost ~]# cd /usr/local/vpnserver/ | |
[root@localhost vpnserver]# chmod 600 * | |
[root@localhost vpnserver]# chmod 700 vpncmd | |
[root@localhost vpnserver]# chmod 700 vpnserver | |
[root@localhost vpnserver]# cat > /etc/init.d/vpnserver | |
#!/bin/sh | |
# chkconfig: 2345 99 01 | |
# description: SoftEther VPN Server | |
DAEMON=/usr/local/vpnserver/vpnserver | |
LOCK=/var/lock/subsys/vpnserver | |
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 | |
# ここでCtrl+Dを入力 | |
[root@localhost vpnserver]# chmod 755 /etc/init.d/vpnserver | |
[root@localhost vpnserver]# /sbin/chkconfig --add vpnserver | |
# SoftEther起動 | |
[root@localhost vpnserver]# /etc/init.d/vpnserver start | |
# ファイアウォール設定 | |
[root@localhost vpnserver]# firewall-cmd --add-port=443/tcp --permanent # SoftEther本体のポート | |
[root@localhost vpnserver]# firewall-cmd --add-port=500/udp --permanent # L2TP/IPsecを使う場合(任意) | |
[root@localhost vpnserver]# firewall-cmd --add-port=4500/udp --permanent # L2TP/IPsecを使う場合(任意) | |
[root@localhost vpnserver]# firewall-cmd --add-port=1194/tcp --permanent # OpenVPNを使う場合(任意) | |
[root@localhost vpnserver]# firewall-cmd --reload # ファイアウォールのリロード |
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment