Skip to content

Commit

Permalink
Move non Machnet apps out of src/apps to src/tools
Browse files Browse the repository at this point in the history
  • Loading branch information
anujkaliaiitd committed Jul 9, 2024
1 parent ecd6dfd commit d51fbf2
Show file tree
Hide file tree
Showing 14 changed files with 13 additions and 14 deletions.
1 change: 1 addition & 0 deletions src/CMakeLists.txt
Original file line number Diff line number Diff line change
Expand Up @@ -34,6 +34,7 @@ if(LIBDPDK_STATIC_FOUND)
enable_testing()
add_subdirectory(tests)
add_subdirectory(apps)
add_subdirectory(tools)
else()
message(WARNING "DPDK not found and RTE_SDK is not set. Building only msg_gen.")
add_subdirectory(apps/msg_gen)
Expand Down
4 changes: 0 additions & 4 deletions src/apps/CMakeLists.txt
Original file line number Diff line number Diff line change
@@ -1,9 +1,5 @@
include_directories(../modules)

add_subdirectory(pktgen)
add_subdirectory(machnet)
add_subdirectory(msg_gen)
add_subdirectory(ping)
add_subdirectory(rocksdb_server)
add_subdirectory(jring_perf)
add_subdirectory(jring2_perf)
3 changes: 0 additions & 3 deletions src/apps/hello_world/CMakeLists.txt

This file was deleted.

6 changes: 6 additions & 0 deletions src/tools/CMakeLists.txt
Original file line number Diff line number Diff line change
@@ -0,0 +1,6 @@
include_directories(../modules)

add_subdirectory(pktgen)
add_subdirectory(ping)
add_subdirectory(jring_perf)
add_subdirectory(jring2_perf)
File renamed without changes.
File renamed without changes.
File renamed without changes.
File renamed without changes.
File renamed without changes.
3 changes: 1 addition & 2 deletions src/apps/ping/README.md → src/tools/ping/README.md
Original file line number Diff line number Diff line change
Expand Up @@ -33,9 +33,8 @@ Other legal configuration options are safely ignored (for example, `engine_threa

### Running

From `${REPOROOT}/build/src/apps/ping`:
From `${REPOROOT}/build/src/tools/ping`:

```bash
sudo GLOG_logtostderr=1 ./ping --remote_ip 10.0.0.1
```
**Attention**: Currently the utility expects the remote host to be specified with its IP address. This will be fixed in the future to support hostnames as well.
File renamed without changes.
File renamed without changes.
10 changes: 5 additions & 5 deletions src/apps/pktgen/README.md → src/tools/pktgen/README.md
Original file line number Diff line number Diff line change
Expand Up @@ -30,7 +30,7 @@ When running in this mode the application is actively generating packets. It als
# Send packets to a remote host.
REMOTE_IP="10.0.0.254"
cd ${REPOROOT}/build/
sudo GLOG_logtostderr=1 ./src/apps/pktgen/pktgen --remote_ip $REMOTE_IP --active-generator
sudo GLOG_logtostderr=1 ./src/tools/pktgen/pktgen --remote_ip $REMOTE_IP --active-generator

# If ran from a different directory, you may need to specify the path to the config file:
sudo GLOG_logtostderr=1 ./pktgen --config_file ${REPOROOT}/src/apps/machnet/config.json --remote_ip $REMOTE_IP --active-generator
Expand All @@ -41,7 +41,7 @@ The above command will run the `pktgen` application to a remote machine with IP

```bash
# From ${REPOROOT}/build/
sudo GLOG_logtostderr=1 ./src/apps/pktgen/pktgen --remote_ip $REMOTE_IP --active-generator --pkt_size 1500
sudo GLOG_logtostderr=1 ./src/tools/pktgen/pktgen --remote_ip $REMOTE_IP --active-generator --pkt_size 1500
```

### Running in ping mode (RTT measurement)
Expand All @@ -53,7 +53,7 @@ The `pktgen` is collecting roundtrip time measurements. When stopping the apppli
```bash
REMOTE_IP="10.0.0.254"
# From ${REPOROOT}/build/
sudo GLOG_logtostderr=1 ./src/apps/pktgen/pktgen --remote_ip $REMOTE_IP --ping
sudo GLOG_logtostderr=1 ./src/tools/pktgen/pktgen --remote_ip $REMOTE_IP --ping
```

If you want RTT measurements printed every 1 second, add option `--v=1` to the previous invocation.
Expand All @@ -66,12 +66,12 @@ To save the samples in a log file add option: `--rtt_log path/to/file`.
When running in this mode the application is only bouncing packets to the remote host. It does not generate any other packets.


From `${REPOROOT}/build/src/apps/pktgen`:
From `${REPOROOT}/build/src/tools/pktgen`:

```bash
REMOTE_IP="10.0.0.254"
# From ${REPOROOT}/build/
sudo GLOG_logtostderr=1 ./src/apps/pktgen/pktgen
sudo GLOG_logtostderr=1 ./src/tools/pktgen/pktgen
```

The above command will run the `pktgen` application in **passive** mode on local machine. It will send all received packets to the originating remote server.
File renamed without changes.

0 comments on commit d51fbf2

Please sign in to comment.