SoftEther is a nice project to establish a VPN a bit easily using both windows and linux enviorment. It has also a vpn azure ddns.

My enviorment is

  • A network with various host most important are
  • A DNS server and ActiveDirectory Server.

    Inside there are adress for a specific client (we access via ipsec vpn)

    • jboss.production.office1
    • jboss.test.office2
    • jboss4.test.office
  • main router DHCP server and a VPN server. The IPsec VPN redirect all packet from the lan that goes to or or on VPN tunnel with next hop

  • a softether server.

Before I had a win notebook now I have Fedora 29 one.

Softether create a TUN network card for each VPN you want to connect the name is vpn_vpnnicname not managed via NetworkManager (or I don't know how to manage it)

  1. I connect via mobile phone and wireless via NetworkManager I am in a range\24 notebook is phone is

  2. I can establish a correct connection from softether client to server

  3. Under win it takes ip addr and configs in automatic mode. Under linux i have read that i need to request a ip via dhcp.
    dhclient vpn_vpnnicname  #THIS retrive a IP  
    The Leased IP is
  4. The next step is to add some row in routing table
    sudo ip route add via dev vpn_vpnnicname #the route to acces inside VPN
    sudo ip route add via dev vpn_vpnnicname #the rule to go to ipsec vpn
    Afther this no ping is working host in 192.168.1.x are unreachable. So i used dhcpcd
    sudo dhcpcd -B -G -C resolv.conf  vpn_vpnnicname
    This give the trick
    • I can read who offers the ip
    • I can read the IP leased
    • I can read the route adding for In routing table i see a row | | | U | 0 | 0 | 0 | vpn_vpnnicname
    I miss the second rule how to?
  5. The next step is to enable dns. Under win I can set it associated to the nic. Under Linux I think is not possible. the solution is to use globally but is not so nice is possible to use a (it can resolve only 20 host on 10.x.x.x network) as primary and as secondary. I have tried a lot of solution also the suggested How do I set my DNS when resolv.conf is being overwritten? the only that work is to write inside resolv.conf

Someone suggest to enable ip forward but is useful?

sudo sysctl -w net.ipv4.ip_forward=1  

The qestions are

  • How to create a correct dhcp lease
  • How to create a correct routing table
  • How to create a correct dns

Your Answer

By clicking “Post Your Answer”, you agree to our terms of service, privacy policy and cookie policy

Browse other questions tagged or ask your own question.