Format of the ntpcap.ini File

libpcap Installation

IntelĀ® PAC
Napatech SmartNIC
Content Type
Software Installation Guide


The configuration file ntpcap.ini uses the INI file format.

The configuration file consists of a [Common] section and a section for each libpcap device. For each device section, a number of optional keys specify additional parameters.

Note: If a device is configured erroneously, it is not created. However, no error message is shown.


The syntax for defining one device is as shown below.

{'Ntpl'<n> '=' '"'<NTPL command>'"'}
'['<device name>']'
{'RX'<n> '=' '"'<NTPL command>'"'}
['StreamId' '=' <ID>]
['HBAllowance' '=' <percentage>]
['TX' '=' <port No.>]
['TXNumaNode' '=' <node No.>]
['TXMinHostBuffer' '=' <minimum buffer size>]
['NTInterface' '=' 'Segment' | 'Packet']
['WithCRC' '=' 'TRUE' | 'FALSE']


The semantics of ntpcap.ini is described below.

Key Description

A section which may hold NTPL commands for common use, for example NTPL macros and NTPL setup commands. If the [Common] section is present, then "Delete=All" is executed implicitly on entry. libpcap makes sure this is only executed once when multiple devices are opened. After all devices have been closed, opening any device will re-initiate the execution of the NTPL commands in the [Common] section.


Optional. Must be specified in the [Common] section.

<n> = 1..256, <n> must start at 1 and increment consecutively. The NTPL commands are loaded in this sequence.

<device name>

A user-defined libpcap device name. If the name clashes with an existing device name, this section of ntpcap.ini is ignored.

Note: Streams that are already created on the SmartNIC, for instance by using the ntpl tool, are automatically available for libpcap. They are named nt3g<x>, where <x> is the stream ID. To avoid naming clashes, do not use these device names in ntpcap.ini.

Optional. NTPL commands for setting up this libpcap device.

<n> = 1..256, <n> must start at 1 and increment consecutively. The NTPL commands are loaded in this sequence. A break in the sequence stops loading commands.

If at least Rx1, and optionally more NTPL commands, assigns or refers to the same single stream ID (not a range), the libpcap device is assigned to this stream ID. Make sure to use the same stream ID in these NTPL commands; otherwise this section of ntpcap.ini is ignored, and the libpcap device is not created.

If a stream with this stream ID has already been created on a SmartNIC, for instance by a previous section in ntpcap.ini or by using the ntpl tool, the NTPL commands are not loaded. Make sure to use a stream ID that is not already in use.

If no NTPL command assigns or refers to a single stream ID, use the key StreamID to assign an existing stream, created for instance in a previous section of ntpcap.ini or by using the ntpl tool.


Optional. Assigns the libpcap device to a stream ID. The stream must already have been created.

If set, Rx<n> NTPL commands are not searched for a stream ID.

Use the StreamID key if no NTPL commands assign or refer to a specific stream ID (see the load-balancing example in Examples of ntpcap.ini Files).

Use the StreamID key to assign the libpcap device to a stream created in a previous section of ntpcap.ini or, for instance, by using the ntpl tool (see the host buffer allowance example in Examples of ntpcap.ini Files).


Optional. Specifies the host buffer allowance in percent for this device. Range: 1..100. Default: 100.

All applications opening this libpcap device will have the same host buffer allowance value. Create more devices assigned to the same stream ID if different host buffer allowance values are needed.

See the host buffer allowance example in Examples of ntpcap.ini Files


Optional. If specified, determines the port used to transmit on. Default: No TX port is assigned.


Optional. Specifies from which NUMA node pool of host buffers the TX buffer is taken. Only relevant if a TX port is specified. Default: 0.


Optional. Specifies the minimum size in MB of the TX host buffer needed.


Optional. Selects between segment-based interface and packet-based interface. Default: Segment.

Segment-based interface is faster and supports the PCAP descriptor (PacketDescriptor=PCAP in ntservice.ini). However, segment-based interface does not support merging of packets between SmartNICs.

Packet-based interface supports merging of packets between SmartNICs, but does not support the PCAP descriptor.


Optional. If set to TRUE, frames are delivered with CRC. Default: FALSE, that is frames are delivered without CRC.