VPN Manager for OpenVPN

  • The problem I saw was that downloaded scripts need their permissions changed before they can run. This isn't a problem for user scripts as you'd set them as executable right ;)


    The only other issue might be that the script security parameter is not being written. You can check out one on of the ovpn files to see if it's in there

  • Hi all,


    Back again with the "Checking Location info" hang issue. This only appears to be an issue on Kodi installed via RetroPi (so on Raspbian i believe?)


    Here's what Ive tried so far:


    - Switched to Libreelec - This works 100% but i now find myself back in Raspbian so that I can use RetroPi. So, then I tried:

    - Tried a variety of different settings within the VPN manager config. Didn't work

    - Tried a User Defined setup with my PIA credentials. Didn't Work.

    - Went through the troubleshooting page and closed issues on Github & tried all tweaks. Didn't Work.

    - Edited Template.txt to add additional lines found in one of the issues pages. Didn't work

    - Opened various different ports on my router. Didn't work.

    - Tried calling OpenVPN from the Terminal. Didn't work


    I believe from reading that this is something to do with DNS after the connection has been made but i don't know how to fix it :(


    I have tried everything that has been posted about this and am stuck . Please can anyone help?




    If I added:

    Code
    1. "dhcp-option DNS 8.8.8.8"

    to the end of the OPVN file or TEMPLATE.txt, would that work? I've given up trying after approx 3 hours of trying to hack through this :(

    Edited once, last by xsy77 ().

  • I believe this is a DNS issue, but I don't know why it's happening on some installs vs others.


    One path would be to download an ovpn file from PIA directly openvpn.zip

    If Kodi is running, make sure the VPN Mgr add-on is disabled (otherwise it'll try and mess with your connection)

    Then use the command line to invoke, eg openvpn Brazil.ovpn - it'll ask you for your user name and password, just like the add-on

    Once it's connected, then use a different session (or run it as a background task) to try pinging and examining the DNS config - what you use for this will be dependent on what tools are installed on your distro.


    Assuming that you still have the same problem (you will, the add-on is just calling the same ovpn files), then go ask PIA support what the problem is. Don't mention Kodi or add-ons - you're just running it via the command line (which is true).


    I'd like to see their answer to determine if there's something better I can do to fix this in the add-on, or at least detect that this is the problem.

  • Hi Zoboided,


    Many thanks for your reply.


    I will do as instructed and report back what PIA state.


    Thanks again,

    Christopher


    P.s. your work on this addon is nothing short of Stellar!

  • Code
    1. people I have a very difficult question.I want to log in to my holiday address /at too my home openvpn
    2. but in one way or another it does not work anyone's
    3. how to proceed thanks :)

    ASRock-j5005-j4105-,Q1900M +nvidia + pulse-eight.+ tv skysytar2HD Dvbs+vpn

  • Hi Zomboided,


    I have carried out what you have asked. Not getting much of a reply from the PIA support staff but there is a fellow on the forums who seems very keen to help. Post is here: Link


    I feel like Im getting closer but still no cigar. Any suggestions or should I just keep hacking?

  • 4.9.5 is available on the repo


    It's a pretty big overhaul, but it now has a lot of bug fixes, better debug and checking, a much better user wizard and a new reconnect only during streaming option.


    It's been well tested on Windows and RPi LE, and less so on OSMC but post up any issues

  • Hey Zomboided,


    So managed to get the VPN connected using the command line with some help from a very helpful member on the PIA forums: https://www.privateinternetaccess.com/forum/discussion/comment/55885#comment_55885


    In a nutshell, using the arguments: "--script-security 2 --up /etc/openvpn/update-resolv-conf --down /etc/openvpn/update-resolv-conf" from the command line worked perfectly however dont work when I add them to the ovpn file.


    I sense there is a way to get this to work if I create an up.bat and down.bat and use your toggle in the settings. However I am unsure how to create these .bat files so that your addon will run them correctly.


    I feel that I am very close to paradise but just need a little of your expertise to get there :)

  • Makes some sense. How are you adding them to the ovpn file? Are you modifying the template?

    See this page to generally understand how to do this, specifically, this link 10. Updating VPNs · Zomboided/service.vpn.manager Wiki · GitHub


    You should probably disable the options in the Advanced tab which talk to up/down scripts as that causes the template to get modified and it could overwrite your updates.


    You can reset the VPN provider and everything should get regenerated when you connect. Check out the resulting ovpn files to see if they contain what you expect

    Edited once, last by zomboided ().

  • Yeh I added the text to the bottom of the Template in the userdata folder and reset the vpn files via the GUI.


    Same result sadly. I will play around a bit more with the settings and come back to you with some logs.


    Thanks again for your support.

  • Ok, view the ovpn files in the addon/service.vpn.manager/PIA directory and check that they contain what you're expecting. If they do, then let's see a log. If they don't, I'll do some tests myself.

  • Got it! Mark this issue as solved!


    Added:


    dhcp-option DNSSEC allow-downgrade

    dhcp-option DOMAIN-ROUTE .


    script-security 2

    up /etc/openvpn/update-resolv-conf

    down /etc/openvpn/update-resolv-conf


    to the bottom of the TEMPLATE.TXT, disabled "systemd-resolved.service" that a previous tutorial advised and BINGO!


    Log:


    Tested fully using your add-on and we appear to be golden! Thank you so much for all your guidance!


    Just 2 things finally and then I'll leave you alone:


    1. Notice the "Too few arguments." in the log. What is that? what am I missing?


    2. With the VPN disconnected, my resolv.conf reads:


    # Generated by resolvconf
    nameserver XXX.XXX.XXX.XXX (ISP DNS)
    nameserver XXX.XXX.XXX.XXX (ISP DNS)


    With the VPN connected it reads:


    # Generated by resolvconf
    nameserver XXX.XXX.XXX.XXX (PIA DNS)
    nameserver XXX.XXX.XXX.XXX (PIA DNS)
    nameserver XXX.XXX.XXX.XXX (ISP DNS)
    nameserver XXX.XXX.XXX.XXX (ISP DNS)


    Is that ok? Should I be concerned that the ISP's DNS is still there?


    Anyway, no rush, Im off to configure finish this setup!


    Thank you again!

  • Good news!


    I'm not sure your update-resolv-conf is running cleanly based on the erorr messages. Does this fix work without the up and the down?

    Do you actually just need dhcp-option DOMAIN-ROUTE . to fix this (as this forces all DNS requests through the openvpn DNS servers)

    If so, I can build this into the add-on for others with the same issue. Would be great if you could try this for me. Cheers

    Edited once, last by zomboided ().

  • My use is basically for streaming and downloading torrents. That's it!

    That is indeed the thing that we are not promoting here. You should perhaps read our forum rules again which you agreed to when registering onto this forum. I've removed the link you had put in your post.

  • Hi...


    I hope somebody can help me out (or point me in the rite direction). I'm a relative noob to LE, but I am well versed in Kodi (and I am fluent in several programming languages). Ive searched and read... and read... and read without finding the answer Im looking for.


    Up until recently Ive been using Kodi on an Android box. I have since switched to a Raspberry Pi 3B running Libre Elec. On the droid box I was able to use Open VPN (under Android, not Kodi) with nothing more than a .ovpn file. Worked great... just had to start/stop the service through Android. Now on the RasPi I'm trying to make this work with no luck. It seems like I need to have the Username and Password (which I don't have access to).


    I've tried opening the .ovpn file in Notepad ++ to see if the info is in there, but either it's not there or I just don't know enough to know what lines have the info. I've tried setting up Open VPN MGR but see no place to link to the .ovpn file that I have. Do I need other programs to go with this one?


    I'm sure that its possible but I'm just missing something. I hate to ask... but I have searched and read trying to find the answer myself. I don't want to be one of those folks that are too lazy to do the work (especially on my very first post).


    Thanx in advance,

    S_N_S