![configure router on a stick configure router on a stick](https://ciscoccnajourney.files.wordpress.com/2014/01/routeronastick.gif)
When the switch forwards packet of one VLAN to another, it inserts a VLAN into the Ethernet header. NOTE : Here encapsulation type dot1q is used for frame tagging between the 2 different VLAN.
![configure router on a stick configure router on a stick](https://www.routerfreak.com/wp-content/uploads/ROAS-figure-2.jpg)
Now, we will make sub-interface of fa0/0 as fa0/0.1 and fa0/0.2 and assign IP address as 192.168.1.1/24 and 192.168.2.1/24 respectively on router’s ports. Then router will perform Inter VLAN Routing and the VLANs will be communicate with each other.įirst we will assign IP address to the host PC1 as 192.168.1.10/24, Server 192.168.1.20/24 and the other host PC2 will have IP address 192.168.2.10/24 manually. The router’s interface is divided into 2 sub-interfaces (as there are 2 different VLANs) which will acts as a default gateway to their respective VLANs. 2 different VLANs have been created on the switch. Here is a topology in which there is a router and a switch and some end hosts. The Router’s interface is divided into sub-interfaces, which acts as a default gateway to their respective VLANs. When the Inter VLAN Routing is done through Router the it is known as Router on a stick. Inter VLAN Routing can be achieved through a layer-3 device i.e.
![configure router on a stick configure router on a stick](https://slidetodoc.com/presentation_image/43b1008c7ef632fc5ed5ff411bb8d7b0/image-45.jpg)
Inter VLAN routing is a process in which we make different virtual LANs to communicate with each other irrespective of where the VLANs are present (on same switch or different switch). If we want to make these virtual LANs communicate with each other, a concept of Inter VLAN Routing is used. Switch doesn’t forward packets across different VLANs by itself. VLAN is a partitioned broadcast domain from a single broadcast domain. Switches divide broadcast domain through VLAN (Virtual LAN).