How to configure GRE Tunnel on Cisco IOS Router

Hello Pinki

The advantages provided by GRE tunnelling (or any kind of network tunnelling) is that it allows us to interconnect two remote sites over a third network as if those remote sites are directly connected to each other. So let’s say you have two branch offices, one in one city and one in another. You have a subnet of 192.168.1.0/24 at the first office and 192.168.2.0/24 at the second office. Those two offices will never be able to communicate directly with each other over the Internet, because the Internet uses its own IP address ranges and it does not allow the use of private IP addresses to be routed using static and dynamic routing.

However, you can create a GRE tunnel between the edge routers at each branch office. The packets addressed in the 192.168.1.0/24 and 192.168.2.0/24 address ranges will then be tunnelled or encapsulated into IP packets that can be routed over the Internet. Once they arrive at the other edge router, they will be decapsulated and sent onto the local network. In this way, hosts at each branch office will think that the two edge routers are directly connected to each other, allowing you to enable communication between the two offices as if they were really directly connected to each other.

So in summary, a tunnel will allow you to route your private packets over a public or third party network such as the Internet, in such a way so that your networks function as if they are directly connected to each other.

I hope this has been helpful!

Laz

2 Likes