Skip to content

Commit

Permalink
Enh appneta#357 archive QuickTX
Browse files Browse the repository at this point in the history
  • Loading branch information
fklassen committed Apr 13, 2017
1 parent 1189811 commit d51de62
Show file tree
Hide file tree
Showing 34 changed files with 24 additions and 3,086 deletions.
42 changes: 1 addition & 41 deletions INSTALL
Original file line number Diff line number Diff line change
Expand Up @@ -81,47 +81,7 @@ The simplest way to compile this package is:
How to make Tcpreplay go fast
=============================

1) Quick TX
--------
There are two ways to add modules which will make Tcpreplay fast. On
Linux and BSD you can separately install netmap (see instructions below).
Note that netmap is disruptive to the network during a Tcpreplay test.
Specifically the network interface is completely bypassed when netmap
is active. A simpler and safer solution is Quick TX (available only
for Linux). Quick TX ships with Tcpreplay as of version 4.1.

Quick TX allows Tcpreplay to bypass the kernel network stack and write
directly to the network driver. Doing so allows up to wire-rate
transmissions (tested up to 10Gbps). Unlike netmap, it does not bypass
the network stack during Tcpreplay transmission. Also, you do not have
to download kernel source code to build it. By default Quick TX is built
and installed automatically.

If you would like to have Quick TX installed, do the following:

./configure --enable-quick-tx
make
sudo make install

To ensure the module is intalled, run 'lsmod' and look for 'quick_tx'.
To uninstall the module, uninstall tcpreplay:

sudo make uninstall

You can build Quick TX for a different kernel version if the sources
or headers are installed on your Linux distribution, e.g.

./configure --enable-quick-tx --with-kernel=/lib/modules/2.6.32-66-generic/build
make
sudo make install

To use the Quick TX module, run tcpreplay with interface names prefixed
with 'qtx:', e.g.

tcpreplay -i qtx:eth0 -Kt bigFlows.pcap


2) netmap
1) netmap
------
This feature will detect netmap capable network drivers on Linux and
BSD systems. If detected, the network driver is bypassed for the
Expand Down
18 changes: 3 additions & 15 deletions Makefile.am
Original file line number Diff line number Diff line change
Expand Up @@ -2,12 +2,12 @@
ACLOCAL_AMFLAGS = -I m4 -I libopts/m4

if NEED_LIBOPTS
SUBDIRS = $(KERNEL_DIR) scripts lib $(LIBOPTS_DIR) src
SUBDIRS = scripts lib $(LIBOPTS_DIR) src
else
SUBDIRS = $(KERNEL_DIR) scripts lib src
SUBDIRS = scripts lib src
endif

DIST_SUBDIRS = scripts lib libopts src docs test $(KERNEL_DIR)
DIST_SUBDIRS = scripts lib libopts src docs test
.PHONY: manpages docs test man2html


Expand Down Expand Up @@ -53,18 +53,6 @@ doxygen: version
ncc:
CC=ncc make

LINUX_MODULE_DIR = $(top_builddir)/kernel

kernel:
echo Making Linux quick_tx module in $(LINUX_MODULE_DIR)
cd $(LINUX_MODULE_DIR) && make


LINUX_MODULE_EXAMPLE_DIR = $(top_builddir)/kernel/linux/example
kernel_example:
echo Making Linux quick_tx sample program in $(LINUX_MODULE_EXAMPLE_DIR)
cd $(LINUX_MODULE_EXAMPLE_DIR) && make all

MOSTLYCLEANFILES = tcpreplay.spec *~

DISTCLEANFILES = .tm_project.cache stamp-h1 *.tar.*
Expand Down
21 changes: 0 additions & 21 deletions README.md
Original file line number Diff line number Diff line change
Expand Up @@ -74,28 +74,7 @@ Simple directions for Unix users:
make
sudo make install
```
Build Quick TX feature
----------------------
Quick TX allows Tcpreplay to bypass the kernel network stack and write
directly to the network driver. Doing so allows up to wire-rate
transmissions (tested up to 10Gbps). For detailed installation information
see INSTALL.

**NOTE:** This feature still an experimental and may not work with every
kernel version or with every network driver.

If you would like to have Quick TX installed, do the following:
```
./configure --enable-quick-tx
make
sudo make install
```
To use the Quick TX module, run tcpreplay with interface names prefixed
with 'qtx:', e.g.
```
tcpreplay -i qtx:eth0
```

Build netmap feature
--------------------
This feature will detect [netmap](http://info.iet.unipi.it/~luigi/netmap/)
Expand Down
71 changes: 1 addition & 70 deletions configure.ac
Original file line number Diff line number Diff line change
Expand Up @@ -4,7 +4,7 @@ dnl $Id$
AC_PREREQ([2.69])

dnl Set version info here!
AC_INIT([tcpreplay],[4.2.3-beta1],
AC_INIT([tcpreplay],[4.2.3],
[https://github.com/appneta/tcpreplay/issues],
[tcpreplay],
[http://tcpreplay.sourceforge.net/])
Expand Down Expand Up @@ -1393,67 +1393,6 @@ if test $have_bpf = yes ; then
[Do we have BPF device support?])
fi

dnl ##################################################
dnl # Check for Linux kernel support
dnl ##################################################
AC_PATH_KERNEL_SOURCE

dnl * Allow disable of Quick TX module
disable_quick_tx=yes
AC_ARG_ENABLE(quick-tx,
[ --enable-quick-tx Enable building Quick TX kernel module],
[ disable_quick_tx="no" ],
[ kerneldir=])

dnl * Compile Quick TX
KERNEL_DIR=
QUICK_TX_EXAMPLE_DIR=
moduledir=
kerneluname=
enable_sandboxed=
have_linux_quick_tx=no
if test x${disable_quick_tx} != xyes; then
if test x${no_kernel} != xyes; then
have_linux_quick_tx=yes
OLDCFLAGS="${OLDCFLAGS} -I../kernel/linux/include -I../../kernel/linux/include"
KERNEL_DIR='kernel'
AC_DEFINE([HAVE_QUICK_TX], [1],
[Do we have quick TX module support?])
fi
AC_SUBST(KERNEL_DIR)

dnl * Set destination directory for kernel modules

if test x${kerneluname} = x ; then
kerneluname=$(uname -r)
fi
default_moduledir=/lib/modules/${kerneluname}/misc
AC_ARG_WITH(moduledir,
[ --with-moduledir=DIR Install kernel modules in DIR (/lib/modules/${kerneluname}/misc)],
moduledir=${withval},
moduledir=${default_moduledir})
AC_SUBST(moduledir)
AC_SUBST(kerneluname)

dnl * Allow kernel example
AC_ARG_ENABLE(quick-tx-example,
[ --enable-quick-tx-example Build Quick TX kernel module example],
[ enable_tx_example="${enableval}" ],
[ enable_tx_example="no"])
if test x$enable_tx_example = xyes; then
QUICK_TX_EXAMPLE_DIR=example
fi
AC_SUBST(QUICK_TX_EXAMPLE_DIR)

dnl * Allow kernel sandbox mode (prevent depmod execution)
AC_ARG_ENABLE(sandboxed,
[ --enable-sandboxed Don't install anything to the kernel module directories],
[ enable_sandboxed="${enableval}" ],
[ enable_sandboxed="no"])
fi

AM_CONDITIONAL(SANDBOXED, test x$enable_sandboxed = xyes)

dnl ##################################################
dnl # Check for libdnet, but only if not Cygwin!
dnl ##################################################
Expand Down Expand Up @@ -1894,13 +1833,6 @@ AC_CONFIG_FILES([Makefile
test/config
scripts/Makefile])

if test x$have_linux_quick_tx = xyes; then
AC_CONFIG_FILES([kernel/Makefile
kernel/linux/Makefile
kernel/linux/example/Makefile
kernel/linux/quick_tx/Makefile])
fi

AC_OUTPUT

# Configuration results
Expand All @@ -1927,7 +1859,6 @@ libdnet: ${have_libdnet}
pcap_inject: ${have_pcap_inject}
pcap_sendpacket: ${have_pcap_sendpacket} **
pcap_netmap ${have_pcap_netmap}
Linux Quick TX: ${have_linux_quick_tx} ${kerneldir}
Linux/BSD netmap: ${have_netmap}
Tuntap device support: ${have_tuntap}

Expand Down
4 changes: 3 additions & 1 deletion docs/CHANGELOG
Original file line number Diff line number Diff line change
@@ -1,8 +1,10 @@
04/12/2017 Version 4.2.3-beta1
- Archive (remove) QuickTX until maintainer found (#357)
- Ubuntu precise 32bit_build (#356)

03/08/2017 Version 4.2.2
- Missing symbol pcap_version on macOS 10.12.4 (#353)
- Archive (remove) QuickTX (#357)
- Missing symbol pcap_version on macOS 10.12.4 (#356)

03/23/2017 Version 4.2.1
- Fix reporting of rates < 1Mbps (#348)
Expand Down
42 changes: 1 addition & 41 deletions docs/INSTALL
Original file line number Diff line number Diff line change
Expand Up @@ -81,47 +81,7 @@ The simplest way to compile this package is:
How to make Tcpreplay go fast
=============================

1) Quick TX
--------
There are two ways to add modules which will make Tcpreplay fast. On
Linux and BSD you can separately install netmap (see instructions below).
Note that netmap is disruptive to the network during a Tcpreplay test.
Specifically the network interface is completely bypassed when netmap
is active. A simpler and safer solution is Quick TX (available only
for Linux). Quick TX ships with Tcpreplay as of version 4.1.

Quick TX allows Tcpreplay to bypass the kernel network stack and write
directly to the network driver. Doing so allows up to wire-rate
transmissions (tested up to 10Gbps). Unlike netmap, it does not bypass
the network stack during Tcpreplay transmission. Also, you do not have
to download kernel source code to build it. By default Quick TX is built
and installed automatically.

If you would like to have Quick TX installed, do the following:

./configure --enable-quick-tx
make
sudo make install

To ensure the module is intalled, run 'lsmod' and look for 'quick_tx'.
To uninstall the module, uninstall tcpreplay:

sudo make uninstall

You can build Quick TX for a different kernel version if the sources
or headers are installed on your Linux distribution, e.g.

./configure --enable-quick-tx --with-kernel=/lib/modules/2.6.32-66-generic/build
make
sudo make install

To use the Quick TX module, run tcpreplay with interface names prefixed
with 'qtx:', e.g.

tcpreplay -i qtx:eth0 -Kt bigFlows.pcap


2) netmap
1) netmap
------
This feature will detect netmap capable network drivers on Linux and
BSD systems. If detected, the network driver is bypassed for the
Expand Down
7 changes: 0 additions & 7 deletions kernel/Makefile.am

This file was deleted.

9 changes: 0 additions & 9 deletions kernel/linux/Makefile.am

This file was deleted.

74 changes: 0 additions & 74 deletions kernel/linux/example/.cproject

This file was deleted.

28 changes: 0 additions & 28 deletions kernel/linux/example/.project

This file was deleted.

Loading

0 comments on commit d51de62

Please sign in to comment.