Configuration Settings
Overview
TOML schema basics, units, and feature-gated keys.
Days simulations are configured using a single TOML file. The CLI entry point (src/main.rs) expects the path to that file as its only argument:
RUST_LOG=info cargo run -- configs/simple.tomlUnits and types
The most common conventions in the TOML schema:
- Time: seconds as floating point (
f64) unless otherwise noted. - Rates: bits per second (
port_rate,rate_gbps, …). - Sizes: bytes for traffic sizes, packet sizes, and most buffers.
- Topology node IDs: integers (
usize), used consistently across graph edges, hosts, paths, and endpoints.
Minimal example
This is a minimal, custom-topology run: one link, one packet-distribution flow.
seed = 1
duration = 2.0
threading = "single"
log_path = "./output/minimal"
edges = [[0, 1]]
hosts = [0, 1]
[switch]
port_rate = 1e9
capacity = 100
discipline = "FIFO"
drop = "TailDrop"
[[flow]]
flow_type = "PacketDistribution"
graph = [[0, 1]]
[flow.traffic]
initial_delay = 0.0
size = 10000
arr_dist = { type = "Uniform", low = 0.001, high = 0.001 }
pkt_size_dist = { type = "DiscreteUniform", low = 512, high = 512 }Sections at a glance
- General / runtime: /docs/configuration/logging
- Topology: /docs/configuration/topology
- Switches, schedulers, and drop/ECN: /docs/configuration/switches
- Flows and traffic: /docs/configuration/flows
- Collectives: /docs/configuration/collectives
- Optional L2/PFC: /docs/configuration/l2
Feature-gated configuration
Some config values are only valid when the binary is built with the right Cargo features:
link.mode = "Pfc"requires--features l2_pfcflow_type = "DCQCN"and[traffic.dcqcn]require--features dcqcn- Protocol event traces for the Lean checker:
dcqcn_events.csvrequires--features dcqcn,leanpfc_events.csvrequires--features l2_pfc,leancubic_events.csvrequires--features leandrr_events.csvrequires--features leanwfq_events.csvrequires--features lean
--features perf_statsenables internal performance statistics from thenexosimsimulation engine