Date: Sun, 6 Aug 2000 00:52:22 -0400 From: James FitzGibbon <james@ehlo.com> To: Bob Van Valzah <Bob@whitebarn.com> Cc: freebsd-net@freebsd.org Subject: Re: VLAN Config Advice Message-ID: <20000806005221.A8147@ehlo.com> In-Reply-To: <398C491E.D7ED5E9F@WhiteBarn.Com>; from Bob@WhiteBarn.Com on Sat, Aug 05, 2000 at 12:04:30PM -0500 References: <398C491E.D7ED5E9F@WhiteBarn.Com>
next in thread | previous in thread | raw e-mail | index | archive | help
* Bob Van Valzah (Bob@WhiteBarn.Com) [000805 13:04]: > I'm having trouble getting VLANs to work on a 4.1-RELEASE system and > would appreciate any advice from those who have it running. (If I'm able > to get a decent understanding of the issues involved, I may even tackle > writing a section for the Handbook on VLANs.) I'll lay out one working VLAN config on 4.x for you: 172.20.32.0/20 VLAN ID 2 172.16.8.0/22 VLAN ID 3 Physical: one CAT5 cable running from fxp1 to a port on an HP Procurve 4000M. On the HP, the port is set to have both VLAN2 and VLAN3 set up as 'tagged'. On some other switch or router, you may have to set things up differently. I'm familiar with Cisco's way of configuring the other end, but won't go into it unless you say that you're using Cisco (it's a long answer). Logical: fxp1: flags=8843<UP,BROADCAST,RUNNING,SIMPLEX,MULTICAST> mtu 1500 inet 169.254.1.1 netmask 0xffffffff broadcast 169.254.1.1 ether 00:d0:b7:65:bf:f5 media: autoselect (100baseTX <full-duplex>) status: active supported media: autoselect 100baseTX <full-duplex> 100baseTX 10baseT/UTP <full-duplex> 10baseT/UTP vlan0: flags=8843<UP,BROADCAST,RUNNING,SIMPLEX,MULTICAST> mtu 1496 inet 172.16.8.101 netmask 0xfffffc00 broadcast 172.16.11.255 ether 00:d0:b7:65:bf:f5 vlan: 3 parent interface: fxp1 vlan1: flags=8843<UP,BROADCAST,RUNNING,SIMPLEX,MULTICAST> mtu 1496 inet 172.20.32.101 netmask 0xfffff000 broadcast 172.20.47.255 ether 00:d0:b7:65:bf:f5 vlan: 2 parent interface: fxp1 I get this configuration on boot this way: 1. I have 'pseudo-device vlan 2' in my kernel 2. My rc.conf looks like this: network_interfaces="fxp1 vlan0 vlan1" ifconfig_fxp1="inet 169.254.1.1 netmask 255.255.255.255" ifconfig_vlan0="inet 172.16.8.101 netmask 255.255.252.0" ifconfig_vlan1="172.20.32.101 netmask 255.255.240.0" I do the VLAN association by way of an /etc/start_if.vlan0 script, which reads like this: ifconfig vlan0 vlan 3 vlandev fxp1 Since the start_if scripts run before the ifconfig magic from rc.conf, the tag ids are set up prior to any real addresses being assigned to the vlan interfaces. The use of 169.254.1.1 is borrowed from the range that M$ uses to default configure DHCP interfaces. I believe that there is an RFC or IETF draft that suggests that this range be used for similar applications. Upon reboot, everything works fine. -- j. To Unsubscribe: send mail to majordomo@FreeBSD.org with "unsubscribe freebsd-net" in the body of the message
Want to link to this message? Use this URL: <https://mail-archive.FreeBSD.org/cgi/mid.cgi?20000806005221.A8147>