Advertisement
If you have a new account but are having problems posting or verifying your account, please email us on hello@boards.ie for help. Thanks :)
Hello all! Please ensure that you are posting a new thread or question in the appropriate forum. The Feedback forum is overwhelmed with questions that are having to be moved elsewhere. If you need help to verify your account contact hello@boards.ie
Hi there,
There is an issue with role permissions that is being worked on at the moment.
If you are having trouble with access or permissions on regional forums please post here to get access: https://www.boards.ie/discussion/2058365403/you-do-not-have-permission-for-that#latest

Can't autoconnect to VPN

  • 21-03-2014 6:04pm
    #1
    Registered Users, Registered Users 2 Posts: 1,635 ✭✭✭


    Fairly basic user of linux here so bear with me.

    Firstly Lubuntu is running as a VM using VMWare Player.
    I have one wired NIC connection bridged from VM to host PC.
    I need to connect to a VPN and have configured the eth0 and VPN without any issue. At first I was trying to get the VPN to autoconnect when eth0 is active using network manager but due to keyring issues that wouldn't work.

    I was willing to put up with the limitations and connect manually to the VPN each time but I've decided that my PC is on too much of the day so set up sleep on the windows 8.1 host. Now when the host is awakened the VPN has dropped and traffic is passing over the normal connection which I don't want.

    I've now blanked the keyring password (madness?) and had to move my ca.crt to a folder outside the /home directory as it is encrypted and that caused problems.

    Now I'm at the point where I boot the VM and it just doesn't connect to eth0. I simply click eth0 in network manager and it connects and auto connects to the VPN which is the desired result but why wont it start on boot without manual intervention?
    Anyone able to assist?


Comments

  • Registered Users, Registered Users 2 Posts: 2,719 ✭✭✭ARGINITE


    Does the VM have network connectivity after a clean boot?


  • Registered Users, Registered Users 2 Posts: 1,635 ✭✭✭Conar


    ARGINITE wrote: »
    Does the VM have network connectivity after a clean boot?

    Not automatically. I enter network manager and click the eth0 connection and it connects to it and then the vpn. Just not automatically on log on.
    I've selected "automatically connect to this network"


  • Registered Users, Registered Users 2 Posts: 2,719 ✭✭✭ARGINITE


    What is in your interfaces file?


  • Registered Users, Registered Users 2 Posts: 1,635 ✭✭✭Conar


    # interfaces(5) file used by ifup(8) and ifdown(8)
    auto lo
    iface lo inet loopback


  • Registered Users, Registered Users 2 Posts: 2,719 ✭✭✭ARGINITE


    Add something along the lines of
    auto eth0
    iface eth0 inet dhcp
    

    or if you are using a static address
    auto eth0
    iface eth0 inet static
    address 192.168.1.5
    netmask 255.255.255.0
    gateway 192.168.1.254
    

    The file that you need to add that to is in /etc/network/interfaces. eth0 should come up automatically after rebooting after adding that.


  • Advertisement
  • Registered Users, Registered Users 2 Posts: 1,635 ✭✭✭Conar


    Sorry, should have mentioned that I'd tried that. Been trying numerous things without luck.
    With those lines added it boots fine, while loading the OS I see a message about "Waiting for network configuration".
    Then it only partially loads network manager, as in its there but no icon, and it doesn't auto connect. Also can't manually connect as it only lists the VPN, no eth0???

    jszfqc.jpg


  • Registered Users, Registered Users 2 Posts: 1,635 ✭✭✭Conar


    OK, so its dawning on me that ammending the interfaces file for eth0 is bypassing the network manager for that connection. But then how will the VPN auto connect?

    If I put the interface file back to how I had it originally I do see that the network manager is trying to connect (linux version of hourglass??)
    nxqh42.jpg

    If I run ifconfig while thats happening I see an IP address on eth0 in the correct range etc.
    Then when that stops and fails to connect, if I run ifconfig again theres no ip address assigned to eth0.

    So.....why is it that it is able to auto connect to eth0 on boot but trying to connect to the VPN just makes it release all config, BUT a simple left click on eth0 in network manager after that allows it to connect eth0 then the VPN without any issue?

    Is there a log I can look at?

    Alternatively, should I be looking at configuring the interface file to include the VPN?

    Thanks for all the help by the way!!


  • Registered Users, Registered Users 2 Posts: 2,719 ✭✭✭ARGINITE


    Have you tried a similar VM in Virtualbox just to rule out an issue with VMWareplayer?


  • Registered Users, Registered Users 2 Posts: 1,635 ✭✭✭Conar


    I haven't. I'll give it a go, cheers


Advertisement