tech-net archive

[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index][Old Index]

Re: About bridges

Staffan Thomén <> wrote:
>Robert Swindells wrote:
>> Staffan Thomén<>  wrote:
>>> No takers for this? Can someone at least check that I'm not crazy?
>> Which bit of "this" ?
>> Your last message suggests to me that you have a working bridged network.
>It works partially; DHCP replies don't seem to show up on the tap device
>so it does not configure an address. I kept a tcpdump on the tap while
>running dhcpcd and I can see dhcpcd retrying the sending to no avail.

Do you need to use DHCP to get an address ?

I have a theory that the MAC address learning feature of bridge(4)
doesn't work well with BOOTP/DHCP, I have a local change to explicitly
add the MAC address of each interface. You could look at the state of
the address cache by running 'brconfig -a'.

People use tap(4) in two ways:

1) To add an extra IP address for the host machine.
2) To connect a software emulator like qemu to the host.

In usage 2, you don't setup an IP address for the tap(4) device, the
virtual network device in the emulator has a different MAC address to
the tap(4) device and can get an IP address using DHCP.

Also, there is a shortcut in bridge(4) if it detects that a packet is
for an "internal" address.

If you do add an IP address for the tap(4) device then that will be
treated as an internal one.

>Additionally, even if I manually configure an address on the tap
>interface and I can use it to connect using ssh, tcpdump on the tap
>device doesn't show the unicast packets, which I don't think is right

I think that usage will be hitting the shortcut I described above, the
packets are treated as being for the host machine so don't get sent to
the tap interface.

Home | Main Index | Thread Index | Old Index