[<prev] [next>] [<thread-prev] [day] [month] [year] [list]
Message-ID: <20130923091450.7615cc60@samsung-9>
Date: Mon, 23 Sep 2013 09:14:50 -0700
From: Stephen Hemminger <stephen@...workplumber.org>
To: Dani Camps <danicamps81@...oo.com>
Cc: "netdev@...r.kernel.org" <netdev@...r.kernel.org>
Subject: Re: Problem with tap interface: link is not ready
On Mon, 23 Sep 2013 16:51:47 +0100 (BST)
Dani Camps <danicamps81@...oo.com> wrote:
>
>
> Dear all,
>
> I am not sure that I am addressing the correct mailing list. In case I am not, please accept my apologies.
>
> I am trying to create a virtual tap device that I want to add later on to a bridge. My problem is that the tap interface always appears with state disabled if I do a ´brctl showstp br0´, and no traffic reaches the bridge. After some investigation I found out that the tap interface is never up. How can I bring the tap interface up?
>
> These are my detailed steps:
>
> sudo tunctl -t tap0
> sudo ifconfig tap0 192.168.0.2/24 up
>
> But when I look at dmesg I get:
>
> ADDRCONF(NETDEV_UP): tap0: link is not ready
>
>
> Nevertheless if I do 'ifconfig tap0' it seems to indicate that the interface is up:
>
> tap0 Link encap:Ethernet HWaddr 72:a0:fb:88:95:44
> inet addr:192.168.0.2 Bcast:192.168.0.255 Mask:255.255.255.0
> UP BROADCAST MULTICAST MTU:1500 Metric:1
> RX packets:0 errors:0 dropped:0 overruns:0 frame:0
> TX packets:0 errors:0 dropped:0 overruns:0 carrier:0
> collisions:0 txqueuelen:500
> RX bytes:0 (0.0 B) TX bytes:0 (0.0 B)
>
> But I never see a message in dmesg saying "tap0: link becomes ready." And when I add the tap0 interface it always appears disabled, so I think that the interface is never really up.
>
> My kernel is 3.0
>
> Any help to bring up the tap interface is much appreciated.
>
> Best Regards
>
> Daniel
> --
> To unsubscribe from this list: send the line "unsubscribe netdev" in
> the body of a message to majordomo@...r.kernel.org
> More majordomo info at http://vger.kernel.org/majordomo-info.html
The carrier state of the TAP device is up if a program has the tap device handle open.
If no program has the tap device open then carrier (IFF_RUNNING) will be down.
The bridge with STP monitors carrier state to decide whether to use the network
device.
In summary, unless you have an application using tap, the device will look
to network as if cable is unplugged.
--
To unsubscribe from this list: send the line "unsubscribe netdev" in
the body of a message to majordomo@...r.kernel.org
More majordomo info at http://vger.kernel.org/majordomo-info.html
Powered by blists - more mailing lists