Essential Linux Commands for File Management, Monitoring, and Oracle EBS Administration
A compact reference of commonly used Linux and Oracle E-Business Suite commands. Each command includes a short description to help you understand its purpose before execution.
📂 File Transfer and Archive Management
Synchronize files with compression while preserving attributes
Efficiently copy files between systems while compressing data and preserving timestamps, permissions, and ownership.
rsync -az /path/to/source username@host:/path/to/destination
Extract files from a tar archive excluding the inst
directory
Unpacks a tar archive to root /
while ignoring files inside the inst
folder.
tar xfv --exclude='inst/*' -C /
🔍 Searching and Managing Files
Delete files older than 30 days and print their names
Removes old files to free space while printing each deleted filename for confirmation.
find . -mtime +30 -exec rm -f {} \; -print
List files modified within the last 2 minutes
Helps identify recently updated files with detailed metadata (long listing, sorted by time).
find . -type f -mmin -2 -exec ls -ltr {} \;
Find all PDF files and count per directory
Counts how many .PDF
files exist in each directory (case-sensitive pattern in this example).
find . -type f -name "*.PDF" | grep -o '/./' | sort | uniq -c
Count number of files in each directory
Quickly checks file distribution across folders by listing each directory with its file count.
find . -type d -exec sh -c 'echo -n "{}: "; find "{}" -maxdepth 1 -type f | wc -l' \;
Delete files older than 10 days and print their names
Removes files older than 10 days and prints each filename as it is deleted.
find . -mtime +10 -exec rm -f {} \; -print
⚙️ Monitoring Processes and Services
Check Oracle Concurrent Manager processes
Verifies if FNDLIBR
processes (Concurrent Managers) are running.
ps -ef | grep FNDLIBR
Check Oracle HTTP Server / Apache processes
Lists active Apache or HTTPD processes.
ps -ef | grep apache
ps -ef | grep httpd
Check Forms server processes
Confirms if Oracle Forms runtime processes are active.
ps -ef | grep forms
Check OACore WebLogic managed server processes
Displays running OACore JVM processes (useful for EBS WebLogic troubleshooting).
ps -ef | grep oacore
Check if a port is listening
Tests if a specific port is active and accepting connections.
netstat -an | grep <port>
List open ports with associated processes
Shows which processes are bound to a given port (requires appropriate privileges).
netstat -nlpa | grep <port>
Show processes using port 5557
Finds detailed process info for applications using port 5557
.
netstat -anp | grep 5557
Test TCP connection (PostgreSQL example)
Checks if a remote host and port (e.g., PostgreSQL 5432) are reachable using netcat.
nc -zv 10.0.2.155 5432
Verify connection with telnet
Uses telnet to manually test host and port connectivity (useful for quick debugging).
telnet <host_name> <port>
📑 Configuration File Exploration
Quickly extract important port, URL, and service configurations from your Oracle EBS $CONTEXT_FILE
.
grep -i oacore_server_ports $CONTEXT_FILE
grep -i oafm_server_ports $CONTEXT_FILE
grep -i appldcp $CONTEXT_FILE
grep -i s_shared $CONTEXT_FILE
grep s_url_protocol $CONTEXT_FILE
grep "s_endUserMonitoringURL" $CONTEXT_FILE
grep "s_external_url" $CONTEXT_FILE
grep "s_webentryhost" $CONTEXT_FILE
grep "s_webentrydomain" $CONTEXT_FILE
grep "s_webdomain" $CONTEXT_FILE
grep "s_login_page" $CONTEXT_FILE
grep "s_active_webport" $CONTEXT_FILE
grep "s_webssl_port" $CONTEXT_FILE
grep "s_webentryurlprotocol" $CONTEXT_FILE
grep "httpslistenparameter" $CONTEXT_FILE
grep "s_enable_sslterminator" $CONTEXT_FILE
grep "adminport" $CONTEXT_FILE
grep "URL" $CONTEXT_FILE
grep $APPLTMP $CONTEXT_FILE
grep $APPLPTMP $CONTEXT_FILE
🖥️ Oracle EBS Managed Server Status
List OACore and OAFM managed servers
Displays all configured managed servers inside the domain directory.
ls $EBS_DOMAIN_HOME/servers/ | grep oacore
ls $EBS_DOMAIN_HOME/servers/ | grep oafm
Check status of specific managed servers
Runs admanagedsrvctl.sh
to verify if servers are up or down.
./admanagedsrvctl.sh status oacore_server1
./admanagedsrvctl.sh status forms_server1
./admanagedsrvctl.sh status oafm_server1
./admanagedsrvctl.sh status forms-c4ws_server1
Loop through multiple servers in one go
Automates status checks for multiple managed servers in a single command.
for srv in oacore_server1 oafm_server1 forms_server1 forms-c4ws_server1; do
./admanagedsrvctl.sh status $srv
done
🖥️ Terminal Multiplexing with Tmux
Start a new tmux session
Create a detachable terminal session so you can run long jobs and come back to them later.
tmux
Detach from a running session
Press Ctrl+B
then D
to detach and leave the session running in background.
CTRL+B D
Reattach to a detached session
Reconnect to a previously detached tmux session.
tmux a
🔑 SSH Key Generation and Setup
Generate RSA SSH key (PEM format)
Creates a 2048-bit RSA private/public keypair in PEM format for compatible SSH setups.
ssh-keygen -t rsa -b 2048 -m PEM
Generate ECDSA SSH key
Creates a high-strength ECDSA key (521-bit) for modern SSH security.
ssh-keygen -t ecdsa -b 521
Add public key to authorized_keys
Append your public key so that the corresponding private key can be used to SSH in.
cat id_rsa.pub >> authorized_keys
🔐 File Attributes and Permissions
Add immutable attribute (protect file)
Prevents file deletion or modification even by root until the attribute is removed.
chattr +i <file_name>
Remove immutable attribute
Allows modifications after removing the immutable flag.
chattr -i <file_name>
💽 Disk and Filesystem Identification
List block devices with UUIDs and mount points
Shows block device names, unique identifiers, and where they're mounted.
lsblk -o NAME,UUID,MOUNTPOINT
Display detailed block device info
Prints device information such as LABEL, UUID and filesystem type.
blkid
✍️ Quick Text Replacement
Replace “deny” with “allow” in config.xml
Performs an inline replacement and saves the file using the classic Ex editor.
ex -s -c '%s/deny/allow/g|x' config.xml