使用bash连接到Ubuntu中的VPN连接

问题描述 投票:4回答:2

当我只能使用bash(终端)时,如何连接到VPN Connection

我创建了一个连接,但我想使用远程ssh连接进行连接或断开连接

linux bash vpn
2个回答
7
投票

你可以使用nmcli来做到这一点。该程序用于网络管理。

nmcli con up id <name_of_connection>

在使用此命令之前,需要保存该连接的密码。有关更多信息,请尝试man nmcli

任何关于如何在bash中创建VPN_CONNECTION的帮助以及如何管理它们都会很感激


1
投票

安装包

  sudo apt-get install vpnc network-manager-vpnc network-manager-vpnc-gnome

然后从bash你可以尝试

vpnc-connect vpn.conf

你需要提供vpn配置文件作为参数。

© www.soinside.com 2019 - 2024. All rights reserved.