cancel
Showing results for 
Search instead for 
Did you mean: 
cancel
21239
Views
1
Helpful
10
Replies

How to assign a VLAN to a router port?

lostngone
Level 1
Level 1

A little background.

We have small remote sites with Cisco 2901 routers all with 8 port D8ESGP(ESW) in them and they all use T1 interfaces for their WAN up-links.

I want to use the 2 routed ports on the device as access ports at some of the sites that have a need for 9/10 devices. I want the additional devices on the same vlan/subnet as the other 8 devices.

The only way I can think of doing this is making a single sub interface on the routed port and use 802.1q encapsulation assign that vlan to the sub int but make it native so it doesn't have any tags.

There has to be a better/cleaner way of doing this?

Thank You

10 Replies 10

Hi

If your module supports, it could be:

Example:

vlan 10

interface vlan 10
ip add 10.10.10.1 255.255.255.0
No shut.


interface f1/0/1
switchport
switchport access vlan 10
switchport mode access
no shut

And connect it a switch. 

http://www.cisco.com/c/en/us/support/docs/interfaces-modules/network-modules/82288-es-mod-config.html

:-)




>> Marcar como útil o contestado, si la respuesta resolvió la duda, esto ayuda a futuras consultas de otros miembros de la comunidad. <<

The built in ports on the router will not take the "switchport" command.

Joseph W. Doherty
Hall of Fame
Hall of Fame

Not sure if 2901 supports IRB, and if it does, whether you could include the built-in routed ports in the same bridge group as your SVI's VLAN ports.  If it does, that would be a solution.

Attaching a link related to BVI

http://www.cisco.com/c/en/us/support/docs/lan-switching/integrated-routing-bridging-irb/200650-Understanding-Bridge-Virtual-Interface.html




>> Marcar como útil o contestado, si la respuesta resolvió la duda, esto ayuda a futuras consultas de otros miembros de la comunidad. <<

Thanks for all these ideas and thank you Julio for the link, unfortunately....

It looks like the EHWIC switch card doesn't support bridging. 

AKN-RTR(config)#interface GigabitEthernet0/1/0
AKN-RTR(config-if)#bridge-group 1
GigabitEthernet0/1/0 does not support bridging
AKN-RTR(config-if)#

You would not apply it under the physical module ports but under the SVI for the vlan and then under the physical inbuilt ports.

But I have never seen it used with more than two ports and never seen it used under an SVI so not sure it will work but worth a try.

Jon

opps, duh....

It took the commands and didn't complain I will have to test and see how if it actually works. 

Jon Marshall
Hall of Fame
Hall of Fame

So I'm assuming you already have an SVI configured for the module ports (as per Julio's configuration example) and you want to add the two inbuilt interfaces to the same vlan ?

If so you can't do that and your suggested solution wouldn't work as the interfaces would still be L3 which is not what you need.

You would be better to simply route between everything ie. connect the extra devices directly to the L3 interfaces and use a /30 subnet per host/interface but this is not an ideal solution.

There is no clean way to do what you want (as far as I know) unless you have a separate switch you can use but then you would not be needing the module.

Jon

Correct I have the SVI setup and all the ports on the switch ehwic assigned to it and I want to use the two ports on the router on the same vlan.

We only have a few sites that need an additional port over the 8. I just hate to have to buy external switches or setup a different subnet just for that additional device at these sites.  

Seem silly(to me at least) that on a router(L3) you can't easily make the ports behave as Layer 2. 

Unfortunately you can't change them.

You may want to consider Joe's suggestion although I'm not convinced it will work with your scenario and it is not a particularly clean solution either but it may be worth a look.

Jon

Getting Started

Find answers to your questions by entering keywords or phrases in the Search bar above. New here? Use these resources to familiarize yourself with the community:

Review Cisco Networking products for a $25 gift card