Re: if_bridge with two subnets
- From: "H.fazaeli" <fazaeli@xxxxxxxxxxx>
- Date: Mon, 12 May 2008 19:50:50 +0430
Jay L. T. Cornwall wrote:
H.fazaeli wrote:It does work. However, if I understand your setup correctly, the freebsd box
The bridge works as it should: It receives packets from
XX.XX.XXX.YYY on the interface connected to the switch, and
forwards them on the interface connected to the gateway.
The problem is that forwarding between subnets is the responsibility
of your switch. The switch does its job, but since the two clients are
not on the same IP subnet, they can not reach each other w/o the help of
an intermediate router.
Perhaps I am mixing up two separate networking concepts.
On a machine configured to act as a gateway, I would expect a single interface with more than one subnet to route packets correctly across those subnets. That may not be how it works in practice.
If it does not work, I would question why not. If it does work then I would expect the same behaviour on each of a bridge's constituent interfaces?
has been setup to act as a bridge, not as a router (routing is enabled with
sysctl net.inet.ip.forwarding=1). Bridging works when the forwarding is
between the same subnets.
For freebsd box to route between subnets:
- enable routing: sysctl net.inet.ip.forwarding=1
- clients must use the freebsd box as gateway.
- IP addresses must be removed from the bridge and assigned to
the member interfaces. (the bridge is no longer needed).
You may have bridging & routing on the same box at the same time but
note that a single packet coming into the system either goes through
bridging _or_ routing code, but not both. The former case happens
if packet's destination MAC address is not that of box. The
latter case happens when destination MAC address is that of receiving
interface.
If you provide a network diagram along with your requirements,
we can better discuss the matter.
--
With best regards.
Hooman Fazaeli <fazaeli@xxxxxxxxxxx>
Technical Manager Sepehr S. T. Co. Ltd.
Web: http://www.sepehrs.com
Tel: (9821)88975701-2
Fax: (9821)88983352
_______________________________________________
freebsd-net@xxxxxxxxxxx mailing list
http://lists.freebsd.org/mailman/listinfo/freebsd-net
To unsubscribe, send any mail to "freebsd-net-unsubscribe@xxxxxxxxxxx"
- Follow-Ups:
- Re: if_bridge with two subnets
- From: Jay L. T. Cornwall
- Re: if_bridge with two subnets
- References:
- if_bridge with two subnets
- From: Jay L. T. Cornwall
- Re: if_bridge with two subnets
- From: H.fazaeli
- Re: if_bridge with two subnets
- From: Jay L. T. Cornwall
- if_bridge with two subnets
- Prev by Date: Re: read() returns ETIMEDOUT on steady TCP connection
- Next by Date: Re: kern/123603: [tcp] tcp_do_segment and Received duplicate SYN
- Previous by thread: Re: if_bridge with two subnets
- Next by thread: Re: if_bridge with two subnets
- Index(es):
Relevant Pages
|