Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

[Solved] Error occurred. (Error code: 31) #148

Closed
gulbuhar opened this issue Apr 24, 2015 · 11 comments
Closed

[Solved] Error occurred. (Error code: 31) #148

gulbuhar opened this issue Apr 24, 2015 · 11 comments

Comments

@gulbuhar
Copy link

Im getting this on my 64bit gentoo box, any idea how to solve it?
I also get the same thing even with vpncmd running as root

~# vpnclient start
~$vpncmd
or
~# vpncmd

Select 1, 2 or 3: 2

Specify the host name or IP address of the computer that the destination VPN Client is operating on.
If nothing is input and Enter is pressed, connection will be made to localhost (this computer).
Hostname of IP Address of Destination:

Connected to VPN Client "localhost".
VPN Client>remoteenable
RemoteEnable command - Allow Remote Management of VPN Client Service
The command completed successfully.

VPN Client>niccreate
NicCreate command - Create New Virtual Network Adapter
Virtual Network Adapter Name: test

Error occurred. (Error code: 31)
Installation of the Virtual Network Adapter device driver failed.

VPN Client>

@gulbuhar
Copy link
Author

i just find the solution
TUN/TAP needs to be enabled to create Virtual Network Adapter to do so
regenerate the kernel with

Device Drivers --->
Network device support --->
[*] Universal TUN/TAP device driver support

@gulbuhar gulbuhar changed the title Error occurred. (Error code: 31) [Solved]Error occurred. (Error code: 31) Apr 24, 2015
@gulbuhar gulbuhar changed the title [Solved]Error occurred. (Error code: 31) [Solved] Error occurred. (Error code: 31) Apr 24, 2015
@Pireirik
Copy link

excuse me, how do you solve this problem finally? I met this problem before, but I haven't found a solution yet.

@Palciny
Copy link

Palciny commented Oct 30, 2016

@Eric7Coding runing sudo ./vpnclient start before ./vpncmd worked for me

@moatazelmasry2
Copy link
Member

@Eric7Coding depends on your Linux distro, but as @gulbuhar mentioned, you might need to enable tun/tap in the kernel and recompile and install the kernel

@nerdyness
Copy link

For what it's worth, I ran into this issue using Ubuntu 16.04 LTS and solved it via...

sudo modprobe -v tunnel4
sudo modprobe -v ip_tunnel
sudo /usr/local/vpnclient/vpnclient stop
sudo /usr/local/vpnclient/vpnclient start
/usr/local/vpnclient/vpncmd

NOTE: this change is only temporary and after a reboot these kernel modules will be removed again. You can auto-load them on every reboot by adding them permanently to /etc/modules via:

echo -e "tunnel4\nip_tunnel" | sudo tee -a /etc/modules

@seanlowe
Copy link

seanlowe commented Sep 1, 2018

For someone using WSL (Windows Subsystem for Linux), this does not entirely work. What could be some other workaround? Creating a virtual NIC in windows and somehow mapping it into the VPN client?

@nerdyness
Copy link

Sorry, I can't help you out here. The way I see it you have two options here:

  1. Use the Windows Client
  2. Run Linux in a VM (on VirtualBox, Hyper-V, or the like)

@seanlowe
Copy link

seanlowe commented Sep 3, 2018

Yeah, those were my thoughts too. Thanks for the input!

@adamryczkowski
Copy link

The Ubuntu 16.04 solution did not work for me on Ubuntu 18.04. Did anyone manage to run the vpnclient on Bionic?

@arno01
Copy link

arno01 commented Aug 17, 2021

The Ubuntu 16.04 solution did not work for me on Ubuntu 18.04. Did anyone manage to run the vpnclient on Bionic?

Ubuntu 20.04 here, everything is working.

Make sure to use sudo, i.e. sudo ./vpnclient start.
(Didn't need to modprobe anything).

@fti-cneve
Copy link

Is this issue fixed in the newest kernel, such as 6.1.X?

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

No branches or pull requests

9 participants