Connecting to a network via VPN

My base os is ubuntu and on this i have two vpns. For work related i need to connect to two vpns. One is pulse secure and the other is forticlient. For some reason i need to connect to subnet in forticlient vpn. But whenever i connect to pulse secure my subnet towards forticlient is not working. Hence everytime i need to disconnect and connect pulse.

  1. Can any one help me on how to use route command or IPTables or anyother option to help route subnet to one vpn while rest on another vpn.
    Note: I have only wireless connections no lan
  2. How can i use a script to connect and disconnect pulse secure vpn. Also it has mfa enabled.

Hi Vinod,

Welcome to our forums.

While networking and vpn is not my profession, I’m afraid what you trying to do is not possible by design. You see, VPN is supposed to put you (your computer) into a private network, blocking all other networking and allowing only the traffic that is allowed from inside the private network. So in order to access resources from both private networks, one of them should be allowed to be accessible from the other - and this is not something you can handle on the client side.

That being said, you could try to run a virtual machine on your computer, and after connecting to the first VPN with the host computer, you could connect to the other one from the virtual machine, if you have access to the second VPN server from inside the first VPN.