rolllog(3)

πŸ“¦
version 2.2.3 Β· 3 versions
, in arch rolling

🌸 NAME 🌸

okay bestie, meet rolllog(3) β€” the manual page for Net::DNS::SEC::Tools::rolllog, aka the DNSSEC-Tools rollover logging interfaces. πŸ’– It’s giving β€œlogging glue for the rollover programs,” and we’re gonna go through every single detail together. 🫢


✨ SYNOPSIS ✨

use Net::DNS::SEC::Tools::rolllog;

@levels = rolllog_levels();

$curlevel = rolllog_level();
$oldlevel = rolllog_level("info");
$oldlevel = rolllog_level(LOG_ERR,1);

$curlogfile = rolllog_file();
$oldlogfile = rolllog_file("-");
$oldlogfile = rolllog_file("/var/log/roll.log",1);

$loglevelstr = rolllog_str(8)
$loglevelstr = rolllog_str("info")

$ret = rolllog_num("info");

$bool = rolllog_validlevel($newlevel);
$bool = rolllog_validlevel(8);

$curtz = rolllog_gettz();
$oldtz = rolllog_settz('local');

rolllog_log(LOG_INFO,"example.com","zone is valid");

πŸ’… DESCRIPTION πŸ’…

The Net::DNS::SEC::Tools::rolllog module provides logging interfaces for the rollover programs. These interfaces let log messages actually get recorded. ✨ Real talk: rollerd must be running, because rollerd is responsible for updating the log file. No rollerd, no log-file updates, periodt. πŸ’€

Each log message gets assigned a particular logging level. The valid logging levels are:

  • tmi β€” numeric 1 β€” the highest level; all log messages are saved. πŸ‘‘
  • expire β€” numeric 3 β€” a verbose countdown of zone expiration is given. ⏳
  • info β€” numeric 4 β€” many informational messages are recorded. 🌸
  • phase β€” numeric 6 β€” each zone’s current rollover phase is given. πŸŒ€
  • err β€” numeric 8 β€” errors are recorded. 🚨
  • fatal β€” numeric 9 β€” fatal errors are saved. πŸ’€

The levels include all numerically higher levels. For example, if the log level is set to phase, then err and fatal messages will also be recorded. iykyk β€” the higher numbers are included automatically. πŸ’œ


🫢 LOGGING INTERFACES 🫢

  • rolllog_file(newfile,useflag) β€” this routine sets and retrieves the log file for rollerd. The newfile argument specifies the new log file to be set. If newfile exists, it must be a regular file. πŸ“ The useflag argument is a boolean that indicates whether or not to give a descriptive message if an invalid log file is given. If useflag is true, the message is given and the process exits; if false, no message is given. For any error condition, an empty string is returned. 🫠
  • rolllog_gettz() β€” this routine returns the timezone selector currently in use. This value may be either 'gmt' (for Greenwich Mean Time) or 'local' (for the host’s local time.) 🌍
  • rolllog_level(newlevel,useflag) β€” this routine sets and retrieves the logging level for rollerd. The newlevel argument specifies the new logging level to be set. newlevel may be given in either text or numeric form. πŸ”’ The useflag argument is a boolean that indicates whether or not to give a descriptive message and exit if an invalid logging level is given. If useflag is true, the message is given and the process exits; if false, -1 is returned. 😭 If given with no arguments, the current logging level is returned. In fact, the current level is always returned unless an error is found. -1 is returned on error. so if you see -1, something went off. πŸ’…
  • rolllog_levels() β€” this routine returns an array holding the text forms of the user-settable logging levels. The levels are returned in order, from most verbose to least. πŸŽ€
  • rolllog_log(level,group,message) β€” the rolllog_log() interface writes a message to the log file. Log messages have this format:
timestamp: group: message

The level argument is the message’s logging level. It will only be written to the log file if the current log level is numerically equal to or less than level. πŸ‘€ group allows messages to be associated together. It is currently used by rollerd to group messages by the zone to which the message applies. πŸ—‚οΈ The message argument is the log message itself. Trailing newlines are removed. βœ‚οΈ

  • rolllog_num(loglevel) β€” this routine translates a text log level (given in loglevel) into the associated numeric log level. The numeric log level is returned to the caller. πŸ” If loglevel is an invalid log level, -1 is returned. πŸ’€
  • rolllog_settz(tzsel) β€” this routine sets the timezone to be used for timestamps in messages written to the log. This tzsel value may be either 'gmt' (Greenwich Mean Time) or 'local' (for the host’s local time.) tzsel may be uppercase or lowercase; the value will be converted to lowercase. If no value is passed, then the default will be used. πŸ•°οΈ The current timezone selector is returned. If an invalid selector is given, then an undefined value is returned. πŸ™ˆ
  • rolllog_str(loglevel) β€” this routine translates a log level (given in loglevel) into the associated text log level. The text log level is returned to the caller. πŸ”€ If loglevel is a text string, it is checked to ensure it is a valid log level. Case is irrelevant when checking loglevel. 🌈 If loglevel is numeric, it must be in the valid range of log levels. undef is returned if loglevel is invalid. πŸ˜΅β€πŸ’«
  • rolllog_validlevel(level) β€” this interface returns a boolean value indicating if the given logging level is valid. βœ… The level argument is the logging level to be validated. It may be a numeric or textual value. πŸ”

Copyright 2005-2014 SPARTA, Inc. All rights reserved. See the COPYING file included with the DNSSEC-Tools package for details. πŸ“œ


πŸ¦‹ AUTHOR πŸ¦‹

Wayne Morrison, tewok@tislabs.com πŸ’Œ


🌈 SEE ALSO 🌈

  • rollctl(1)
  • rollerd(8)
  • Net::DNS::SEC::Tools::rollmgr.pm(3)

mwah πŸ’‹ β€” source/version is perl v5.44.0, and this page is dated 2026-10-17. bye bestie! πŸ«ΆπŸŽ€

πŸ“¦ where this page comes from