Cover | Table of Contents
ps -ef|grep "ora_"|grep -v grep|awk '{ print $2 }'|xargs kill -9
ps -ef
|
grep "ora_"
|
grep -v grep
|
awk '{ print $2 }'
|
xargs kill -9
#***********************************************
# Standard Unix Prompt
#***********************************************
PS1="
`hostname`*\${ORACLE_SID}-\${PWD}
>"
corphp*PROD-/home/oracle >pwd /home/oracle corphp*PROD-/home/oracle >cd /u01/oradata/PROD corphp*PROD-/u01/oradata/PROD >
>ps -ef|grep ora
UID PID PPID C STIME TTY TIME CMD
oracle 13168 1 0 05:33:06 - 3:15 oracleprod
oracle 26164 1 0 12:57:10 - 4:54 oracleprod
...
>ps -ef|sort +6|tail
oracle 55676 1 0 03:06:16 - 0:36 oracleprod
oracle 24876 1 0 02:52:56 - 0:40 oracleprod
oracle 41616 1 0 07:00:59 - 0:44 oracleprod
oracle 43460 1 0 02:45:05 - 0:53 oracleprod
oracle 25754 1 0 08:10:03 - 1:01 oracleprod
oracle 17402 1 0 07:27:04 - 2:06 oracleprod
oracle 14922 1 0 01:01:46 - 2:54 oracleprod
oracle 13168 1 0 05:33:06 - 3:15 oracleprod
oracle 26164 1 0 12:57:10 - 4:54 oracleprod >lsdev
Character Block Driver Class
0 -1 cn pseudo
3 -1 mm pseudo
16 -1 ptym ptym
17 -1 ptys ptys
27 -1 dmem pseudo
28 -1 diag0 diag
46 -1 netdiag1 unknown
52 -1 lan2 lan
uerf -r 300 | grep -i mem
>prtconf|grep -i mem
Memory size: 2048 Mbytes
memory (driver not attached)
virtual memory (driver not attached)
spcre: semget error, unable to get first semaphore set.
|
Operating System
|
Utility
|
|---|---|
|
HP-UX
|
SAM
|
|
SCO
|
SYSADMSH
|
|
AIX
|
SMIT
|
|
Solaris
|
ADMINTOOL
|
>grep error /var/adm/syslog/syslog.log|more
May 1 20:30:08 sprihp01 syslog: NetWorker media:
(warning) /dev/rmt/c5t6d0BESTn reading: I/O error
>errpt -a|more
-------------------------------------------
LABEL: CORE_DUMP
IDENTIFIER: C60BB505
Date/Time: Tue May 9 10:34:47
Sequence Number: 24908
Machine Id: 000138644C00
Node Id: sp2k6n03
Class: S
Type: PERM
Resource Name: SYSPROC
Server1>top
System: corp-hp9 Thu Jul 6 09:14:23 2000
Load averages: 0.04, 0.03, 0.03
340 processes: 336 sleeping, 4 running
CPU states:
CPU LOAD USER NICE SYS IDLE...
0 0.06 5.0% 0.0% 0.6% 94.4%...
1 0.06 0.0% 0.0% 0.8% 99.2%...
2 0.06 0.8% 0.0% 0.0% 99.2%...
3 0.06 0.0% 0.0% 0.2% 99.8%...
4 0.00 0.0% 0.0% 0.0% 100.0%...
5 0.00 0.2% 0.0% 0.0% 99.8%...
--- ---- ----- ----- ----- -----...
avg 0.04 1.0% 0.0% 0.2% 98.8%...
... BLOCK SWAIT INTR SSYS
... 0.0% 0.0% 0.0% 0.0%
... 0.0% 0.0% 0.0% 0.0%
... 0.0% 0.0% 0.0% 0.0%
... 0.0% 0.0% 0.0% 0.0%
... 0.0% 0.0% 0.0% 0.0%
... 0.0% 0.0% 0.0% 0.0%
... ----- ----- ----- -----
... 0.0% 0.0% 0.0% 0.0%
>ls -alt|head
-rw-r----- 1 ... 52429312 May 11 07:00 arlog272.arc
-rw-r----- 1 ... 393829 May 10 20:20 arlog21.arc.Z
-rw-r----- 1 ... 19748689 May 10 20:03 arlog27.arc.Z
-rw-r----- 1 ... 16018687 May 10 08:05 arlog26.arc.Z
>ls -alc|tail
-rw-r----- 1 ... May 09 05:02 archlog263.arc.Z
-rw-r----- 1 ... May 09 05:03 archlog264.arc.Z
-rw-r----- 1 ... May 10 05:02 archlog265.arc.Z
-rw-r----- 1 ... May 10 05:02 archlog266.arc.Z
-rw-r----- 1 ... May 10 05:02 archlog267.arc.Z
-rw-r----- 1 ... May 10 05:02 archlog268.arc.ZROOT>df -k
/home(/dev/vg00/lvol5): 20166 total allocated Kb
4945 free allocated Kb
15221 used allocated Kb
75 % allocation used
/opt (/dev/vg00/lvol6):615914 total allocated Kb
227403 free allocated Kb
388511 used allocated Kb
63 % allocation used
/tmp (/dev/vg00/lvol4):64215 total allocated Kb
20564 free allocated Kb
43651 used allocated Kb
67 % allocation used
/u01 (/dev/vg01/u01 ):17580720 total allocated Kb
12117048 free allocated Kb
5463672 used allocated Kb
31 % allocation used
ROOT>lvdisplay /dev/vg00/u01
--- Logical volumes ---
LV Name /dev/vg00/lvol3
VG Name /dev/vg00
LV Permission read/write
LV Status available/syncd
Mirror copies 1
Consistency Recovery MWC
Schedule parallel
LV Size (Mbytes) 140
Current LE 35
Allocated PE 70
Stripes 0
Stripe Size (Kbytes) 0
Bad block off
Allocation strict/contiguous
IO Timeout (Seconds) default # Loop through each database name
# on the host /etc/oratab.
for db in `cat /etc/oratab|egrep ':N|:Y'|\
grep -v \*|cut -f1 -d':'`
do
# Get the ORACLE_HOME for each database.
home=`cat /etc/oratab|egrep ':N|:Y'|\
grep -v \*|grep ${db}|cut -f2 -d':'`
echo " "
echo "database is $db"
cd $home/network/admin
ln -s /etc/tnsnames.ora\
$home/network/admin/tnsnames.ora
done
Return to Unix for Oracle DBAs Pocket Reference