Command History

View the command execution and auditable event history for the current context using the mtxctl history command.

Note: History is not kept indefinitely. There is a limit to how much history that can be viewed.

Command Execution History

The mtxctl history command list command returns the commands you have run recently.

By default, this shows the last 12 hours. The length of time can be adjusted using the --period flag:

mtxctl history command list --period 1h

You can also adjust the reported period of time with the --since flag:

mtxctl history command list --since "2014-03-07 12:00:00" --period 4h

View history of all Admin Service users with the --all flag:

mtxctl history command list --all

View more details about a command execution using the view sub-command:

history command view ID

Where ID is one of the IDs in the output of history command list. The output is provided in JSON format. This can be made more easy to read when processed with the jq tool:

mtxctl history command view xxxxxxxxxxxxxxx | jq '.'

Audit Event

The mtxctl history event list command returns the audit events captured by the Admin Service.

By default, this shows the last 12 hours. The length of time can be adjusted using the --period flag:

mtxctl history event list --period 1h

You can also adjust the reported period of time with the --since flag:

mtxctl history event list --since "2014-03-07 12:00:00" --period 4h

View more details about a command execution using the view sub-command:

history event view ID

Where ID is one of the IDs in the output of history event list. The output is provided in JSON format. This can be made more easy to read by processing the output with the jq tool:

mtxctl history event view xxxxxxxxxxxxxxx | jq '.'