Using virtual Ethernet pair device

Posted by Benoit Papillault on Nov 1, 2009 in Linux |

I have been wondering what was virtual Ethernet pair Linux driver and how to use it. In fact, the principle is quite simple. As soon as you have created a pair of Ethernet like devices, each packet send at one side is received at the other side. Here is a quick tutorial on using it.
First, you need to load the kernel  module :

# modprobe veth

Next, you need to create the interfaces :

# ip link add type veth

You can also name the interfaces as well :

# ip link add name first0 type veth peer name second0

For more information, here is a more complete web site : http://lxc.sourceforge.net/network/configuration.php

 

http://lxc.sourceforge.net/network/configuration.php

Comments are closed.

© 2025 Blog de Benoit Papillault ! Theme : Laptop Geek - Réalisation : BenoitDuWeb - Mentions légales