Hello everyone,
Thanks for thoughtful and thorough advice. No luck so far, though.
I have two VLAN's now - 0003 and 0004, named "vlan3" and "vlan4" respectively - and still for some reason the CentOS fails to recognize them as one would expect. So I am puzzled as to what is still missing from the picture? Could the NIC itself (the hardware) introduce some undesired weirdness into the picture?
Thanks.
Boris.
On Fri, May 30, 2014 at 4:23 PM, Blake Hudson blake@ispn.net wrote:
Boris, I'd suggest reviewing the guide from Redhat on configuring your server ( https://access.redhat.com/site/documentation/en-US/Red_Hat_Enterprise_Linux/... )
In essence, eth0 is a shell. eth0.x is where all the traffic happens. VLANs will need to be explicitly defined on both the server and the switch in order for traffic to pass. Again, follow the RedHat guide for the server configuration. Be sure to set the interface filename and the device name inside the file to match the VLAN ID you're using. For example, VLAN 1 will be /etc/sysconfig/network-scripts/ifcfg-eth0.1 and the first line of the file should be DEVICE=eth0.1. VLAN 2 should use ifcfg-eth0.2 and DEVICE=eth0.2. It's easy to forget to update the DEVICE field inside the file and conflict with another device on the system so double check all work.
On the Cisco switch, define the VLANs:
Switch# configure terminal Switch(config)# vlan 2 Switch(config-vlan)# name vlan2 Switch(config-vlan)# end
... repeat for each VLAN
And configure the ports:
Switch# configure terminal Enter configuration commands, one per line. End with CNTL/Z. Switch(config)# interface gigabitethernet0/1 Switch(config-if)# switchport mode trunk Switch(config-if)# switchport trunk allowed vlan 1-4 Switch(config-if)# end
... repeat for other trunk ports. I'd also recommend turning off VTP and setting all non-trunk ports to access mode ( http://www.cisco.com/c/en/us/td/docs/switches/lan/catalyst3750x_3560x/softwa... ).
--Blake
Boris Epstein wrote the following on 5/30/2014 2:59 PM:
Hello all,
I have a CentOS box that has a NIC (eth0) on which I defined 4 VLAN's (counting the NIC itself): eth0, eth0.1, eth0.2 and eht0.3. Initially the Cisco switch was not partitioned into VLAN's which means that the only
VLAN
running on it was the default one (VLAN 1).
I have then played with VLAN's a bit on the switch and at this point have two: VLAN 1 (which is default and can not be deleted) and VLAN 3. The CentOS box is plugged into a trunk port on VLAN 3 which by virtue of
being
a trunk should belong to all VLANs. However, this does not seem to work
as
expected.
What I get is the following:
- eht0 does not come up at all.
ifup eth0 Device eth0 does not seem to be present, delaying initialization
eth0.3 comes up fine.
Other VLAN's do not come up. No error messages, just never show up.
Any insight into this would be most welcome. Primarily, I fail to understand why all those VLAN's came up on VLAN 1 and why now even VLAN 1 does not come up - even though the trunk port the device is plugged into
is
supposed to be a member of all VLAN's.
Thanks in advance.
Boris. _______________________________________________ CentOS mailing list CentOS@centos.org http://lists.centos.org/mailman/listinfo/centos
CentOS mailing list CentOS@centos.org http://lists.centos.org/mailman/listinfo/centos