LoginSignup
11
13

More than 5 years have passed since last update.

SoftEther VPN Server for Linux

Last updated at Posted at 2014-06-21

はじめに

Debian 7.0 (Wheezy) に SoftEther VPN Server をインストールします。

SoftEther VPN Server のインストール

apt-get コマンドで開発ツールをインストールします。

apt-get update
apt-get install build-essential

公式サイトから SoftEther VPN Server をダウンロードします。

wget http://jp.softether-download.com/.../softether-vpnserver-v4.08-9449-rtm-2014.06.08-linux-x64-64bit.tar.gz

ダウンロードしたファイルを /usr/local/ ディレクトリに展開します。

tar zxvf softether-vpnserver-v4.08-9449-rtm-2014.06.08-linux-x64-64bit.tar.gz -C /usr/local/

展開先のディレクトリに移動して、make コマンドで実行可能ファイルを生成します。

cd /usr/local/vpnserver
make

make コマンドを実行するとライセンスの同意を求められるので、ライセンス条項を読んで、同意します。
ライセンスに同意するとプログラムの生成と動作環境のチェックが行われます。

--------------------------------------------------------------------

SoftEther VPN Server (Ver 4.08, Build 9449, Intel x64 / AMD64) for Linux Install Utility
Copyright (c) SoftEther Project at University of Tsukuba, Japan. All Rights Reserved.

--------------------------------------------------------------------


Do you want to read the License Agreement for this software ?

 1. Yes
 2. No

Please choose one of above number:
1[Enter]

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[Enter]

Did you agree the License Agreement ?

1. Agree
2. Do Not Agree

Please choose one of above number:
1[Enter]

make[1]: ディレクトリ `/usr/local/vpnserver' に入ります
Preparing SoftEther VPN Server...
ranlib lib/libcharset.a
ranlib lib/libcrypto.a
ranlib lib/libedit.a
ranlib lib/libiconv.a
ranlib lib/libintelaes.a
ranlib lib/libncurses.a
ranlib lib/libssl.a
ranlib lib/libz.a
ranlib code/vpnserver.a
gcc code/vpnserver.a -O2 -fsigned-char -pthread -m64 -lm -ldl -lrt -lpthread -L./ lib/libssl.a lib/libcrypto.a lib/libiconv.a lib/libcharset.a lib/libedit.a lib/libncurses.a lib/libz.a lib/libintelaes.a -o vpnserver
ranlib code/vpncmd.a
gcc code/vpncmd.a -O2 -fsigned-char -pthread -m64 -lm -ldl -lrt -lpthread -L./ lib/libssl.a lib/libcrypto.a lib/libiconv.a lib/libcharset.a lib/libedit.a lib/libncurses.a lib/libz.a lib/libintelaes.a -o vpncmd
./vpncmd /tool /cmd:Check
vpncmd コマンド - SoftEther VPN コマンドライン管理ユーティリティ
SoftEther VPN コマンドライン管理ユーティリティ (vpncmd コマンド)
Version 4.08 Build 9449   (Japanese)
Compiled 2014/06/08 15:19:48 by yagi at pc25
Copyright (c) SoftEther VPN Project. All Rights Reserved.

VPN Tools を起動しました。HELP と入力すると、使用できるコマンド一覧が表示できます。

VPN Tools>Check
Check コマンド - SoftEther VPN の動作が可能かどうかチェックする
---------------------------------------------------
SoftEther VPN 動作環境チェックツール

Copyright (c) SoftEther VPN Project.
All Rights Reserved.

この動作環境チェックツールを実行したシステムがテストに合格した場合は、SoftEther VPN ソフトウェアが動作する可能性が高いです。チェックにはしばらく時間がかかる場合があります。そのままお待ちください...

'カーネル系' のチェック中...
              [合格] ○
'メモリ操作系' のチェック中...
              [合格] ○
'ANSI / Unicode 文字列処理系' のチェック中...
              [合格] ○
'ファイルシステム' のチェック中...
              [合格] ○
'スレッド処理システム' のチェック中...
              [合格] ○
'ネットワークシステム' のチェック中...
              [合格] ○

すべてのチェックに合格しました。このシステム上で SoftEther VPN Server / Bridge が正しく動作する可能性が高いと思われます。

コマンドは正常に終了しました。

--------------------------------------------------------------------
The preparation of SoftEther VPN Server is completed !


*** How to switch the display language of the SoftEther VPN Server Service ***
SoftEther VPN Server supports the following languages:
  - Japanese
  - English
  - Simplified Chinese

You can choose your prefered language of SoftEther VPN Server at any time.
To switch the current language, open and edit the 'lang.config' file.


*** How to start the SoftEther VPN Server Service ***

Please execute './vpnserver start' to run the SoftEther VPN Server Background Service.
And please execute './vpncmd' to run the SoftEther VPN Command-Line Utility to configure SoftEther VPN Server.
Of course, you can use the VPN Server Manager GUI Application for Windows on the other Windows PC in order to configure the SoftEther VPN Server remotely.
--------------------------------------------------------------------

make[1]: ディレクトリ `/usr/local/vpnserver' から出ます

パーミッションを変更して root 権限以外からの読み書きができないように保護します。

cd /usr/local/vpnserver
chmod 600 *
chmod 700 vpncmd
chmod 700 vpnserver

スタートアップスクリプトを作成します。

cat << EOT > /etc/init.d/vpnserver
#!/bin/sh
### BEGIN INIT INFO
# Provides:          vpnserver
# Required-Start:    $local_fs $network
# Required-Stop:     $local_fs $network
# Default-Start:     2 3 4 5
# Default-Stop:      0 1 6
# Short-Description: SoftEther VPN Server
# Description:       SoftEther VPN Server
### END INIT INFO

DAEMON=/usr/local/vpnserver/vpnserver
LOCK=/var/lock/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
EOT

スタートアップスクリプトのパーミッションを変更します。

chmod 755 /etc/init.d/vpnserver

自動起動するようにスタートアップスクリプトをサービスに登録します。

insserv vpnserver

VPN サービスを起動します。

service vpnserver start

SoftEther VPN Server の設定

SoftEther VPN Server の設定は vpncmd コマンド、または Windows に「VPN サーバー管理マネージャ」をインストールして行います。VPN サーバー管理マネージャを使用して設定するにはこちらを参照してください。

11
13
0

Register as a new user and use Qiita more conveniently

  1. You get articles that match your needs
  2. You can efficiently read back useful information
  3. You can use dark theme
What you can do with signing up
11
13