WelcomeWelcome | FAQFAQ | DownloadsDownloads | WikiWiki

Author Topic: piCore tun / tun0 interface for vtund  (Read 2995 times)

Offline onelife

  • Full Member
  • ***
  • Posts: 141
piCore tun / tun0 interface for vtund
« on: October 20, 2013, 08:19:10 AM »
Hi all,

So it looks like PiCore is going to be the new standard for my application as so far things are working well on building an initial system. I have however come across an "issue" that I am not sure if it's a vtund setting or process I need to tweak in creating an interface.

In order for virtual tunnel (vtund) to run it assigns the IP address to dev tun0. At the moment I see /dev/net/tun but when I run vtund it throws an error just saying it can't access tun / tun0 interface.

Any ideas on how I should add the interface at boot and / or other process within vtund to maybe point at /dev/net/tun ? At the moment my vtund starts, connects but then drops connection as it can't assign the tun IP to the tun0 interface.

Any ideas :) - Thanks!


Offline Rich

  • Administrator
  • Hero Member
  • *****
  • Posts: 11694
Re: piCore tun / tun0 interface for vtund
« Reply #1 on: October 20, 2013, 11:16:35 AM »
Hi onelife
Quote
... but when I run vtund it throws an error just saying it can't access tun / tun0 interface.
When asking for help, you should always provide the exact error message returned by the system. Have you looked
through the documentation provided by  vtun-doc.tcz ?

Offline bmarkus

  • Administrator
  • Hero Member
  • *****
  • Posts: 7183
    • My Community Forum
Re: piCore tun / tun0 interface for vtund
« Reply #2 on: October 20, 2013, 03:11:05 PM »
Please share your configuration file and the command line how are you starting vtund. On piCore 5.0alpha5 I can start vtund. It runs, and on ps list I see the comment "Waiting for connections on port 5000" I can't verify if it really works or not not being familira with vtund, but it starts without error message.
Béla
Ham Radio callsign: HA5DI

"Amateur Radio: The First Technology-Based Social Network."

Offline onelife

  • Full Member
  • ***
  • Posts: 141
Re: piCore tun / tun0 interface for vtund
« Reply #3 on: October 21, 2013, 02:18:18 AM »
Hi Guys,

Thanks for the reply .. sure, the exact command I am using to start the client (not server) is :

Code: [Select]
snb@sbs:~$ sudo vtund vpn14 108.161.128.40 -n
vtund[3894]: VTun client ver 3.X 10/16/2013 started
vtund[3894]: Connecting to 108.161.128.40
vtund[3894]: Remote Server sends <TuL9KE1>
.
vtund[3894]: Session vpn14[108.161.128.40] opened
vtund[3894]: Can't allocate tun device tun0. No such file or directory(2)
vtund[3894]: Session vpn14[108.161.128.40] closed
vtund[3894]: Exit

Interesting enough I see on the system I have :

Code: [Select]
snb@sbs:~$ ls -l /dev/net/tun
crw-rw-rwT    1 root     root       10, 200 Jan  1  1970 /dev/net/tun

As I say above, I'm starting the client to connect to a server, the command vtund -s starts the server and waits on port 5000. That I also see works 100%.

Thanks :)