cancel
Showing results for 
Search instead for 
Did you mean: 
cancel
41682
Views
28
Helpful
6
Replies

Cisco 1921 router - Trunk and vlan interface

hallvard.solem
Level 1
Level 1

Hello!

We have some locations in our WAN with cisco 1712 routers that we want to replace.
I have now bought a cisco 1921 router for test, to see if this can replace the old routers.


While testing the 1921 I have ran into some problems which I hope someone can help me with.

Problem 1:

The 1912 router has two gigabit interfaces. The plan is to connect gi0/0 to the ISP WAN, and gi0/1 to the local network (a cisco 2960 switch) with a trunkport.
On the 1712 the trunk config on the LAN-interface looks like this:

interface fa1
switchport trunk allowed vlan 1,2,3
switchport mode trunk

..but on the 1921 router the "switchport" command doesnt seem to exist.
If I connect a switch with trunk-configuration to this port, the port comes up and seems allright, but im not sure if this is the correct way to do it?

Problem 2:

On the 1712 we use vlan interfaces. These interfaces are used for switch management, and as default gateway in the LAN. The config of one of the vlan interface looks like this:

interface Vlan2
description HR
ip vrf forwarding HR
ip address 10.20.26.1 255.255.255.0

..but on the 1921 router im not able to create a vlan interface with the "interface vlan" command, it does not exist.


Is this router not the right one for this use, or am I just missing the correct commands?


I have attached a simple network-drawing and a "sh version" from both routers.

I really hope someone can help me with this one!

3 Accepted Solutions

Accepted Solutions

p.mcgowan
Level 3
Level 3

the switchport command will not work on a router, you will need to use sub-interfaces

e.g

conf t

interface g0/1

no ip address

!

interface g0/1.1

encapsulation dot1q 1

ip address 1.1.1.1 255.255.255.0

!

interface g0/1.2

encapsulation dot1q 2

ip address 2.2.2.2 255.255.255.0

!

interface g0/1.3

encapsulation dot1q 3

ip address 3.3.3.3 255.255.255.0

!

obvously replace IP addresses with address range to suit your network.

View solution in original post

I would like to make explicit something that the previous posts talk around but never clearly identify. The original poster clearly has a switch module installed on the old router. It is not clear that there is a switch module installed in the new router.

If the old router does have a switch module then there are two potential solutions:

- make sure that the switch is configured with a trunk port, connect the switch trunk port to the router interface, and configure subinterfaces on the router interface to match the vlans on the trunk. (the solution in the first response)

- install a switch module and configure the switch ports and vlans to match the old setup. (the solution in the second response)

Both solutions should work and the original poster just needs to decide which solution works better for him. (note that if there are other things connected to the switch ports in the old router then perhaps using the switch module on the new router will be a more smooth transition)

HTH

Rick

HTH

Rick

View solution in original post

sylvain.munaut
Level 1
Level 1

That's something I was surprising to me as well when working with different Cisco models.

You can have several type of "Ports" on a switch.

- "Real indepedent ports" (no idea of the real name for them)

  They're completely separate ethernet ports with not relation to one another. That's what the 1921 has for Gi0/0 Gi0/1.

  On them you can use subinterface ( the .1 .2 .3 ) that allow among other things to put VLAN in there.

- "switchports"

  They're ports that are part of a switch module. You can configure those port but you have to keep in mind they're all part of a switch and are not as flexible. You can't for example assign IP to them (AFAIK), but you can place them in Vlans and such.

  But then to configure Layer 3 interfaces, it's not done "per port", but it's done using "software virtual interfaces" that represent the IP of the router "inside" the vlan. Those are the "Vlan X" interfaces you had.

View solution in original post

6 Replies 6

p.mcgowan
Level 3
Level 3

the switchport command will not work on a router, you will need to use sub-interfaces

e.g

conf t

interface g0/1

no ip address

!

interface g0/1.1

encapsulation dot1q 1

ip address 1.1.1.1 255.255.255.0

!

interface g0/1.2

encapsulation dot1q 2

ip address 2.2.2.2 255.255.255.0

!

interface g0/1.3

encapsulation dot1q 3

ip address 3.3.3.3 255.255.255.0

!

obvously replace IP addresses with address range to suit your network.

Ok, so using sub-interfaces on this interface will resolve both my problems?

In the old config I also used this command:

"ip radius source-interface vlan1"

Will the command

"ip radius source-interface gigabitethernet0/1.1" replace this command?

SunilKhanna
Level 1
Level 1
Hi,

You will need an ESW module.

The following Cisco EtherSwitch service modules provide Cisco  modular access routers

the ability to stack Cisco EtherSwitch service modules as  Layer 2 switches using

Cisco StackWise technology.

•NME-16ES-1G •NME-16ES-1G-P •ME-X-23ES-1G •ME-X-23ES-1G-P •ME-XD-48ES-2S-P •NME-XD-24ES-1S-P

Please have a look at Cisco Etherswitch Service Modules.

Regards,

Sunil

If you think the post was helpful please rate the posting.



Regards, Sunil Khanna

I would like to make explicit something that the previous posts talk around but never clearly identify. The original poster clearly has a switch module installed on the old router. It is not clear that there is a switch module installed in the new router.

If the old router does have a switch module then there are two potential solutions:

- make sure that the switch is configured with a trunk port, connect the switch trunk port to the router interface, and configure subinterfaces on the router interface to match the vlans on the trunk. (the solution in the first response)

- install a switch module and configure the switch ports and vlans to match the old setup. (the solution in the second response)

Both solutions should work and the original poster just needs to decide which solution works better for him. (note that if there are other things connected to the switch ports in the old router then perhaps using the switch module on the new router will be a more smooth transition)

HTH

Rick

HTH

Rick

sylvain.munaut
Level 1
Level 1

That's something I was surprising to me as well when working with different Cisco models.

You can have several type of "Ports" on a switch.

- "Real indepedent ports" (no idea of the real name for them)

  They're completely separate ethernet ports with not relation to one another. That's what the 1921 has for Gi0/0 Gi0/1.

  On them you can use subinterface ( the .1 .2 .3 ) that allow among other things to put VLAN in there.

- "switchports"

  They're ports that are part of a switch module. You can configure those port but you have to keep in mind they're all part of a switch and are not as flexible. You can't for example assign IP to them (AFAIK), but you can place them in Vlans and such.

  But then to configure Layer 3 interfaces, it's not done "per port", but it's done using "software virtual interfaces" that represent the IP of the router "inside" the vlan. Those are the "Vlan X" interfaces you had.

Thanks for all good replies, I now have the info i needed.

Instaead of using a switchmodule like on the old routers, I will configure subinterfaces (router on a stick) on the "lan"-interface. I then dont need a switchport for trunk, and I dont need software virtual interfaces.

We dont use the switch-module on the 1712 routers for anything else than the trunk to the switch anyway, so I think the 1921 router with only two interfaces is just what we need, as long as it satisfy our requirements for cryptating traffic in one of the vlans. I will have to do some more testing on that.

Review Cisco Networking products for a $25 gift card