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]acceptstimeslice(a string:"default","short","medium", or"long") andtimeslice_yield_level(integer1or2). 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>]acceptsallowed_devices,pinned_memory_limit,active_thread_percentage,client_priority,uid,locality_domains(boolean only), andtimeslice_pct(0-100; omitted or 0 means unset). The example scales thelongduration to 25 ms for servertraining.[servers.<name>.namespaces.<name>]acceptspinned_memory_limit,active_thread_percentage,client_priority,cgroup, andcgroup_depth.cgroupis an absolute cgroup v2 path below/sys/fs/cgroup; omitted or"none"means unmapped.cgroup_depthrequires a mapping and accepts 0-64; omitted means unbounded. See Cgroup Matching. A namespace nameddefaultrefers 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]]requiresuuidandsm_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]]requiresuuid. Optionalsm_partitionassigns 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 requiringnameandchunks, with optionalinclude_remainder(defaultfalse) and the load balancing keysshareable(boolean, defaultfalse),max_chunks(a non-negative integer or the string"unlimited";0disables borrowing; a numeric value must be at leastchunks). See SM Partition Load Balancing.sm_partitionsentries define partitions;sm_partitionselects one for a namespace. The example defines thelargepartition and assigns it tohigh_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_limitin the file corresponds to--pinned-memory-limiton the command line).