AND(8)

πŸ’– AND(8) β€” Administrator's Tools πŸ’–

okay bestie, sit down, we're talking about and, the auto nice daemon, from section 8 of the manual (that's the admin-tools girlies section, iykyk πŸ‘‘). This page documents and version 1.2.2, and honestly? she's giving quiet chaos in the best way.


✨ NAME ✨

and β€” the auto nice daemon. that's it, that's the name, short and iconic πŸŽ€


🌸 SYNOPSIS 🌸

and [-htvsxf] [-i interval] [-c /path/to/and.conf] [-d
/path/to/and.priorities]

πŸ¦‹ VERSION πŸ¦‹

This manual page documents and version 1.2.2. yes girl, 1.2.2, write it down πŸ“


πŸ’… DESCRIPTION πŸ’…

So the auto nice daemon wakes herself up in certain intervals and then, like, does the most: she renices jobs and even straight-up kills them, all according to their priority and CPU usage. main character energy fr fr πŸ”₯

Renice levels and kill signals can be defined in terms of users, groups, and commands. Wildcards? yes babes, you can use them for any of those. And on top of that, commands can be specified using POSIX regular expressions. For the network-wide girls who need network-wide configuration and priority files, there's a mechanism for hostname-based evaluation β€” and yes, it also supports regular expressions for specifying host names. regex girlies, we ate πŸ’…

Two rules to keep in your heart forever:

  • Jobs owned by root are left alone. don't touch her, she's busy πŸ’€
  • Jobs are never increased in their priority. no, we do not glow-up a job's niceness upward, that's not the vibe.

Here are some real-world examples, because lore matters:

  • A certain user is notorious for wasting CPU with next-to-irrelevant jobs. One line is all you need to renice all of his jobs to about 19. This is a typical situation for a LART (Luser's Attitude Readjustment Tool) like and. 🫢
  • A CPU server is dedicated to a certain group, but others may also use it when it's idle. Just define default nice levels of e.g. 18 and a lower nice level for the privileged group, say nice level 12. slay, everybody gets their turn ✨
  • A certain web browser who shall remain unnamed tends to go berserk once in a while. You can configure and to kill -9 it after e.g. 20 CPU minutes. (not me naming names, i would NEVER πŸ™ˆ)

✨ COMMAND-LINE OPTIONS ✨

one bullet per flag, no skipping, we're thorough here πŸ’–

  • -c /path/to/and.conf β€” Specifies the configuration file. If this flag is omitted, /etc/and.conf is used instead. πŸŽ€
  • -d /path/to/and.priorities β€” Specifies the priority database file. If this flag is omitted, /etc/and.priorities is used instead. πŸ—‚οΈ
  • -h β€” Produces a short help text. a little snack of information, love that for us 🌸
  • -i interval β€” Sets the interval between nice level checks. This flag overrides the interval specified in the configuration file, if any. The default interval of 60 seconds is used if neither -i nor an interval directive in the configuration file is given. ⏰
  • -s β€” Log to stdout. Without this switch, logging goes to syslog (normal operations) or ./debug.and (test mode). Useful for debugging config files. ngl this one is your bestie when you're figuring out why ur conf is acting up πŸ”
  • -t β€” Run in test mode only, i.e. don't really renice or kill anything. In this mode, logging goes into ./debug.and instead of syslog. pretend mode! safe mode! no casualties! 😭
  • -v β€” Increase verbosity. For maximum verbosity, this flag can be specified multiple times. Be warned that this will blow up your log files, so you should use it in test mode only. πŸ’€ (she said be warned and she MEANT it)
  • -x β€” Run in full operational mode, i.e. really renice or kill things. This is the default. no take-backs, she's doing it for real πŸ”₯
  • -f β€” Foreground mode. Don't daemonize. stay right here with me babes 🫢

πŸŽ€ SIGNALS πŸŽ€

On kill -HUP the auto nice daemon will reload its configuration file and priority database. that's the whole thing. glow-up via refresh ✨


🌈 FILES 🌈

  • /etc/and.conf β€” General configuration file. Stores default nice level, default interval, the "time zones" and the database lookup affinity. πŸ“‹
  • /etc/and.priorities β€” The priority database (in plain text). Contains the (user, group, command, nicelevels) tuples. 🧾
  • ./debug.and β€” Contains logging and status information for debugging purposes. Used in test mode only. πŸ›
Both files have their own manual pages. go read them too, they're cute, i promise 🫢

πŸ’œ SEE ALSO πŸ’œ

and.conf(5), and.priorities(5), kill(1), regex(7), renice(8)


🌐 INTERNET 🌐

http://and.sourceforge.net/

πŸ‘‘ AUTHOR πŸ‘‘

The auto nice daemon and this manual page were written by Patrick Schemitz <schemitz@users.sourceforge.net>


okay that's the whole page bestie, you're officially educated πŸ’– this one came from the Unix manual set, dated 27 Mar 2005 β€” shoutout to the era that birthed her, periodt. mwah, go renice responsibly ✨