MPS v3 Configuration File#

MPS v3 can load its full startup configuration from a TOML file with -a/--apply:

nvidia-cuda-mps-control -d -p 3 -a /path/to/config.toml

Configuration is applied once at startup; there is currently no persistence of subsequent CLI changes back to disk, so servers, namespaces, and partitions created after startup only exist for the lifetime of the daemon unless they are also added to the configuration file.

schema_version = "1.0"

[compute_policy]
timeslice            = "long"
timeslice_yield_level = 2

[servers.training]
allowed_devices          = "GPU-74d43ed3-cdf7-e667-3644-bf5b4f46ed65"
pinned_memory_limit      = "10G"
active_thread_percentage = "50"
client_priority          = "0"
uid                      = 1000
locality_domains         = false
timeslice_pct            = "50"

[servers.training.namespaces.high_priority]
pinned_memory_limit      = "5G"
active_thread_percentage = "25"
cgroup                   = "/sys/fs/cgroup/training"
cgroup_depth             = 1

[[servers.training.namespaces.high_priority.devices]]
uuid         = "GPU-74d43ed3-cdf7-e667-3644-bf5b4f46ed65"
sm_partition = "large"

[[servers.training.devices]]
uuid = "GPU-74d43ed3-cdf7-e667-3644-bf5b4f46ed65"

  [[servers.training.devices.sm_partitions]]
  name              = "large"
  chunks            = 4
  include_remainder = false
  shareable         = true
  max_chunks        = 6

[features.memacct]
enabled       = true
audit_log     = true
force_polling = false

[features.context-share]
enabled        = true
default_socket = "on"
  • [compute_policy] accepts timeslice (a string: "default", "short", "medium", or "long") and timeslice_yield_level (integer 1 or 2). When omitted, duration uses the device default and yield behavior is unchanged. These daemon-wide settings are applied before servers are created. Refer to Weighted Timeslicing for their interaction and update restrictions.

  • [servers.<name>] accepts allowed_devices, pinned_memory_limit, active_thread_percentage, client_priority, uid, locality_domains (boolean only), and timeslice_pct (0-100; omitted or 0 means unset). The example scales the long duration to 25 ms for server training.

  • [servers.<name>.namespaces.<name>] accepts pinned_memory_limit, active_thread_percentage, client_priority, cgroup, and cgroup_depth. cgroup is an absolute cgroup v2 path below /sys/fs/cgroup; omitted or "none" means unmapped. cgroup_depth requires a mapping and accepts 0-64; omitted means unbounded. See Cgroup Matching. A namespace named default refers to the server’s built-in default namespace rather than creating a new one. Cgroup mappings are not supported on that namespace.

  • [[servers.<name>.namespaces.<name>.devices]] requires uuid and sm_partition. The assignment names an SM partition defined on the same server and device. Each namespace can assign one partition per device.

  • [[servers.<name>.devices]] requires uuid. Optional sm_partition assigns a partition to the server’s default namespace; it does not assign it to custom namespaces. The table also optionally nests [[servers.<name>.devices.sm_partitions]] entries, each requiring name and chunks, with optional include_remainder (default false) and the load balancing keys shareable (boolean, default false), max_chunks (a non-negative integer or the string "unlimited"; 0 disables borrowing; a numeric value must be at least chunks). See SM Partition Load Balancing.

  • sm_partitions entries define partitions; sm_partition selects one for a namespace. The example defines the large partition and assigns it to high_priority. The default namespace has no SM partition assignment and retains the environment-variable fallback. Omit an assignment to use the environment-variable fallback; sm_partition = "none" is not accepted in TOML. See SM Partition Assignments for precedence and the CLI commands for changing or clearing an assignment.

  • [features.<name>] tables are read per-feature; see the Features section in MPS v3 Interface for the keys each feature accepts.

  • TOML keys use underscores; the equivalent CLI flags use dashes (for example, pinned_memory_limit in the file corresponds to --pinned-memory-limit on the command line).