Hướng dẫn cài đặt SoftEther VPN Server trên CentOS 6.x

SoftEther VPN là một phần mềm đa giao thức VPN mã nguồn mở mạnh mẽ và dễ sử dụng. Tương thích với nhiều hệ điều hành khác nhau như: Windows, Linux, Mac, FreeBSD và Solaris. SoftEther trở thành phần mềm mã nguồn mở vào đầu năm 2014 và là phần mềm tối ưu thay thế cho Open VPN và Microsoft’s VPN Servers.

* Bảng so sánh các chức năng của OpenVPN và SoftEther VPNHướng dẫn cài đặt SoftEther VPN Server trên CentOS 6.x 12

1.Kiểm tra hệ thống và thư viện

Để cài đặt SoftEther Server, bạn cần phải có các thư viện sau:

  • gcc software
  • binutils software
  • tar, gzip or other software for extracting package files
  • chkconfig system utility
  • cat, cp or other basic file operation utility
  • EUC-JP, UTF-8 or other code page table for use in a Japanese language environment
  • libc (glibc) library
  • zlib library
  • openssl library
  • readline library
  • ncurses library
  • pthread library

Chạy lệnh sau để kiểm tra và cài đặt thư viện còn thiếu:

yum install -y gcc* binutils zlib openssl readline ncurses pth

2.Cài đặt SoftEther VPN Server

Vào link: http://www.softether-download.com/en.aspx

Chọn gói cài đặt phù hợp với server của bạn.

Hướng dẫn cài đặt SoftEther VPN Server trên CentOS 6.x 13

Sau đó, lấy link của phiên bản mới nhất và dùng lệnh wget để tải về server

wget http://www.softether-download.com/files/softether/v4.25-9656-rtm-2018.01.15-tree/Linux/SoftEther_VPN_Server/64bit_-_Intel_x64_or_AMD64/softether-vpnserver-v4.25-9656-rtm-2018.01.15-linux-x64-64bit.tar.gz

Lần lượt sử dụng các lệnh sau để cài đặt

tar xvzf softether-vpnserver-v4.25-9656-rtm-2018.01.15-linux-x64-64bit.tar.gz 
mv vpnserver /usr/local 
cd /usr/local/vpnserver 
make

Nhấn phím 1 ba lần để cài đặt.

3.Kiểm tra SoftEther VPN Server

Sau khi cài đặt thành công, bạn cần kiểm tra lại xem SoftEther có tương thích hay không, có xảy ra lỗi nào hay không, bằng cách chạy lệnh:

./vpncmd 
Chọn 3 
Gõ check

Sau khi check, nếu xảy ra lỗi, hãy thử kiểm tra lại các thư viện xem đã được cài đặt đầy đủ chưa. Nếu hệ thống báo thành công, thì tiếp tục tạo script để SoftEther khởi động cùng hệ thống

Tạo file /etc/init.d/vpnserver bằng lệnh

nano /etc/init.d/vpnserver

Và copy nội dụng bên dưới vào:

#!/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

CHMOD 775

chmod 755 /etc/init.d/vpnserver

Thiết lập cho SoftEther tự khởi động sau khi reboot server

chkconfig vpnserver on

Khởi động lại SoftEther

service vpnserver restart

Các bạn có thể sử dụng SoftEther VPN Server Management để quản lí. Tải về tại đây

[su_button url=”http://www.softether-download.com/files/softether/v4.25-9656-rtm-2018.01.15-tree/Windows/SoftEther_VPN_Server_and_VPN_Bridge/softether-vpnserver_vpnbridge-v4.25-9656-rtm-2018.01.15-windows-x86_x64-intel.exe” target=”blank” style=”flat” center=”yes” icon=”icon: cloud-download”]Tải SoftEther VPN Server Manager for Windows[/su_button]