Wednesday, March 18, 2009

Creating dummy network interfaces in Linux

I'm working on a lab recreate where I have to replay traffic from a sniffer capture.
I need 2 interfaces, one ethernet and one dummy interface. After a few hours searching the web I found my answer on how to setup a dummy interface.


To create the dummy interfaces, make sure the kernel is compiled with the CONFIG_DUMMY option.

In the 2.6.27 kernel this is found in Device Drivers -> Network Drivers section

To create the dummy interface after the dummy module is installed issue:
modprobe dummy
If you need 3 fake interfaces, the command is
modprobe dummy numdummies=3

Now I can assign traffic to go out dummy0 interface..