当前位置:首页>文章中心>Linux>CentOS 7.6 下安装 SoftEther VPN Server

CentOS 7.6 下安装 SoftEther VPN Server

发布时间:2026-01-28 点击次数:7

一、安装SoftEther VPN Server

1. 安装编译环境

yum -y install gcc

2.下载安装包

wget https://www.softether-download.com/files/softether/v4.43-9799-beta-2023.08.31-tree/Linux/SoftEther_VPN_Server/64bit_-_Intel_x64_or_AMD64/softether-vpnserver-v4.43-9799-beta-2023.08.31-linux-x64-64bit.tar.gz

3. 解压缩文件

tar -zxvf softether-vpnserver-*.tar.gz

4. 进入到解压目录

cd vpnserver

5. 启动安装脚本

./.install.sh

6. 启动服务

./vpnserver start

7. 进入VPN的命令行

./vpncmd

选择1. Management of VPN Server or VPN Bridge

这里需要选择地址和端口。默认443端口,如果需要修改,可以输入localhost:5555(实际端口),然后出现:

If connecting to the server by Virtual Hub Admin Mode, please input the Virtual Hub name.
If connecting by server admin mode, please press Enter without inputting anything.
Specify Virtual Hub Name:

这里就是指定一个虚拟HUB名字,用默认的直接回车就行。

Connection has been established with VPN Server "localhost" (port 5555).

You have administrator privileges for the entire VPN Server.

VPN Server>

输入ServerPasswordSet命令设置远程管理密码,确认密码后就可以通过Windows版的SoftEther VPN Server Manager远程管理了。

8. 设置自启动服务

新建启动脚本/etc/systemd/system/vpnserver.service

[Unit]
Description=SoftEther VPN Server
After=network.target

[Service]
Type=forking
ExecStart=/root/vpnserver/vpnserver start
ExecStop=/root/vpnserver/vpnserver stop

[Install]
WantedBy=multi-user.target

然后就可以通过systemctl start vpnserver启动了,并通过systemctl enable vpnserver设置开机自启。


微信公众号

028-13085881145