Error code 1

Need help configuring your VPN? Just post here and you'll get that help.

Moderators: TinCanTech, TinCanTech, TinCanTech, TinCanTech, TinCanTech, TinCanTech

Forum rules
Please use the [oconf] BB tag for openvpn Configurations. See viewtopic.php?f=30&t=21589 for an example.
Post Reply
Jecder
OpenVpn Newbie
Posts: 4
Joined: Thu Sep 24, 2015 1:26 am

Error code 1

Post by Jecder » Thu Sep 24, 2015 1:35 am

I'm having trouble getting internet access through the VPN I set up. When I use the key on a remote computer I get this
Wed Sep 23 21:19:59 2015 OpenVPN 2.3.8 i686-w64-mingw32 [SSL (OpenSSL)] [LZO] [P
KCS11] [IPv6] built on Aug 4 2015
Wed Sep 23 21:19:59 2015 library versions: OpenSSL 1.0.1p 9 Jul 2015, LZO 2.08
Enter Private Key Password:
Wed Sep 23 21:20:02 2015 WARNING: this configuration may cache passwords in memo
ry -- use the auth-nocache option to prevent this
Wed Sep 23 21:20:02 2015 Control Channel Authentication: tls-auth using INLINE s
tatic key file
Wed Sep 23 21:20:02 2015 UDPv4 link local: [undef]
Wed Sep 23 21:20:02 2015 UDPv4 link remote: [AF_INET]73.46.136.93:1194
Wed Sep 23 21:20:02 2015 [PiVPN] Peer Connection Initiated with [AF_INET]73.46.1
36.93:1194
Wed Sep 23 21:20:05 2015 do_ifconfig, tt->ipv6=0, tt->did_ifconfig_ipv6_setup=0
Wed Sep 23 21:20:05 2015 open_tun, tt->ipv6=0
Wed Sep 23 21:20:05 2015 TAP-WIN32 device [Local Area Connection 2] opened: \\.\
Global\{685E0AFA-654E-45DD-900E-ED216DABB997}.tap
Wed Sep 23 21:20:05 2015 Notified TAP-Windows driver to set a DHCP IP/netmask of
10.8.0.10/255.255.255.252 on interface {685E0AFA-654E-45DD-900E-ED216DABB997} [
DHCP-serv: 10.8.0.9, lease-time: 31536000]
Wed Sep 23 21:20:10 2015 ROUTE: route addition failed using CreateIpForwardEntry
: Access is denied. [status=5 if_index=11]
Wed Sep 23 21:20:10 2015 env_block: add PATH=C:\Windows\System32;C:\WINDOWS;C:\W
INDOWS\System32\Wbem
Wed Sep 23 21:20:10 2015 ERROR: Windows route add command failed [adaptive]: ret
urned error code 1
Wed Sep 23 21:20:10 2015 ROUTE: route addition failed using CreateIpForwardEntry
: Access is denied. [status=5 if_index=15]
Wed Sep 23 21:20:10 2015 env_block: add PATH=C:\Windows\System32;C:\WINDOWS;C:\W
INDOWS\System32\Wbem
Wed Sep 23 21:20:10 2015 ERROR: Windows route add command failed [adaptive]: ret
urned error code 1
Wed Sep 23 21:20:10 2015 ROUTE: route addition failed using CreateIpForwardEntry
: Access is denied. [status=5 if_index=15]
Wed Sep 23 21:20:10 2015 env_block: add PATH=C:\Windows\System32;C:\WINDOWS;C:\W
INDOWS\System32\Wbem
Wed Sep 23 21:20:10 2015 ERROR: Windows route add command failed [adaptive]: ret
urned error code 1
Wed Sep 23 21:20:10 2015 ROUTE: route addition failed using CreateIpForwardEntry
: Access is denied. [status=5 if_index=15]
Wed Sep 23 21:20:10 2015 env_block: add PATH=C:\Windows\System32;C:\WINDOWS;C:\W
INDOWS\System32\Wbem
Wed Sep 23 21:20:10 2015 ERROR: Windows route add command failed [adaptive]: ret
urned error code 1
Wed Sep 23 21:20:10 2015 ROUTE: route addition failed using CreateIpForwardEntry
: Access is denied. [status=5 if_index=15]
Wed Sep 23 21:20:10 2015 env_block: add PATH=C:\Windows\System32;C:\WINDOWS;C:\W
INDOWS\System32\Wbem
Wed Sep 23 21:20:10 2015 ERROR: Windows route add command failed [adaptive]: ret
urned error code 1
Wed Sep 23 21:20:10 2015 Warning: address 10.0.1.26 is not a network address in
relation to netmask 255.255.255.0
Wed Sep 23 21:20:10 2015 ROUTE: route addition failed using CreateIpForwardEntry
: Access is denied. [status=5 if_index=15]
Wed Sep 23 21:20:10 2015 env_block: add PATH=C:\Windows\System32;C:\WINDOWS;C:\W
INDOWS\System32\Wbem
Wed Sep 23 21:20:10 2015 ERROR: Windows route add command failed [adaptive]: ret
urned error code 1
Wed Sep 23 21:20:10 2015 ROUTE: route addition failed using CreateIpForwardEntry
: Access is denied. [status=5 if_index=15]
Wed Sep 23 21:20:10 2015 env_block: add PATH=C:\Windows\System32;C:\WINDOWS;C:\W
INDOWS\System32\Wbem
Wed Sep 23 21:20:10 2015 ERROR: Windows route add command failed [adaptive]: ret
urned error code 1
Wed Sep 23 21:20:10 2015 Initialization Sequence Completed
server.conf file


local 10.0.1.26 # SWAP THIS NUMBER WITH YOUR RASPBERRY PI IP ADDRESS
dev tun
proto udp #Some people prefer to use tcp. Don't change it if you don't know.
port 1194
ca /etc/openvpn/easy-rsa/keys/ca.crt
cert /etc/openvpn/easy-rsa/keys/PiVPN.crt # SWAP WITH YOUR CRT NAME
key /etc/openvpn/easy-rsa/keys/PiVPN.key # SWAP WITH YOUR KEY NAME
dh /etc/openvpn/easy-rsa/keys/dh1024.pem # If you changed to 2048, change that here!
server 10.8.0.0 255.255.255.0
ifconfig 10.8.0.1 10.8.0.2
push "route 10.8.0.1 255.255.255.255"
push "route 10.8.0.0 255.255.255.0"
push "route 10.0.1.26 255.255.255.0" # SWAP THE IP NUMBER WITH YOUR RASPBERRY PI IP ADDRESS
push "dhcp-option DNS 8.8.8.8" # This should already match your router address and not need to be changed.
push "redirect-gateway def1"
client-to-client
duplicate-cn
keepalive 10 120
tls-auth /etc/openvpn/easy-rsa/keys/ta.key 0
cipher AES-128-CBC
comp-lzo
user nobody
group nogroup
persist-key
persist-tun
status /var/log/openvpn-status.log 20
log /var/log/openvpn.log
verb 1

User avatar
Traffic
OpenVPN Protagonist
Posts: 4066
Joined: Sat Aug 09, 2014 11:24 am

Re: Error code 1

Post by Traffic » Thu Sep 24, 2015 11:02 am

Jecder wrote:Wed Sep 23 21:20:10 2015 ROUTE: route addition failed using CreateIpForwardEntry
: Access is denied. [status=5 if_index=15]
Using the OpenVPN-GUI on W7/8/10 etc ..
  • Being logged in as administrator is not sufficient for OpenVPN to work.
    You must select OpenvpnGUI.exe and <right-click>:"Run As Administrator" ..
This is a security measure imposed by Microsoft not OpenVPN.

Jecder
OpenVpn Newbie
Posts: 4
Joined: Thu Sep 24, 2015 1:26 am

Re: Error code 1

Post by Jecder » Thu Sep 24, 2015 1:08 pm

yea I tried that too. From my office and from my laptop connected to a mobile hotspot.

Jecder
OpenVpn Newbie
Posts: 4
Joined: Thu Sep 24, 2015 1:26 am

Re: Error code 1

Post by Jecder » Thu Sep 24, 2015 9:23 pm

So I have right clicked on the program and ran as administrator. I then right clicked on the .ovpn file and ran with openvpn gui. Still the same exact message

User avatar
Traffic
OpenVPN Protagonist
Posts: 4066
Joined: Sat Aug 09, 2014 11:24 am

Re: Error code 1

Post by Traffic » Fri Sep 25, 2015 12:31 pm

Jecder wrote:Still the same exact message
If this is your own PC then you are still not running as administrator .. If this is your work PC perhaps you are not given administrator rights by network policy.

Jecder
OpenVpn Newbie
Posts: 4
Joined: Thu Sep 24, 2015 1:26 am

Re: Error code 1

Post by Jecder » Fri Sep 25, 2015 5:38 pm

I figured out the issue. Even though I was running the openvpn gui as administrator the .ovpn file was using a different program. I went to the program and opened up advanced settings and ticked the run as administrator so it will run as admin everytime it starts up and doesn't need to be forcefully each time. YAY!!! I have full connectivity now.

rrocha@rochacontrols.com
OpenVpn Newbie
Posts: 2
Joined: Mon Jul 27, 2020 6:14 pm

Re: Error code 1

Post by rrocha@rochacontrols.com » Mon Jul 27, 2020 6:33 pm

this fixed mine after hours of &nbsp; around with everything. i clarified one step for others.


I figured out the issue. Even though I was running the openvpn gui as administrator the .ovpn file was using a different program.

I went to the program "and opened file location" and on OPenVPN GUI, right clicked and opened up advanced settings and ticked the run as administrator so it will run as admin everytime it starts up and doesn't need to be forcefully each time. YAY!!! I have full connectivity now.

TinCanTech
OpenVPN Protagonist
Posts: 11137
Joined: Fri Jun 03, 2016 1:17 pm

Re: Error code 1

Post by TinCanTech » Mon Jul 27, 2020 7:23 pm

The OpenVPN GUI should never be run as administrator.

https://community.openvpn.net/openvpn/w ... PN-GUI-New

If you have to run the GUI as an administrator then you are using an old
and unsupported version of OpenVPN.

The risk you take is your and yours alone.

Post Reply