My Oracle Support Banner

Oracle Linux: How to Configure System Logger (syslog) to Record Shell Executed Commands (Doc ID 2657508.1)

Last updated on MARCH 14, 2023

Applies to:

Linux OS - Version Oracle Linux 6.0 and later
Linux x86-64
Linux x86


Whether for security, auditing, or other reasons, it may be necessary or useful to log details of all command-line executed tasks performed by users.
This document describes various methods of how to accomplish the task.


To view full details, sign in with your My Oracle Support account.

Don't have a My Oracle Support account? Click to get started!

In this Document
 1. Using bash shell option shopt to log user commands
 2. Using rsyslogd(8) to log user commands
 3. Using script(1) to log user commands

My Oracle Support provides customers with access to over a million knowledge articles and a vibrant support community of peers and Oracle experts.