fedora 20 –> 3750 breakout –> switch block
the 3750 on top is the breakout switch. the four 3560’s comprise the switch block. the yellow cable goes to the linux pc ethernet port. the blue cables from the 3750 go to assigned vlans on the switch block.
the first order of business is to ensure your fedora box supports vlans on the nic.
this command proves it’s currently loaded:
[arteq@arteq-p7-1254 ~]$ lsmod | grep 8021q
8021q 28968 0
if not this command will load it:
[arteq@arteq-p7-1254 ~]$ sudo modprobe 8021q
you may or may not need to make file adjustments to etc/sysconfig. we’ll get to that.
the 3750 config. select a port on the 3750 to connect to your pc.
this will give you bidirectional and transparent l2 connectivity to gns3; in other words, you won’t see the 3750 when you issue sh cdp neigh. next: the pc and gns3.
this is the topology i am working with, but we’ll keep it simple.
that 3750 to the right represents a cloud. that is your way into the pc from gns3. the virtual gns3 ethernet switch is the way you chop out the vlans for use with your pc.
the cloud config:
simple. once the cable is connected to the nic on the pc, gns3 should discover it. add it and apply.
when you know what vlans you want to support, open the configuration of the gns3 ethernet switch:
all ports are access ports except the one representing the connection to your pc; that one needs to support dot1q. (11 in my config)
note: i have f0/0 from each router being supported by the same port number on the gns3 switch as the router number; r1 f0/0 –> port 1 gns3 switch and on down. r4 – r6 require a second port each (f1/0); they are ports 14 – 16 on the gns3 switch. port 11 attached to the cloud(3750) is the dot1q port going to the pc nic. remember, all other ports will be access.
back to the 3750. it needs to support the vlans represented in our diagram. we already have trunk support to the pc on f1/0/1. now we need to include vlans from the 3750 to the switch block.
there are a couple of differences between the access ports on the 3750 and the trunk to the pc.
you see, most of the work is done behind the scenes between gns3, your pc and the 3750 switch.
we are ready to test l2.
Type escape sequence to abort.
Sending 5, 100-byte ICMP Echos to 188.8.131.52, timeout is 2 seconds:
Success rate is 80 percent (4/5), round-trip min/avg/max = 20/39/64 ms
i have included svi’s on the switches for l3 support.
Now about l3:
i have done this with ubuntu in the past and i didn’t have to add anything to /etc/syconfig/. however, if you’ve proven l2 connectivity but you cannot ping, you may need to add devices to network-scripts. here’s how that is done. run sudo and launch an editor you’re comfortable with:
[arteq@arteq-p7-1254 ~]$ sudo gedit /etc/sysconfig/network-scripts/ifcfg-p5p1.100
this will open gedit so that you can build a vlan script for your nic.
you need to know your nic name (mine is p5p1, you add the ifcfg at the beginning) the vlan you want the nic to use (.100 as above; ifcfg-nic name dot vlan)
and build a file similar to this, substituting network specific parameters:
*******choose an ip for this config file that is NOT being used by the router or the real switch, but that still resides in the subnet they belong to.
make sure to save
it will not launch by itself, lmao.
you can try simply:
sudo ifup ifcfg-p5p1.100
and check with ifconfig:
p5p1.100: flags=4163<UP,BROADCAST,RUNNING,MULTICAST> mtu 1500
inet6 fe80::ea40:f2ff:fe0e:de63 prefixlen 64 scopeid 0x20<link>
if that doesn’t bring it up, try:
sudo systemctl restart network.service
or you could reboot.