General Commands
Command
Description
Sample usage
pwd
root> pwd
Is
Is -al
root> ls
root> ls -al
cd
Changes directory
root> cd /u01/app/oracle
touch
rm
Deletes files
root> rm slx_01.log
mv
cp
mkdir
find
which
User Management
Command
umask
chmod
Description
To set default File Permissions for current
User
To change the File Permissions after the
creation of the file
Sample usage
root> umask 022
chown
useradd
To add user
usermod
userdel
passwd
who
Performance Characteristics
Command
ps
Description
Sample usage
kill
uname
hostname
cat
alert_lin1.log
root> uname -a
root> hostname
root> cat alert_LIN1.log |
grep -i ORA-
rm
gzip
To zip files
gzip myfile
gunzip
To uncompress
gunzip myfile.gz
compress
To Compress Files
compress myfile
uncompress
To uncompress
uncompress myfile
CPU Performance
vmstat
To display system Statistics(for 5 seconds apart for 2 times):
root>$ vmstat 5 2
procs memory page disk faults
r b w Swap
Free re mf Pi
0
2 2 1 72 0 0
3 0 8 04
2 2 1 72 0 0
2 9 8 08
2
8
po fr
55
178
13 9
143
22 2
31 9
De
sr
s0 s1
in sy
112 4
251
14 3
257
44 9
19
2 17
263
25 1
procs.
This parameter gives information about the number of processes.
R: rocesses in the run queue.
B: processes blocked for resources.
W: Processes those are swapped.
cs
us
261
198
12
cpu
sy id
3
14
88
91
Memory
Reports the usage of the memory.
Swap: currently available swap space.
Free: size of free space.
Page
Reports the paging activities.
Re: pages that were reclaimed.
Mf: minor faults.
Pi: KB paged in.
Po: KB paged out.
Fr: free space.
De: short term memory short fall.
Sr: pages scanned.
Disk
Number of disk operations for the disk s0 and
s1. Faults.
The number of traps and interrupts.
Si: system calls.
Cs : context switches.
CPU
The use of the CPU time.
Us: user time.
Si: system time.
Cs: idle time
root>sar -u 5 2
02:50:51 PM
CP
%use
%nice %system %idle
U
r
02:50:56 PM
all
26.53
2.95 70.53
0.00
02:51:01 PM
all 26.13
2.32 71.55
0.00
Average:
all 26.33
2.63 71.05
0.00
user: CPU utilization that occurred during the execution at the user level.
nice: CPU utilization that occurred during the execution at the user level with
nice priority.
system: CPU utilization that occurred during the execution at the system level.
idle: Time that the CPU was idle
mpstat
Reports preprocessor statistics 5 Seconds apart for 2 times.
mpstat 5
02:51:56
PM
02:52:01
PM
02:52:06
PM
Average:
%idle intr/s
246.52
233.27
239.86
ps
To display the top 10 CPU users.
02:51:56 PM
02:52:01 PM
02:52:06 PM
Average:
%idle intr/s
246.52
233.27
239.86
Contents
/etc/passwd
User settings
/etc/group
/etc/hosts
/etc/system