This repository consists of various small-scale tests intended to help inform experimentation about pinned memory usage in kernel bypass networking stacks. Below, each individual experiment's purpose and how to run it is outlined:
The intended purpose of this benchmark is to measure how long it takes to register memory regions. To run the benchmark, run the following:
Install the following dependencies in the listed order:
Numa:
sudo apt-get update && sudo apt-get upgrade
sudo apt-get install libnuma-dev
Mellanox Driver:
wget https://www.mellanox.com/downloads/ofed/MLNX_OFED-<version>/MLNX_OFED_LINUX-<version>-<distribution>-<arch>.tgz Example: wget https://www.mellanox.com/downloads/ofed/MLNX_OFED-5.0-2.1.8.0/MLNX_OFED_LINUX-5.0-2.1.8.0-ubuntu18.04-x86_64.tgz
tar -xvf MLNX_OFED_LINUX-<version>-<distribution>-<arch>.tgz
cd MLNX_OFED_LINUX-<version>-<distribution>-<arch>
sudo ./mlnxofedinstall --upstream-libs --dpdk
- Restart the driver:
sudo /etc/init.d/openibd restart
Enable HugePages:
- Run
sudo /path/to/nicbenchmarks/dpdk/usertools/dpdk-setup.sh
- Select #49 (or #6, depends on the script)
- Enter 2048
- Quit
DPDK:
git clone https://github.com/DPDK/dpdk.git
cd ./dpdk/
git checkout v19.11
git apply ../mlx5_registration.patch
make defconfig
make -j
To compile the program, execute the following steps:
- Export RTE_TARGET:
export RTE_TARGET=build
- Export RTE_SDK:
export RTE_SDK=/proj/demeter-PG0/murray22/nicbenchmarks/dpdk
- Run
make
To run the program, follow these steps:
- Run
ethtool -i [interface]
and take note of the bus-info - Server:
sudo build/register -c 0xff -n 4 -w [bus-info value found in #5] --proc-type=auto -- --mode=SERVER --ip=[ip of the machine]
a. Example Server command:sudo build/register -c 0xff -n 4 -w 0000:41:00.0 --proc-type=auto -- --mode=SERVER --ip=192.168.1.1 --num_mbufs=2
- Client:
sudo build/register -c 0xff -n 4 -w [bus-info value found in #5] --proc-type=auto -- --mode=CLIENT -server_ip=[ip of the server] --ip=[ip of the machine] --server_mac=[mac address printed out by the server] --rate=120000 --message_size=1024 --time=10
This folder contains simulation code which runs over a twitter trace [CITE TRACE] and observes various statistics related to number of pages "pinned".