Command Line Interface¶
Print these command-line options and exit.
Start lnav and switch to the help view.
Check the given files against the configuration, report any errors, and exit. This option can be helpful for validating that a log format is well-formed.
- -c <command>¶
Execute the given lnav command, SQL query, or lnav script. The argument must be prefixed with the character used to enter the prompt to distinguish between the different types (i.e. ‘:’, ‘;’, ‘|’). This option can be given multiple times.
- -f <path>¶
Execute the given command file. This option can be given multiple times.
- -I <path>¶
Add a configuration directory.
Install the format files in the
.lnav/formats/directory. Individual files will be installed in the
installeddirectory and git repositories will be cloned with a directory name based on their repository URI.
Update formats installed from git repositories.
- -d <path>¶
Write debug messages to the given file.
Run without the curses UI (headless mode).
Do not open the default syslog file if no files are given.
Recursively load files from the given base directories.
Prepend timestamps to the lines of data being read in on the standard input.
- -w <path>¶
Write the contents of the standard input to this file.
Print the version of lnav.
Do not print the log messages after executing all of the commands.
If this variable is set, lnav will use this directory to store its configuration in a sub-directory named
XDG_CONFIG_HOMEis not set, lnav will use this directory to store its configuration in a sub-directory named
The timezone setting is used in some log formats to convert UTC timestamps to the local timezone.
To load and follow the system syslog file:lnav
To load all of the files in
To watch the output of make with timestamps prepended:make 2>&1 | lnav -t