# data[].attributes.headline
HERE AN EXAMPLE .PKT (Cisco Packet Tracer)

# data[].attributes.subject
HERE AN EXAMPLE .PKT (Cisco Packet Tracer)

# data[].attributes.body
Now we’ll verify connectivity by pinging the subinterfaces from the switch:

Switch#ping 192.168.5.1

Type escape sequence to abort.
Sending 5, 100-byte ICMP Echos to 192.168.5.1, timeout is 2 seconds:
!!!!!
Success rate is 100 percent (5/5), round-trip min/avg/max = 1/2/8 ms

Switch#ping 192.168.10.1

Type escape sequence to abort.
Sending 5, 100-byte ICMP Echos to 192.168.10.1, timeout is 2 seconds:
!!!!!
Success rate is 100 percent (5/5), round-trip min/avg/max = 1/2/8 ms

Switch#ping 192.168.15.1

Type escape sequence to abort.
Sending 5, 100-byte ICMP Echos to 192.168.15.1, timeout is 2 seconds:
!!!!!
Success rate is 100 percent (5/5), round-trip min/avg/max = 1/2/8 ms

That’s it, we have a working router on a stick.

# data[].attributes.headline
                                                 Second Step: Now it's up to Router!

# data[].attributes.subject
                                                 Second Step: Now it's up to Router!

# data[].attributes.body
Router(config)#interface FastEthernet0/0
Router(config-if)#no ip address
Router(config-if)#interface FastEthernet0/0.5
Router(config-subif)#encapsulation dot1Q 5
Router(config-subif)#ip add 192.168.5.1 255.255.255.0
Router(config-subif)#interface FastEthernet0/0.10
Router(config-subif)#encapsulation dot1Q 10
Router(config-subif)#ip add 192.168.10.1 255.255.255.0
Router(config-subif)#interface FastEthernet0/0.15
Router(config-subif)#encapsulation dot1Q 15
Router(config-subif)#ip add 192.168.15.1 255.255.255.0

On the router, we go to the interface connected to the switch and make sure there is no IP address. Then we configure our subinterfaces with 802.1q and the appropriate VLAN. Then we give each subinterface an IP address. Now we can see all the subinterfaces are up:

Router#sh ip int b

Interface              IP-Address      OK? Method Status  Protocol
FastEthernet0/0        unassigned      YES NVRAM  up      up
FastEthernet0/0.5      192.168.5.1     YES manual up      up
FastEthernet0/0.10     192.168.10.1    YES manual up      up
FastEthernet0/0.15     192.168.15.1    YES manual up      up

# data[].attributes.body
Switch(config)#vlan 5
Switch(config-vlan)#exit
Switch(config)#vlan 10
Switch(config-vlan)#exit
Switch(config)#vlan 15
Switch(config-vlan)#exit
Switch(config)#interface FastEthernet0/1
Switch(config-if)#switchport trunk encapsulation dot1q
Switch(config-if)#switchport mode trunk

The switch config is pretty basic, we create VLANs 5, 10 and 15, then we make a trunk port to the router.

# data[].attributes.body
HOW DOES WE CAN CREATE ROUTER ON A STICK?

# data[].attributes.body
Router on a stick is a way to communicate between VLANs. There comes a time where your VLANs may need to communicate, for example, let say you have all your user computers on one VLAN and a file server on another. In order for your users to access files from that server there must be some kind of ‘interlan routing’ and ‘router on a stick’ is one way we can do this.