Assigns VLAN 10 to this subinterface. This subinterface uses the 802.1Q trunking protocol.

Router(config-subif)#ip address 192.168.10.1 255.255.255.0

Assigns IP address and netmask.

Router(config-subif)#exit

Returns to interface configuration mode.

Router(config-if)#exit

Returns to global configuration mode.

Router(config)#

NOTE

The subnets of the VLANs are directly connected to the router. Routing between these subnets does not require a dynamic routing protocol. In a more complex topology, these routes need to either be advertised with whatever dynamic routing protocol is used, or be redistributed into whatever dynamic routing protocol is used.

NOTE

Routes to the subnets associated with these VLANs appear in the routing table as directly connected networks.