1TUNA(8) System Administration Utilities TUNA(8)
2
3
4
6 tuna - program for tuning running processes
7
9 tuna [OPTIONS]
10
12 This manual page explains the tuna program. The program can be used to
13 change the attributes of application and kernel threads. tuna can oper‐
14 ate on IRQs by name or number, and tasks or threads by process ID or
15 command-line. CPUs and sets of CPUs can be specified by CPU or socket
16 number. IRQ names and process command-lines can include wildcards.
17
18 tuna can change scheduling policy, scheduler priority and processor
19 affinity for processes and process threads. tuna can also change the
20 processor affinity for interrupts. When tuna is invoked without any
21 options it starts up in its graphical interface mode. This manual page
22 explains only the command-line options for tuna
23
25 tuna has both action options and modifier options. Modifier options
26 must be specified on the command-line before the actions they are in‐
27 tended to modify. Any modifier option applies to following actions on
28 the same command-line until it is over-ridden.
29
30 Actions
31
32 -h, --help
33 Print a list of options. tuna will exit after this action, ig‐
34 noring the remainder of the command-line.
35
36 -g, --gui
37 Start the GUI. Actions that follow this on the command-line will
38 be processed without waiting for the GUI to complete.
39
40 -a, --config_file_apply=profilename
41 Apply changes described in profile
42
43 -l, --config_file_list
44 List preloaded profiles
45
46 -i, --isolate
47 Move all allowed threads and IRQs away from CPU-LIST. Requires
48 -c or -S.
49
50 -I, --include
51 Allow all allowed threads and IRQs to run on CPU-LIST. Requires
52 -c or -S.
53
54 -m, --move
55 Move selected entities to CPU-LIST. Requires -c and either -t or
56 -q.
57
58 -p, --priority=[POLICY:]RTPRIO
59 Set thread scheduler tunables: POLICY and RTPRIO. POLICY is one
60 of OTHER, FIFO, RR, or BATCH. If -t is not set, -p will act as a
61 Modifier saving the sched tunables for future Actions, for exam‐
62 ple -r.
63
64 -P, --show_threads
65 Show thread list.
66
67 -Q, --show_irqs
68 Show IRQ list.
69
70 -r, --run="COMMAND"
71 Run the COMMAND. If arguments are passed, the entire command
72 line must be provided inside "quotes". Modifiers -c and -p can
73 be used to set the affinity and scheduler tunables of the given
74 COMMAND. The arg[0] (i.e. the command) will be set in
75 THREAD-LIST. Likewise the -t, the COMMAND accepts the prefix +
76 and - as wildcards in order to be appended or removed from
77 THREAD-LIST, respectively.
78
79 -R, --refresh=MSEC
80 Refresh the GUI every MSEC milliseconds
81
82 -s, --save=FILENAME
83 Save kthreads sched tunables to FILENAME.
84
85 -v, --version
86 Show version
87
88 -W, --what_is
89 Provides help about selected entities. Requires -t.
90
91 -x, --spread
92 Spread selected entities over CPU-LIST. Requires at least one of
93 -t or -q. The specified threads and IRQs are each assigned to
94 one cpu in CPU-LIST.
95
96 Modifiers
97
98 -c, --cpus=CPU-LIST
99 CPU-LIST affected by commands. Requires a CPU number or a comma-
100 separated list of CPU numbers.
101
102 -C, --affect_children
103 Operation will affect children threads.
104
105 -d, --disable_perf
106 Explicitly disable usage of perf in GUI for process view
107
108 -D, --debug
109 Print DEBUG level logging details to console.
110
111 -f, --filter
112 Disable display of selected CPUs in --gui. Requires -c
113
114 -G, --cgroup
115 Display the processes with the type of cgroups they are in. Re‐
116 quires -P
117
118 -K, --no_kthreads
119 Operations will not affect kernel threads.
120
121 -L, --logging=LOG-LEVEL
122 Log application details to log file for given LOG-LEVEL
123
124 -N, --nohz_full
125 CPUs in nohz_full= kernel command line parameter will be af‐
126 fected by operations
127
128 -q, --irqs=IRQ-LIST
129 IRQ-LIST affected by commands. Requires an IRQ number or a
130 comma-separated list of IRQ numbers.
131
132 -S, --sockets=CPU-SOCKET-LIST
133 CPU-SOCKET-LIST affected by commands. Requires a socket number
134 or a comma-separated list of socket numbers.
135
136 -t, --threads=THREAD-LIST
137 THREAD-LIST affected by commands. Requires a thread number or
138 thread name, or a comma-separated list of thread numbers and/or
139 names. Thread names may contain wildcards. Be sure to quote or
140 escape any wildcard specifications. If only - is passed as argu‐
141 ment, the THREAD-LIST will be cleared.
142
143 -U, --no_uthreads
144 Operations will not affect user threads.
145
147 If for instance the Ethernet NICs have multiple queues for both receive
148 and transmit, each with its own IRQ, the Ethernet IRQs can be associ‐
149 ated with a CPU socket:
150
151 tuna -S 2 -i -q 'eth*' -x
152
153 Move everything off the CPUs in socket 2, then spread the IRQs
154 for the Ethernet devices across those same CPUs.
155
156
157
158tuna February 2010 TUNA(8)