GANESHA-LOG-CONFIG(8)

✨ GANESHA-LOG-CONFIG ✨

okay so bestie, this is the ganesha-log-config manual page, section 8, from the NFS-Ganesha crew πŸ’– it's the whole lore on the Ganesha Log Configuration File and honestly? it's a lot. but we're gonna get through it together, no cap 🫢


🌸 NAME 🌸

ganesha-log-config β€” NFS Ganesha Log Configuration File πŸ’…


πŸ¦‹ SYNOPSIS πŸ¦‹

/etc/ganesha/ganesha.conf

✨ DESCRIPTION ✨

NFS-Ganesha reads the configuration data from:

/etc/ganesha/ganesha.conf

This file lists NFS-Ganesha Log config options. that's literally its whole job πŸŽ€

heads up bestie: these options may be dynamically updated by issuing a SIGHUP to the ganesha.nfsd process. live edits, main character energy πŸ‘‘

πŸ’– LOG {} πŸ’–

  • Default_log_level(token, default EVENT) β€” if this option is NOT set, the fall-back log level is the one given by the -N option on the command line, if that's set. otherwise the fallback level is EVENT.
    • and if a SIGHUP is issued, any components that aren't spelled out in LOG { COMPONENTS {} } get reset to this value. (yes, reset. it's giving consequences 😭)

The log levels are:

NULL, FATAL, MAJ, CRIT, WARN, EVENT, INFO, DEBUG, MID_DEBUG, M_DBG, FULL_DEBUG, F_DBG

  • RPC_Debug_Flags(uint32, range 0 to UINT32_MAX, default 7) β€” debug flags for TIRPC (the default 7 matches the log level default EVENT).
    • > lowkey important: these flags are only used if the TIRPC component is set to DEBUG.
  • Display_UTC_Timestamp(bool, default false) β€” flag to enable displaying UTC date/time in log messages instead of localtime. timezone girlies rise 🌈
  • Match_Policy(token, default MATCH_ANY) β€” specifies how conditional logging rules are evaluated when Clients and/or Exports are configured.
    • MATCH_ANY β€” enable conditional logging if either the client OR the export matches.
    • MATCH_ALL β€” enable conditional logging only if both the client AND the export match.

πŸŽ€ LOG { COMPONENTS {} } πŸŽ€

  • Default_log_level(token, default EVENT)

These entries are of the form:

COMPONENT = LEVEL;

The components are:

ALL, LOG, MEMLEAKS, FSAL, NFSPROTO, RECOVERY, NFS_V4, EXPORT, FILEHANDLE, DISPATCH, MDCACHE, MDCACHE_LRU, HASHTABLE, HASHTABLE_CACHE, DUPREQ, INIT, MAIN, IDMAPPER, NFS_READDIR, NFS_V4_LOCK, CONFIG, CLIENTID, SESSIONS, PNFS, RW_LOCK, NLM, TIRPC, NFS_CB, THREAD, NFS_V4_ACL, STATE, 9P, 9P_DISPATCH, FSAL_UP, DBUS, NFS_MSK, XPRT

Some synonyms are:

FH = FILEHANDLE
HT = HASHTABLE
CACHE_INODE_LRU = MDCAHCE_LRU
CACHE_INODE = MDCACHE
INODE_LRU = MDCAHCE_LRU
INODE = MDCACHE
DISP = DISPATCH
LEAKS = MEMLEAKS
NFS3 = NFSPROTO
NFS4 = NFS_V4
HT_CACHE = HASHTABLE_CACHE
NFS_STARTUP = INIT
NFS4_LOCK = NFS_V4_LOCK
NFS4_ACL = NFS_V4_ACL
9P_DISP = 9P_DISPATCH

The log levels are:

NULL, FATAL, MAJ, CRIT, WARN, EVENT, INFO, DEBUG, MID_DEBUG, M_DBG, FULL_DEBUG, F_DBG

default none

ALL is a special component that, when set, sets all components to the specified value, overriding any that are explicitly set. note that if ALL is then removed from the config and SIGHUP is issued, all components will revert to what is explicitly set, or Default_Log_Level if that is specified, or the original log level from the -N command line option if that was set, or the code default of EVENT. the whole chain, in order, no skipping πŸ’…

TIRPC is a special component that also sets the active RPC_Debug_Flags. if the level for TIRPC is DEBUG or MID_DEBUG, the custom RPC_Debug_Flags set by that parameter will be used. otherwise the flags depend on the level the TIRPC component is set to:

  • NULL or FATAL: 0
  • CRIT or MAJ: TIRPC_DEBUG_FLAG_ERROR
  • WARN: TIRPC_DEBUG_FLAG_ERROR | TIRPC_DEBUG_FLAG_WARN
  • EVENT or INFO: TIRPC_DEBUG_FLAG_ERROR | TIRPC_DEBUG_FLAG_WARN | TIRPC_DEBUG_FLAG_EVENT
  • DEBUG or MID_DEBUG: RPC_Debug_Flags
  • FULL_DEBUG: 0xffffffff

🌈 LOG { CONDITIONAL {} } 🌈

Conditional logging allows selective override of log levels for specific clients or exports, while all other traffic continues to use the global COMPONENTS settings. this mechanism is useful for debugging targeted activity without increasing verbosity system-wide. targeted glow-up only, periodt ✨

🧚 How It Works

Global Filtering (COMPONENTS block) β€” all requests are first evaluated against the log levels defined in the top-level COMPONENTS block. these levels serve as the default for all clients and exports.

Conditional Overrides (Conditional block) β€” the Conditional block provides a way to override component log levels only for the clients or exports explicitly listed.

If a request matches a client and/or export mentioned in the Conditional block: β†’ logging levels defined inside Conditional apply.

If a request does not match any entry in the Conditional block: β†’ logging uses only the global COMPONENTS settings.

This behavior ensures that only selected traffic receives more or less verbose logging, while all remaining traffic follows the normal log-level configuration. it's giving VIP section πŸŽ€

Example:

LOG {
  COMPONENTS {
    FSAL = WARN;
    NFS4 = CRIT;
  }

  Match_Policy = MATCH_ANY;

  Conditional {
    Clients = 192.0.2.25;
    Exports = 101;

    COMPONENT_ALL = EVENT;
    NFS4 = DEBUG;
  }
}

Explanation:

  • Requests originating from client/export inside the Conditional block are logged strictly according to conditional components (e.g. NFS4 = DEBUG, ALL = EVENT).
  • Requests from all other clients or exports are logged strictly according to the top-level COMPONENTS block (e.g., FSAL = WARN, NFS4 = CRIT).

πŸ’œ Clients(client list, default: empty)

  • Client list entries can take on one of the following forms. this parameter may be repeated to extend the list.
  • x.x.x.x β€” IPv6 addresses are only allowed

πŸ“ Exports(Export list, default: empty)

  • Export list entries can take list of Export_IDs.

⭐ COMPONENT = LEVEL

The components are:

ALL, LOG, MEMLEAKS, FSAL, NFSPROTO, NFS_V4, EXPORT, FILEHANDLE, DISPATCH, MDCACHE, MDCACHE_LRU, HASHTABLE, HASHTABLE_CACHE, DUPREQ, INIT, MAIN, IDMAPPER, NFS_READDIR, NFS_V4_LOCK, CONFIG, CLIENTID, SESSIONS, PNFS, RW_LOCK, NLM, TIRPC, NFS_CB, THREAD, NFS_V4_ACL, STATE, 9P, 9P_DISPATCH, FSAL_UP, DBUS, NFS_MSK, XPRT

Some synonyms are:

FH = FILEHANDLE
HT = HASHTABLE
CACHE_INODE_LRU = MDCAHCE_LRU
CACHE_INODE = MDCACHE
INODE_LRU = MDCAHCE_LRU
INODE = MDCACHE
DISP = DISPATCH
LEAKS = MEMLEAKS
NFS3 = NFSPROTO
NFS4 = NFS_V4
HT_CACHE = HASHTABLE_CACHE
NFS_STARTUP = INIT
NFS4_LOCK = NFS_V4_LOCK
NFS4_ACL = NFS_V4_ACL
9P_DISP = 9P_DISPATCH

The log levels are:

NULL, FATAL, MAJ, CRIT, WARN, EVENT, INFO, DEBUG, MID_DEBUG, M_DBG, FULL_DEBUG, F_DBG, default FULL_DEBUG

ALL is a special component that, when set, sets all components to the specified value, overriding any that are explicitly set. default is set to FULL_DEBUG. COMPONENT_ALL in Conditional acts as fallback for any unspecified components. bestie fallback, iykyk 🫢


πŸ‘‘ LOG { FACILITY {} } πŸ‘‘

This block may be repeated to configure multiple log facilities. (yes, multiple. collect them all πŸ’…)

  • name(string, no default)
  • destination(string, no default, must be supplied) β€” non-negotiable, it has to be there
  • max_level(token, default FULL_DEBUG) β€” the log levels are: NULL, FATAL, MAJ, CRIT, WARN, EVENT, INFO, DEBUG, MID_DEBUG, M_DBG, FULL_DEBUG, F_DBG
  • headers(token, values [none, component, all], default all)
  • enable(token, values [idle, active, default], default idle)

πŸ’« LOG { FORMAT {} } πŸ’«

  • date_format(enum, default ganesha) β€” possible values: ganesha, true, local, 8601, ISO-8601, ISO 8601, ISO, syslog, syslog_usec, false, none, user_defined
  • time_format(enum, default ganesha) β€” possible values: ganesha, true, local, 8601, ISO-8601, ISO 8601, ISO, syslog, syslog_usec, false, none, user_defined
  • user_date_format(string, no default)
  • user_time_format(string, no default)
  • EPOCH(bool, default true)
  • CLIENTIP(bool, default false)
  • HOSTNAME(bool, default true)
  • PROGNAME(bool, default true)
  • PID(bool, default true)
  • THREAD_NAME(bool, default true)
  • FILE_NAME(bool, default true)
  • LINE_NUM(bool, default true)
  • FUNCTION_NAME(bool, default true)
  • COMPONENT(bool, default true)
  • LEVEL(bool, default true)
  • OP_ID(bool, default false)
  • CLIENT_REQ_XID(bool, default false)
  • LOG_INDEX(bool, default false)
  • LOG_INDEX_WRAP_AROUND(uint32_t, default 100000)

πŸŽ€ LOG { ROTATE {} } πŸŽ€

  • size_kb(uint32_t, default 0) β€” rotate the log file when the size in KB exceeds this value. if zero, do not rotate based on size.
  • time_sec(uint32_t, default 0) β€” rotate the log file when the time in seconds exceeds this value. if zero, do not rotate based on time.

πŸ”₯ SEE ALSO πŸ”₯

ganesha-config <>(8)


and that's the whole page, bestie πŸ¦‹ go forth and configure your logs with main character energy πŸ’–

NFS-Ganesha β€” Aug 11, 2026 β€” GANESHA-LOG-CONFIG(8) βœ¨πŸŽ€

πŸ“¦ where this page comes from