public inbox for gentoo-user@lists.gentoo.org
 help / color / mirror / Atom feed
* [gentoo-user] tun/tap - ifconfig tun0 - device not found
@ 2006-07-07 22:04 Claudinei Matos
  2006-07-08 16:53 ` Hans-Werner Hilse
  0 siblings, 1 reply; 3+ messages in thread
From: Claudinei Matos @ 2006-07-07 22:04 UTC (permalink / raw
  To: gentoo-user

[-- Attachment #1: Type: text/plain, Size: 739 bytes --]

Hi guys,

I'm trying to use tun/tap to assign some ip to my server (since I'll need it
to my LVS solution) and I think it's a trivial task to put tun to work, but
I'm trying in 3 different machines (with 2  different kernels) and in both
they when I try to ifconfig tun0 I get the follow message:
tun0: error fetching interface information: Device not found

Well, I'd try to look if is something wrong with my kernel configuration but
is everything ok since it just need tun/tap support to be compiled (I did
tried both module and built-in).

/dev/net/tun is a valid character device with 10, 200 (major/minor)

the both kernel I'd tried are 2.6.16-gentoor3 and 2.6.16-gentoo-r9.

so where the error?

tks in advice,

-- 
Claudinei Matos

[-- Attachment #2: Type: text/html, Size: 812 bytes --]

^ permalink raw reply	[flat|nested] 3+ messages in thread

* Re: [gentoo-user] tun/tap - ifconfig tun0 - device not found
  2006-07-07 22:04 [gentoo-user] tun/tap - ifconfig tun0 - device not found Claudinei Matos
@ 2006-07-08 16:53 ` Hans-Werner Hilse
  2006-07-08 18:01   ` Claudinei Matos
  0 siblings, 1 reply; 3+ messages in thread
From: Hans-Werner Hilse @ 2006-07-08 16:53 UTC (permalink / raw
  To: gentoo-user

Hi,

On Fri, 7 Jul 2006 19:04:41 -0300
"Claudinei Matos" <claudineimatos@gmail.com> wrote:

> I'm trying to use tun/tap to assign some ip to my server (since I'll need it
> to my LVS solution) and I think it's a trivial task to put tun to work, but
> I'm trying in 3 different machines (with 2  different kernels) and in both
> they when I try to ifconfig tun0 I get the follow message:
> tun0: error fetching interface information: Device not found
> 
> Well, I'd try to look if is something wrong with my kernel configuration but
> is everything ok since it just need tun/tap support to be compiled (I did
> tried both module and built-in).
> 
> /dev/net/tun is a valid character device with 10, 200 (major/minor)

...and, is at first all you get by enabling TUN support in the kernel.
See /usr/src/linux/Documentation/networking/tuntap.txt for more
information about the ioctl() you have to issue in order to register a
tun network device (TUNSETIFF). The docs have a code example, too.

Oh, and I think OpenVPN has inbuilt functionality to create or remove
tun network devices (independent from OpenVPNs other functionality).

I've not completely understood what your usage scenario was, but maybe
a dummy network device is enough?

-hwh
-- 
gentoo-user@gentoo.org mailing list



^ permalink raw reply	[flat|nested] 3+ messages in thread

* Re: [gentoo-user] tun/tap - ifconfig tun0 - device not found
  2006-07-08 16:53 ` Hans-Werner Hilse
@ 2006-07-08 18:01   ` Claudinei Matos
  0 siblings, 0 replies; 3+ messages in thread
From: Claudinei Matos @ 2006-07-08 18:01 UTC (permalink / raw
  To: gentoo-user

[-- Attachment #1: Type: text/plain, Size: 1886 bytes --]

tks for the help.. I was really thinking about give dummy interface a try
but instead I did solved my problem using an lo alias like this:

ifconfig lo:0 192.168.1.2 broadcast 192.168.1.2 netmask 255.255.255.255

supposing that eth0 is on the same network ;)

what is funny is that on all LVS guides I'd read, they just mention the
sequence:
modprobe tun
ifconfig tun0 x.x.x.x

no one talk about initiate the tun device or to use some other software to
do that.

tks,

claudinei matos

On 7/8/06, Hans-Werner Hilse <hilse@web.de> wrote:
>
> Hi,
>
> On Fri, 7 Jul 2006 19:04:41 -0300
> "Claudinei Matos" <claudineimatos@gmail.com> wrote:
>
> > I'm trying to use tun/tap to assign some ip to my server (since I'll
> need it
> > to my LVS solution) and I think it's a trivial task to put tun to work,
> but
> > I'm trying in 3 different machines (with 2  different kernels) and in
> both
> > they when I try to ifconfig tun0 I get the follow message:
> > tun0: error fetching interface information: Device not found
> >
> > Well, I'd try to look if is something wrong with my kernel configuration
> but
> > is everything ok since it just need tun/tap support to be compiled (I
> did
> > tried both module and built-in).
> >
> > /dev/net/tun is a valid character device with 10, 200 (major/minor)
>
> ...and, is at first all you get by enabling TUN support in the kernel.
> See /usr/src/linux/Documentation/networking/tuntap.txt for more
> information about the ioctl() you have to issue in order to register a
> tun network device (TUNSETIFF). The docs have a code example, too.
>
> Oh, and I think OpenVPN has inbuilt functionality to create or remove
> tun network devices (independent from OpenVPNs other functionality).
>
> I've not completely understood what your usage scenario was, but maybe
> a dummy network device is enough?
>
> -hwh
> --
> gentoo-user@gentoo.org mailing list
>

[-- Attachment #2: Type: text/html, Size: 2478 bytes --]

^ permalink raw reply	[flat|nested] 3+ messages in thread

end of thread, other threads:[~2006-07-08 18:18 UTC | newest]

Thread overview: 3+ messages (download: mbox.gz follow: Atom feed
-- links below jump to the message on this page --
2006-07-07 22:04 [gentoo-user] tun/tap - ifconfig tun0 - device not found Claudinei Matos
2006-07-08 16:53 ` Hans-Werner Hilse
2006-07-08 18:01   ` Claudinei Matos

This is a public inbox, see mirroring instructions
for how to clone and mirror all data and code used for this inbox