ADRCI Commands
ADRCI (Automatic Diagnostic Repository Command-Line Interface) is a powerful Oracle utility for managing diagnostic data such as listener logs, alert logs, incidents, and core dumps. This guide covers essential ADRCI commands to help you analyze, maintain, and troubleshoot your Oracle environment effectively.
General Commands
adrept -- Launches the ADR report viewer
adrcat -- Displays contents of the ADR repository
adrci -- Opens the ADR command-line interface
show base -- Shows current ADR base location
set base <path> -- Sets a new ADR base location
show home -- Lists current ADR homes (Oracle homes)
set homepath <path> -- Sets a new Oracle home path
show alert -- Displays the alert log
show alert -tail <n> -- Shows last n lines of alert log
Purging Diagnostic Files
purge -age <minutes> -type <type> -- Purges diagnostic files older than specified age by type
set control (LONGP_POLICY = <hours>) -- Sets retention period (hours) for long retention policy
set control (SHORTP_POLICY = <hours>) -- Sets retention period (hours) for short retention policy
show control -- Displays current retention policies
Incident Package Management
IPS CREATE PACKAGE INCIDENT -- Creates an incident package
ips pack incident in <output_path> -- Packs incidents into output directory
IPS CREATE PACKAGE -- Creates an empty package for manual additions
IPS ADD INCIDENT <incident_number> PACKAGE <package_number> -- Adds incident to package
IPS ADD FILE <file_path> PACKAGE <package_number> -- Adds file to package
IPS GENERATE PACKAGE <package_number> IN <output_dir> -- Generates package file
ips unpack file <file_name> into <directory> -- Unpacks IPS file into directory
ips pack time '<start_time>' to '<end_time>' -- Packs incidents within time range
ips show package -- Shows list of packages
ips show package <package_number> -- Shows package details
ips delete package <package_number> -- Deletes a package
ips remove incident <incident_number> package <package_number> -- Removes incident from package
ips remove problem <problem_number> package <package_number> -- Removes problem from package