Creating a subinterface - Help

Answered Question
Apr 2nd, 2009
User Badges:


I have a router doing some routing this is connected to an access switch port, I would like to add a subinterface to it can someone help me with setting it up as I've never done this before.

Here are the details


interface FastEthernet0/0

ip address

duplex auto

speed auto

standby 32 ip

standby 32 priority 110

standby 32 preempt

standby 32 track FastEthernet0/1 30



interface GigabitEthernet2/0/48

switchport mode access

spanning-tree portfast.

I want to create a fa0/0.0 interface, is that possible on a 2800 router? When I initially created it I lost connection to the router, here's what I added:

int fa 0/0.0

ip address


Could I have lost connection to the router becuase the switch is set as access mode instead of trunk?

After a short while I tried the same thing above but this time just did the below:

int fa 0/0.0

Description Test interface


But when I run "show run" I can't see this interface anywhere it only shows me fa0/0 and fa0/1. Any thoughts?

Also I then thought let me add the address "" again but this time the router says "Bad mask /24 for address". Any thoughts on this?

Thanks in advance


  • 1
  • 2
  • 3
  • 4
  • 5
Overall Rating: 5 (1 ratings)
Giuseppe Larosa Thu, 04/02/2009 - 04:29
User Badges:
  • Super Silver, 17500 points or more
  • Hall of Fame,

    Founding Member

Hello Dan,

use the following examples adapt to your scenario

router side:

use two subinterfaces with different vlan-id and remove ip address from main interface

int f0/0

no ip address

int f0/0.10

enc dot1q 10

ip address

int f0/0.20

enc dot1q 20

ip address

switch side:

int f0/15


swithcport trunk enc dot1q

swithcport mode trunk

switchport trunk allowed vlan 10,20

>> he address "" again but this time the router says "Bad mask /24 for address". Any thoughts on this?

this is the subnet address and cannot be used for any host including a router interface (all 0 in host portion)

Hope to help


dan_track Thu, 04/02/2009 - 05:07
User Badges:


Thank you all for this. Can someone suggest how I can do this remotely? I.e the exact process to take without losing connection?



Jon Marshall Thu, 04/02/2009 - 05:27
User Badges:
  • Super Blue, 32500 points or more
  • Hall of Fame,

    Founding Member

  • Cisco Designated VIP,

    2017 LAN, WAN


You need to access the router through another interface ie. not fa0/0

If you can do thiss log onto the switch and change the port to a trunk port first. Be aware that as soon as you do this you will lose connectivity between the switch and the router. Then configure fa0/0 interface as described and it should start communicating again.


dan_track Thu, 04/02/2009 - 05:36
User Badges:

Ahh, so that's a problem as I onlyt have one link to this site and it's this link that's going to be dropped. I'll find a way round somehow. Appreciate the info though.




This Discussion