1AND.CONF(5)                      File Formats                      AND.CONF(5)
2
3
4

NAME

6       /etc/and/and.conf  - general configuration parameters for the auto nice
7       daemon.
8
9
10

VERSION

12       This manual page documents and.conf for and version 1.2.2.
13
14
15

DESCRIPTION

17       This is the general configuration file for  and.   It  stores  settings
18       like  the default nice level, the renice intervals, the three stages of
19       renicing, and the affinity of the priority database, i.e. the weight of
20       (user,  group,  command)  when resolving nice levels from the database.
21       These settings are described below.
22
23       Comments start with a # in the first column.  Empty lines are  ignored.
24       Unlike  with  other  configuration  files, lines cannot be concatenated
25       with a backslash. Furthermore, this file is case sensitive.
26
27       and allows for host-specific sections in the configuration file.  These
28       work  as  lines of the form on somehost and work as follows: the parser
29       determines if the host name (as returned by  gethostname)  matches  the
30       extended regular expression that follows the on keyword. If it does, it
31       just keeps processing the file as if nothing had happened. If  it  does
32       not match, however, everything up to the next on keyword is skipped. So
33       if you want to end a  host-specific  section,  you  must  write  on  .*
34       (which matches all hosts) to switch back to normal.
35
36       Don't forget to kill -HUP the auto nice daemon to enable the changes.
37
38
39

SETTINGS

41       defaultnice
42            The  default nice level. A number between 0 and 19. Jobs for which
43            no entry can be found in /etc/and/and.priorities  are  reniced  to
44            this level, regardless of the CPU time they've used so far. If you
45            prefer to renice unknown jobs gradually, you can do so by  supply‐
46            ing   three   asterisks   as   (user,  group,  command)  tuple  in
47            /etc/and/and.priorities.  The default nice level is 0
48
49
50       interval
51            The default interval between nice checks of the auto nice  daemon,
52            in  seconds.  This  value can be overridden by the -i command-line
53            option of and.  The default interval is 60 seconds.
54
55
56       lv1time
57
58       lv2time
59
60       lv3time
61            Ranges for the nice levels. Jobs with less  than  lv1time  seconds
62            CPU time are not reniced; jobs between lv1time and lv2time seconds
63            are reniced to the first  level  in  an.priorities;  jobs  between
64            lv2time  and  lv3time  seconds to the second level; jobs with more
65            than lv3time seconds are reniced to the third level.  Defaults are
66            120 , 1200 , and 3600 seconds.
67
68
69       minuid, mingid
70            Minimum  user id and group id to be considered for renicing.  Pro‐
71            cesses whose user id is below minuid are left alone, as  are  pro‐
72            cesses  with  a  group id of below mingid.  (Note that even if you
73            set minuid to zero, root processes are left alone.)
74
75
76       affinity
77            Strategy for picking the right priority entry for a user/group/job
78            triple.  The  strategy  is  a  permutation  of  "cgu",  "c"ommand,
79            "g"roup, "u"ser. The order specifies the affinity of the  priority
80            lookup method. Suppose you have an entry for all jobs of user foo,
81            another entry for all jobs of group bar, and yet another entry for
82            the  command  baz.   Furthermore  suppose user foo (who happens to
83            belong to group bar ) starts a job named baz -- which entry should
84            be  chosen?  This  is what the affinity setting means, for example
85            "cug" means an exact match of the command has priority  over  both
86            an  exact match of the user and the group. The default affinity is
87            "cug", which is probably sensible for most cases, since  it's  the
88            job which takes up CPU time, not the user or group ID.
89
90
91

EXAMPLES

93       Default Configuration
94            # This is the default configuration:
95            defaultnice 0
96            interval 60
97            lv1time 300
98            lv2time 1800
99            lv3time 3600
100            affinity cug
101            minuid 0
102            mingid 0
103
104
105       Default Configuration, with terminals
106            # Normal default configuration for all
107            defaultnice 0
108            interval 60
109            lv1time 300
110            lv2time 1800
111            lv3time 3600
112            # Hosts foo, bar, baz are terminals and must
113            # be more responsive, so earlier renice.
114            on (foo|bar)
115            lv1time 120
116            lv2time 600
117            lv3time 1200
118            on .*
119            # This is for all hosts again
120            affinity cug
121
122
123       Group-specific Hosts
124            defaultnice 0
125            interval 60
126            lv1time 300
127            lv2time 1800
128            lv3time 3600
129            # Normal affinity for all hosts.
130            affinity cug
131            # Hosts bar, baz belong to group foo, which
132            # is privilegued on these hosts, so override
133            # affinity. (Note regexp!)
134            on ba[rz]
135            affinity guc
136            on .*
137            minuid 500
138            mingid 100
139
140
141

FILES

143       /etc/and.conf
144            General  configuration  file.  Stores  default nice level, default
145            interval, the "time zones" and the database lookup affinity.  This
146            is what this manual page is about.
147
148
149

SEE ALSO

151       and(8), and.priorities(5), kill(1), regex(7), renice(8)
152
153
154

INTERNET

156       http://and.sourceforge.net/
157
158
159

AUTHOR

161       The  auto  nice  daemon  and  this  manual page were written by Patrick
162       Schemitz <schemitz@users.sourceforge.net>
163
164
165
166Unix                              27 Mar 2005                      AND.CONF(5)
Impressum