Tek-Tips is the largest IT community on the Internet today!

Members share and learn making Tek-Tips Forums the best source of peer-reviewed technical information on the Internet!

  • Congratulations IamaSherpa on being selected by the Tek-Tips community for having the most helpful posts in the forums last week. Way to Go!

dot1q vlans

Status
Not open for further replies.

ttnnee

MIS
Sep 20, 2001
52
US
I have a 4006 switch and a 3640 router with one fast ethernet port. I set up two vlans on the switch (vlan 1 & vlan 2) and trunk one of the ports that the router is on. I set the trunk to dot1q encapsulation in nonegiotate mode. On the router side I set up this config.

config t
int fa 1/0
ip address 10.250.237.254 secondary
ip address 10.250.230.254
int fa 1/0.2
encapsulation dot1q 2
ip addresss 10.250.224.254
description Vlan 2

I cant get the intervlan routing to work. I think the problem is the fact that with the IOS I am using on the router I cannot use the "encapsulation dot1q 1 native" command on the sub-interface. This is why I didn't create a sub-interface for vlan 1. Does anyone have any ideas? I think the problem is that the native vlans arent matching on both sides. The native vlan on the switch side is 1.
 
That is your problem. You need to have both vlans configured on the router to perform inter Vlan communication. Why are you using dot1q? why are you using a secondary address? personaly I would config it this way.

Switch(config)#ip address 10.250.230.x 255.255.255.0
Switch(config)#ip default-gateway 10.250.230.254
Switch(config)#vtp domain myswitch
Switch(config)#vtp server
Switch(config)#vlan 1 name sales
Switch(config)#vlan 2 name Audit
Switch(config)#int e0/1
Switch(config-if)#vlan-membership static 1
Switch(config-if)#desc VLAN1
Switch(config-if)#int e0/2
Switch(config-if)#vlan-membership static 2
Switch(config-if)#desc VLAN2
Switch(config-if)#int f0/26
Switch(config-if)#duplex full
Switch(config-if)#trunk on
Switch(config-if)#desc trunk to router3640

Router on a stick config

Router(config)#int f1/0
Router(config-if)#no ip address
Router(config-if)#int f0/0.1
Router(config-if)#ip address 10.250.230.254 255.255.255.0
Router(config-if)#int f0/0.2
Router(config-if)#encap isl 1
Router(config-if)#ip address 10.250.237.254 255.255.255.0
Router(config-if)#int f0/0.3
Router(config-if)#encap isl 2
Router(config-if)#ip address 10.250.224.254 255.255.255.0


 
I actually have tried that config too. My switch doesn't support isl, that is why I am using dot1q. Also the 4000 series uses Cat OS, so the commands for the switch you used would not work. I do see your point though. I have set-up intervlan routing before with ISL but the ios on the router was a newer version that allowed the command "encapsulation dot1q 1 native" command. With the ios I am using it wont allow to use the "native" part of the command, and my router doesn't have enough flash to upgrade. I am using secondary commands because there is more than one subnet on a vlan, so they need a default gateway.
 
You can either use on the router side:

encapsulation dot1Q 1 native (since 12.1(3)T)

or

In the earlier Cisco IOS versions, it is important not to configure VLAN1 interface as a sub-interface. The router then expects a tag dot1q frame on VLAN1 and the switch is not expecting a tag on VLAN1. As a result, no traffic will pass between VLAN1 on the switch and the router


 
Anyone know where I can get a lab for a CCNA class for configuring router on a stick? I have 4 Catalyst 2600 routers, a Catalyst 2601 , and a pair of Catalyst 2950 switches, and lotsa ethernet cabling.
 
Status
Not open for further replies.

Part and Inventory Search

Sponsor

Back
Top