On this article we will discuss about bridged network interface. Why we need this kind of facilities or why we use it. First of all we need this facility for various reasons. Depends on what we will design as a service. Before launching a service we must need to know what we are developing and what will the network path for this. If we require a bridged interface we can do it with one or more interfaces.
Suppose we need to put an outer IP to an internal IP. It is hard to make it work by directly putting the IP in internal network. So we have to pass this IP through another interface which has access to the external network. Now we have to make the interface bridged which have access to the outer network.
The basic use of bridged interface is to provide access to another network where a desired network cannot reach.
Now what are the most common uses for this technology!
This technology mostly used in case of KVM or other virtualization platform. Also this is a common technology used on cloud platform.
Let me describe a little about the process before showing the procedure. For creating this network interface we need to decide a device name, the device type will be bridge; it will have a MAC address for the hardware.
Let’s start the detailed work from here. First, run the below command to create a device interface.
# vi /etc/sysconfig/network-scripts/ifcfg-br00
We will get a blank editor on our terminal. Here we have to write the blow lines.
Now save and exit this file. Once this file is created properly, run the below command.
# systemctl restart network
After this command we have to check the network interfaces. For that we have to run the below command.
Here we will find a new interface named br00.
After that we have to configure the interface through which our desired connection will be obtained to our internal network. For that we have to configure the physical device. So that we will open the Ethernet interface and add a line at the end of the lines.
# vi /etc/sysconfig/network-scripts/ifcfg-enp0s3
Now we will see the below content in that file.
Now at the end of the file we have to add the below line.
Also if we don’t use the physical interface for other networking reasons then we can remove the ip address from the interface.
Now once again we have to restart the network service and check the IP addresses once again. For that we have to run the below commands.
#systemctl restart network
Once the whole process is done, we can configure our internal network interface to access outer network for the desired connection. We just have to configure that by putting into the bridge interface.