stardog-admin log print Manual Page


stardog-admin log print —Prints the contents of an access or audit log. A log is a sequence of events where each event has a type, timestamp, user, ip, flags, and an optional value.


stardog-admin log print [ {-d | --delimeter} <delimeter> ] [ {-f | --field} <field>... ] [ --filter <filter>... ] [ --tail ] [ --text ] [--] <log file>


-d <delimeter>, --delimeter <delimeter>
Delimeter to use for separating fields in the output. By default the output is printed in a tabular format but this option can be used to output in CSV or TSV format.
-f <field>, --field <field>
Fields to include in the output. Allowed values are: {Time, Event, Database, User, IP, Value, Flags}
--filter <filter>
Filter expressions to hide certain events. A filter expression is in the form 'field op value' where field is one of the fields defined in --field option, op is one of '=', '<', '<=', '>', '>=', or '~', and value should be a valid value for the field. For example,filter expression for time field should use xsd:date or xsd:dateTime values. The op '~' represents regular expression matching where value should be a valid Java regular expression and should match the entire value of the given field.
Wait for new events to be logged and print them as they are logged.
Used to indicate that the log file is in text format. Otherwise log will be assumed to be in binary format.
This option can be used to separate command-line options from the list of argument, (useful when arguments might be mistaken for command-line options
<log file>
The log file to print


Print all the events in the log file

    $ stardog-admin log print access.log

Print all the events but show only the specified fields

    $ stardog-admin log print --field time user database query -- access.log

Print only query events for the databases matching the regular expression that occurred in a specific time interval

    $ stardog-admin log print --filter event=query database~customer.* time>=2014-01-06 time<=2014-01-07 -- audit.log