0% found this document useful (0 votes)
108 views

DB2 Administrators Unix Commands Surviva PDF

Uploaded by

rohit kumar
Copyright
© © All Rights Reserved
We take content rights seriously. If you suspect this is your content, claim it here.
Available Formats
Download as PDF, TXT or read online on Scribd
0% found this document useful (0 votes)
108 views

DB2 Administrators Unix Commands Surviva PDF

Uploaded by

rohit kumar
Copyright
© © All Rights Reserved
We take content rights seriously. If you suspect this is your content, claim it here.
Available Formats
Download as PDF, TXT or read online on Scribd
You are on page 1/ 7

DB2 Administrator’s Unix Commands Surival Sheets 3/2014

Path / File / Command Function Path / File / Command Function


.login Settings for Korn shell user at Execute Command later:
.profile Profile Script for Korn shell user at -m 0730 tuesday sort <f1 >f2
.Xauthority X-Window Scecurity Mechanism at now <enter> cmd
.Xdefault X-Window GUI settings at -l List defered Command Execution
.Xsession X-Window settings (wie .profile) banner text Creates big letters
/etc /init.d/... Solaris: Run Control Scripts, system-level independent bc Builtin Calculator
/rc.d/[rc{runlvl}|init].d/ AIX: Run Control Scripts, system-level independent bfs file AIX: Scans a file, displays requested lines
/etc/[profile|.login] Solaris+AIX: Initial Machine wide BSH/KSH Defaults Boot Process AIX AIX System Boot Sequence or changing Run Levels:
/etc/csh.cshrc 1st System-wide Setup File C Shell shutdown (script) or boot  init (program) 
/etc/csh.login 2nd System-wide Setup File C Shell (wenn verfügbar) /etc/inittab: sysinit + rc + per level: /sbin/rc.boot
/etc/default/... Solaris: Default-Umgebungseinstellungen lvl + /etc/rc 2 + /etc/rc.d/rc lvl 
/etc/default/init Solaris: Timezones, Locales, Language, Codepage /etc/rc.d/rclvl.d /[K|S][0-9]script (symbolic links to
/etc/default/login Solaris: Shell Defaults /etc/rc.d/init.d)  start or kill legacy systems
/etc/environment AIX: Shell Defaults (ulimit, umask, path etc.) Boot Process Solaris Solaris System Boot Sequence or changing Run Levels:
/etc/group User Group registry shutdown (script) or boot  init (program) 
/etc/inet/... Solaris: Inet Daemon Config (hosts,ipnodes,services) /etc/inittab: initdefault, /sbin/rc2 /etc/rc2 
© www.ruban.de

/etc/inittab System Initialization Table /etc/rc2.d  [K|S][0-9]script  start or kill


/etc/passwd User registry
/etc/rc{runlvl} legacy systems
Run Level Boot/Stop Commands bootinfo -K
/etc/rc{runlvl}.d/... AIX Kernel 32/64 Bit enabled, or ...
Boot/Stop Commands
/etc/security/limits ls –al /unix displays symbolic link to Unix Kernel
AIX User Limits (e.g. Hard and Soft File Sizes)
bootinfo –r AIX display real memory in kilobytes
/etc/services TCP/IP Dienste-Verzeichnis
bootinfo –y AIX display if the hardware is 32-bit or 64-bit
/etc/system Solaris System Kernel
cat [options] file View File
/etc/vfstab File System Description Table
-n - number lines
/home/user/.cshrc individual C Shell settings at login and every new C Shell
chmod mask file Change Access Modes:
/home/user/.login individual C Shell settings at login (nach .cshrc)
/home/user/.logout 3 x r/w/x/- for Owner/Group/other
individual log out processing
/home/user/.ssh/ Directory of Secure Shell identification data x=exec w=write r=read
/home[1]/user chmod -R m f Recurse into Sub Path's
Home Directory
/opt/IBM/db2/Vnn.n chmod u+s | g+s | +t Setuid-Bit, Setguid-Bit, Sticky-Bit (4000/2000/1000)
IBM DB2 installation path (see db2ls command)
/opt/IBM/db2/V9.1/ chown o.g file Change Owner o=owner/g=group
IBM DB2 V9.1 instance registry
profiles.reg chown –R o.g. f Change Owner, recurse into paths
/usr/[lpp|opt]/db2_... Obsolete AIX DB2 Package Library cleanipc inst-no remove SAP: like ipcrm, removes [shared] memory segments
/usr/sap/<sid>/SYS/exe/run SAP Executables, Utilities, User Exits clear clear terminal screen
/usr/sap/<SID>/SYS/profi- SAP R3 Executables, Utilities, User Exits cmd | grep –o s filter with options ans search patterns
le/DEFAULT.PFL -i ignore case (upper/lower caps)
/var/adm/{ras|log} wichtige System Log Files cmd |{pg|more} Writes to console page by page controlled by user
/var/db2/vxx/defaults.env Obsolete DB2 DB2 V8.x-- 9.1 registry and environment compress file Compress (see uncompress)
/var/db2/global.reg DB2 DB2 V9.7++ registry and environment cp f1 d2 Copy of file1 to directory2
^c Interrupt processing cp f1 f2 Copy of file1 to file2
^d ends user data input cp –opt f1 f2|d2 -f unlink -i prompt before overwrite
<Esc>+k | <Esc>+j Command Editor vi: previous | next command (scroll) -p preserve permissions-r recurse into subdirs
admintool Solaris Admin GUI (X-Window) cpio parms Copy Files into or from an Archive, for example
alias [shortcut="cmd"] Pseudonym or Shortcut for a command or cmd series, find . –print | cpio -ov Copy all File of Directory to Disk
alias r='fc -s' e.g. simple 'repeat last command' as "r" >/dev/rfd0
apropos keyword Hinweise zu Schlüsselwörtern crontab -l List of (planned) crontab activities
© www.ruban.de, Boeblingen, Germany DB2 administrator’s Unix commands survival sheets for AIX and Solaris page 1
DB2 Administrator’s Unix Commands Surival Sheets 3/2014

Path / File / Command Function Path / File / Command Function


curt -i AIX: CPU Utilization Reporting Tool db2pd Information from the DB2 memory sets (sysadm):
date [format] Shows date [in different formats] -inst Instance-Scope Info -everything all DB Info
db2am DB2 Activity Monitor (use client GUI) -alldbs all Databases -dynamic SQL Statements
db2batch -d database -a DB2 benchmark tool, in-line options: -osinfo Operating System -tcbstats TBSpace Info
user/psw -f input.sql -i --#SET ROWS_FETCH -1 to n -apinfo Application related info
long -r output.OUT --#SET ROWS_OUT -1 to n db2pdcfg [-catch|-cos par] DB2 Call-Out Script for problem determination:
--#SET PER_DETAIL {1-5} -catch status|clear|'....' (eg.
1 (deflt.) Elapsed Time only 'deadlock|timeout')
2 Appl Snapshot + Elapsed Time -cos status|on|off|...
3 DBM/DB/Appl Snapshot + Elapsed Time db2support –d db –m –n no Creates DB2 Support (Zip) File for IBM technical support
4 DBM/DB/Appl/Stmt Snapshot + Elapsed Time db2top DB2 interactive snapshot monitor (more, see appendix)
5 like 4+buffer pools, table spaces and FCM db2trc on Starts DB2 trace:
--#SET ERROR_STOP {YES|NO} ... ... issue command or start DB2 application
--#SET DELIMITER delim db2trc dmp db2trc.dmp Dump Trace into File
--#SET SLEEP 1 to n db2trc off Trace off,
--#SET PAUSE db2trc flw db2trc.dmp Trace flow and
--#SET SNAPSHOT snapshot
© www.ruban.de

db2trc.flw Trace format into separate file


--#SET TIMESTAMP db2trc fmt db2trc.dmp
--#SET TIMING {ON|OF} db2trc.fmt
--#BGBLK [repeat_count] dbx –a <pid> | <file> Debugging eines Binaries oder eines lfd. Prozesses,
--#COMMENT comment detach <pid> ohne detach wird <pid> beendet.
--#EOBLK quit (im Anschluß gencore <pid> <file>)
db2dart db /tsi n /rhwm Simple reduction of a DB2 tablespace highwater mark. df -k Display Free KB Block on File Systems
Complex reduction: Use arguments /lhwm /NP 0 diff f1 f2 Differences between Files
db2diag db2diag logs analysis tool command diff -rsl f1 f2 Differences, recurse, long, all files
–gi filter case insensit db2diag -gi "level=severe" -H period diagpath/db2diag.log disp+work -v SAP R/3 Release Level Display
component db2diag -gi component="Automatic Table dmesg Solaris Display System Messages
Maintenance",stopevent:="""success""" -l event -H period dpmon pf=profile SAP R/3 Display Queue Statistics, numerous arguments,
diagpath/db2diag.log profile in /sapmnt/<SSID>/profile
db2diag -gi "msg:=msgtxt" -H period diagpath/db2diag.log dscdb6up <user> <password> SAP R/3: login and change pwd for users <sapsid>adm
message >> output-file
-H nn M|D|H|m|s and sap<sapsid> or sapr3
dscdb6up –create <connect SAP R/3 password regeneration after change of
user pwd> <sapsid_adm pwd> DB2DB6EKEY environment variable.
db2fm –i inst –f|-a on|off Fault Monitor per Instance options, see also
dscdb6up –create SAP R/3 set password in case of loss or loss of
./sqllib/fm.[hostname].reg
<sap<sapsid>|sapr3 pwd> configuration file dscdb6.conf
db2fmcu –d Stops db2fmcd daemon Fault monitor process and
<<sapsid>adm pwd>
removes entry from /etc/inittab (see /db2-inst-path/bin) du -k
db2greg {–dump –g –v} Disk Usage in KB,
Displays DB2 V9.x global registry file name and content
db2ls -a for each file -s Summary
Lists installed DB2 product paths
[-q -b /opt/IBM/db2/V9.7] egrep opt "string" file Extended grep Command:
and all installed features of DB V9.7
db2mtrk -i -d -p –m -c -i - count results - ignore case
DB2 Memory Tracker: Report of Memory Status for
[-v] [-r n n] -e pattern - search for patterns, egrep -l -e "(sed|awk)" *
Instances, Databases and Agents
-l - print only files names with matches
db2osconf Recommendations for Solaris Kernel values (root Users):
-h Help Screen -f compare to current -l List current eject Eject (e.g. CD-Rom)
errpt [-a] AIX Error Reporting, auch im Detail

© www.ruban.de, Boeblingen, Germany DB2 administrator’s Unix commands survival sheets for AIX and Solaris page 2
DB2 Administrator’s Unix Commands Surival Sheets 3/2014

Path / File / Command Function Path / File / Command Function


exec </dev/tty Reassigns standard input back to the keyboard head -nnn file die ersten nnn Zeilen einer File ausgeben
exec <&- | exec >&- Closes standard input | output history See "fc -l", set history=nn
exec >filename Reassigns standard output from terminal display to a file ifconfig –a Display machine IP address
exec >/dev/tty Reassigns stardard output back to terminal install|patch /var/sadm/ Solaris Packages: versions and patches (e.g. FixPaks)
exit End Session/Shell instfix -i [-k n] AIX List Installed Fixes “IXnnnnnn“
export DISPLAY=ipaddr:0 Redirection of X-Window screen output instfix -i | grep ML AIX Maintenance Level, watch text „All filesets for ...“, also
fc [-l | -s nn] Command History File, list or start cmd see oslevel
file file Classify File Content/Type ioo –L AIX display tunables characteristics
filemon AIX File Access Monitor, Performance: iostat –s System AIX File System Performance
filemon –v –o ofile –O all iostat –a Adapter (History active? lsattr -E -l sys0 -a iostat)
dd if=file1 of=file2 bs=1k count=100000 iostat -xnP Solaris File System Performance (detailled Device)
trcstop ipcrm {-m|-q|-s} id Remove IPC’s (-m=Shared Memory,
fileplace options file Placement of file in LV and/or PV -q=Message, -s=Semaphore-ID
–p physical volume -l logical volume ipcs [-ma] Interprocess Communication System , Shared Memory
-i indirect blocks -v details, degree of fragmentat. Usage Status anzeigen
find . -name f1 Suche File f1 in diesem Pfad und allen Subdirs jobs -l PID und Working Dir von Jobs
© www.ruban.de

find . -type f –name Suche alle Files (Type f) mit Namen test* in diesem und kill -9 pid Kill pid immediatelly and all children
“test*” -print -exec allen Unterverzeichnissen, gebe den Namen aus (Signal Kill SIGKILL=9, see kill -l)
grep -i "ruban" {} \; durchsuche sie per grep Command nach String “ruban” kill pid Kill Process mit ID pid
finger -s Short Infos on active Users last Display Last Logins
finger user Find Infos about User leave hhmm Wecker
ftp File Transfer Programm: listusers List User Login Information
open host llstatus AIX SP: information on Load Leveler machine status
user user psw ln -opt sf tf Make Links from Source to Target File
get|put file [file]
-s Symbolic Link -f replace existing link
close and quit
lqueryvg -At -p hdisk0 AIX all attributes for the VG (Disks, see lspv)
fusage Solaris Disk Access Statistics
fuser [opt] ls options file List Directory Structure
Lists the process numbers of local processes that use the
device local or remote files specified by the File parameter: -al lange Liste mit Attributen -R recurse subdirs
path - open files in the file system –t sortiert nach Timestamp -u ‘used’ timestamp
-c - open files which have been unlinked lsattr -E -l device AIX Show Device Attributes, e.g. Disk Device
-d - SIGKILL signal to process (root only) lsattr -El sys0 -a realmem AIX Display Real Memory
-k - login name for local processes using lscfg | grep proc AIX Display Number of Processors
-u - executable/loadable objects (with -c or -f) lscfg -vp | pg AIX Hardware Information
-x lsconf AIX List Configuration (see also prtconf)
getconf –a AIX: Configuration Information lsdev –C –H AIX Device Information of customized devices
grep opt pat f Search File f for Pattern pat with Option opt lsfs [-q] AIX List file systems (and spec. attributes, also see
-i -n ignore case print line numbers /etc/security/limits [bf:true=large file]
-l print only names of files with matching lines lsmle –c AIX List of system-defined locale definitions /usr/lib/nls/
grep -v '^$' fin > fout Remove blank lines from file fin, creates file fout. lslpp -l AIX List installed Software Packages
grep '.' fin > fout lslpp -qLc AIX query and report installed Software e.g. for compare
sed '/^$/d' fin > fout lsps option AIX Display Paging Space:
sed -n '/^$/!p' fin>fout -a display size –s summay/usage
awk NF fin > fout lspv [-p|l|L disk] AIX List Physical Volumes and Volume Groups
awk '/./' fin > fout lsvg {–l|-L} vg-name AIX LV’s in VG | VG attributes
groups Show Group Membership of User lsvg -L -n device AIX Display VG on a physical device e.g. hdisk
© www.ruban.de, Boeblingen, Germany DB2 administrator’s Unix commands survival sheets for AIX and Solaris page 3
DB2 Administrator’s Unix Commands Surival Sheets 3/2014

Path / File / Command Function Path / File / Command Function


lsvg -o | lsvg -i -l AIX Display Logical Volumes sorted by Volume Groups rm -opt file Delete/Remove Files: -f force without prompting
lsvgfs name AIX Displays list of file systems belonging to a VG -i ask for confirmation -R/r recurse into subdirectories
lvmstat –l|-g name AIX LV Statistics (like iostat but on LV’s or VG’s) Run Levels | Init states 0: power-down state
man cmd Manual Pages zu Unix Commands 1: administrative state
memlimits SAP R/3 address space configuration test tool 2: multiuser state
metastat [-s id –i –t –p] Solaris Metadevice Information (LVM, s.a. lsvg, lslv) 3: dflt., multi user operation, all resources avail.
mount [all] Show Device Table or mount if /etc/filesystems 4: alternative multiuser state
indicates ‘mount=true’ (also: smitty mount) 5: power-down state
mpstat Solaris Processor Status ( pstat -S) 6: reboot with initdefault in /etc/inittab (i.e. 3)
mv -opt f f|d Move/Rename File to File|Directory S: single user (root) access only
netstat/nfsstat Network activity rup Up Time Remote Machine
newgrp group Log in with another Group (non-primary) saposcol –h SAP R3 Operating System Data Collector,
nmon AIX readl-time monitor, see also on page 5 saposcol -v SAP release and patch information (see also disp+work)
nslookup ip-addr|name Name Server Look-up function sar -opt t n System Activty Reporter (siehe sa1, sa2, sadc in man)
oslevel [-r|-g] AIX Maintenance Level, oder alternativ siehe instfix -s hhmm Startzeit -u CPU -r Memory
oslevel –s -e hhmm Endezeit -g Paging -v Processes
AIX Base Level-Technology Level-Service Pack:YYWW
© www.ruban.de

passwd [-d] [login name] Passwowrt ändern/löschen -d Disk I/O -P ALL per Processor Statistics
perl -MDBI -e 'DBI-> Listet Versionen der Perl Database Interfaces (auch DB2 schedo –L AIX the current, default, and reboot settings
installed_versions' unter DBD::DB2) scp –B usr@server:file –v Secure copy from server in batch and verbose mode
perl –V Perl Version, stored at ls –al `which perl` scp file usr@serv:/path Secure copy to remote server
perspectives AIX: Invokes SP Perspectives GUI scp usr@server:/path/file Secure copy from remote server to local server
pkginfo -l List installed Solaris Software Packages /local-path/file
pprof <time> AIX Measure CPU usage of Kernel Threads sendmail ricipient-list SMTP Send Mail
prstat [-a] set -o vi Editing Commands as used in vi
Solaris report active process statistics ( top/topas)
set -vx Shell Script Debugging
prtconf System Configuration Info (see also lsconf)
setenv DISPLAY ip-addr:0.0 Route X-Windows output to specific console
prtdiag System Diagnostics
showipc instance-no SAP: wie ipcs, Anzeige von Memory Segments
ps Report Process Status
showrev [-p] Solaris Systemeigenschaften/ Patch Level
-ef Full List all Processes
shutdown -Fr AIX Fast Reboot
-l Long Listing
shutdown -i6 Solaris: Shutdown and reboot (see Run Levels)
-o format
smitty Interaktive AIX Command Konsole
ps  von /usr/ucb Extended UCB Process Status smitty nfs -> NFS -> Add a directory to Export List ->
-a all -S accum CPU Time
/export/samplepath (Export now/at system restart)
-x w/o Terminal -l Long Listing snap AIX: collecting system informationen (root required)
ps au Display Commands and Arguments spmon AIX SP Monitor: -d Display
ps -efo THREAD AIX Full List of all Threads in process -power off|on node1 Strom aus|an
ps eww [pid] Display Environment Variables of process id ssh-copy-id -i Copies SSH ID file to remote server and appends it to
psrinfo Solaris Processor Information ~/.ssh/id_{rsa|dsa}.pub ~/.ssh/authorized_keys. Then sftp/ssh/scp needs no psw
pstat -f AIX Display interpretation of various system tables, e.g. user@remote-system
(various flags) -a|-p process table, -f file table, -S processors, -s ssh-keygen [-t rsa|dsa] Creates SSH key pair ID file at local server ~/.ssh
swap and paging space usage starsap [r3|db|all] SAP R3 Start Script Instance and/or Database
ptree –a pid|uid Solaris show process tree startx AIX Start X-Windows Session (see DISPLAY)
pwconv erzeugt /etc/shadow aus /etc/passwd stopsap [r3|db|all] SAP R3 Stop Script Instance and/or Database
pwd Print Current Working Directory su [-] user Switch to another User [- changes env]
-c cmd Execute cmd, then return

© www.ruban.de, Boeblingen, Germany DB2 administrator’s Unix commands survival sheets for AIX and Solaris page 4
DB2 Administrator’s Unix Commands Surival Sheets 3/2014

Path / File / Command Function Path / File / Command Function


svmon AIX Memory Usage Monitor id CPU idle time
sysdef -i Solaris System Resource Limits wa waiting on I/O
tail -nnn file show last nnn rows of a file page ins page is read from disk to memory
tar switches archive Process Archive File pages outs writing pages to disk
[files] -xvf Extract File -cf Create File paging space page ins only pages read f. paging spc
tee -a file Display and writes output to file paging space page outs only pages writtem f. pag.space
e.g. ls -al | tee -a directory.txt w[-hsuw] Current System Activity (1, 5, 15 Minuten)
time cmd Elapsed/System/User Time for Command wc -opts file Word Count
top|topas Report local system information ( prstat) -w Words -l Lines
topas_nmon AIX real-time monitor, see also on page 5 whereis name Locate binary, source, man page in /usr/...
tr Deletes or substitutes Characters which cmd Pathname of Command
tr '{}' '()' < f1 > f2 - wandelt Klammern um who [am i] who is on system, what is my account
tr -d '\015' < in > out – remove ^M (DOS CR/LF) -b Last System Boot Time
traceroute ip-addr Trace der IP-Strecke -r System Run Level (usually with boot time)
tvi file Line Editor Full Screen whodo –l Jobs being performed by users on the system.
uuencode infile > outfile Converts a binary file to an ASCII file, wlmcheck AIX: WLM Checking classes and rules for 'current'
© www.ruban.de

uudecode infile and this command vice versa configuration


ulimit –[H]a All (Hard) User Limits wlmstat AIX: WLM Resource Utilization Status
umask [mask] default mask for user files (use complement) wsm AIX: System Manager Start (X-Win, von Telnet aus)
uname –M|m AIX Display Machine Type/Model and ID xargs options cmd Constructs parameter lists and runs commands, it
uncompress file Uncompress (siehe Comress) receives input from standard input. Some examples:
uptime System Load der letzten 1/5/15 Min. -I char replacement char Snapshot view of a path:
vi file Browse/Edit File ls -al * | xargs -I date +"Snapshot %Y-%m-
:q quit :q! quit w/o save %d-%H.%M.%S: {}"
:w write file esc-dd remove row Append header and footer to files, merge output:
ls *.cbl | xargs -I {} cat BEG.incl {}
esc-x del char esc-shift-a end END.incl > copybook.cbl
esc-i insert char esc-o inser row Append header and footer to individual output files:
vi file Line Editor ls *.cbl | xargs –I {} sh -c "cat BEG.incl
vmo –L AIX Virtual Memory information '{}' END.incl > '{}.out'"
vmstat [opts intval count] Statistics: Processes, Memory, Paging, Faults, CPU, Disk Xsession  /usr/dt/bin/ Start CDE X-Window session client
-s summary r kernel threads on run queue, run-able threads
-i interrupts sinc startup b avg number of kernel threads on wait queue
-v VMM statistics avm number of pages allocated to paging space
-t prints timestamp free number of free memory frames ( 4KB)
re number (rate) of pages reclaimed
pi no. (rate) of pages paged in from paging space
po no. (rate) of pages paged out to paging space
fr number (rate) of pages freed (VMM LRU)
sr no. (rate) pages scanned by LRU daemon
cy rate of complete scans of Page Frame Table
in number (rate) of device interrupts
sy number (rate) of system calls
cs number (rate) of context switches
us percent of CPU time spent in user mode
sy percent of CPU time spent in system mode

© www.ruban.de, Boeblingen, Germany DB2 administrator’s Unix commands survival sheets for AIX and Solaris page 5
DB2 Administrator’s Unix Commands Surival Sheets 3/2014

db2top - interactive monitor (9.7): (Windows not supported!) db2top -d dbname -f collect.file.bin -b b > bpout
db2top [-d dbname] [-n nodename] [-u username] [-p password] db2top -d dbname -f collect.file.bin -b T > tbout
[-V schema] [-i interval] [-P <part>] db2top -d dbname -f collect.file.bin -b D > sqlout
[-a] [-B] [-R] [-k] [-x] [-f file <+time> </HH:MM:SS>] db2top -d dbname -f collect.file.bin -b s > stmtout
[-b options [-s <sample>] [-D separator] <-X>] db2top -d dbname -f collect.file.bin -b U > lockout
-o outfile]] [-C [option]] [-m duration] db2top -d dbname -f collect.file.bin -b u > utilout
db2top –h (this help) db2top -d dbname -f collect.file.bin -b F > fedout
-d : Database name (default DB2DBDFT) db2top -d dbname -f collect.file.bin -b m > memout
-n : Node name
-u : User name
-p : User password topas_nmon | nmon Monitor:
-V : Default explain schema h = Help information q = Quit nmon 0 = reset peak counts
-i : Interval in seconds between snapshots + = double refresh time - = half refresh r = ResourcesCPU/HW/MHz/AIX
-b : background mode c = CPU by processor C=upto 128 CPUs p = LPAR Stats (if LPAR)
option: d=database, l=sessions, t=tablespaces, l = CPU avg longer term k = Kernel Internal # = PhysicalCPU if SPLPAR
b=bufferpools, T=tables, D=Dynamic SQL, s=Statements, m = Memory & Paging M = Multiple Page Sizes P = Paging Space
U=Locks, u=Utilities, F=Federation, m=Memory d = DiskI/O Graphs D = diskIO+service times o = Disks %Busy Map
-X=XML Output -L=Write queries to ALL.sql,
© www.ruban.de

a = Disk Adapter e = ESS vpath stats V = Volume Group stats


-A=Performance analysis ^ = FC Adapter (fcstat) O = VIOS SEA (entstat) v = Verbose=OK/Warn/Danger
-o : output file for background mode n = Network stats N=NFS stats (NN for v4) j = JFS Usage stats
-a : Monitor only active objects A = Async I/O Servers w = see AIX wait procs "="= Net/Disk KB<-->MB
-B : enable bold b = black&white mode g = User-Defined-Disk-Groups (see cmdline -g)
-R : Reset snapshot at startup t = Top-Process ---> 1=basic 2=CPU-Use 3=CPU(default) 4=Size 5=Disk-I/O
-k : Display cumulated counters u = Top+cmd arguments U = Top+WLM Classes . = only busy disks & procs
-x : Extended display W = WLM Section S = WLM SubClasses ~ = Switch to topas
-P : Partition snapshot (number or current) [ = Start ODR ] = Stop ODR Help: topas_nmon -?| nmon -?
-f : Replay monitoring session from snapshot data collector
file, can skip entries when +seconds is specified
-D : Delimiter for -b option
-C : Run db2top in snapshot data collector mode, see –b options
-m : Max duration in minutes for -b and -C
-s : Max # of samples for –b
-A : automatic performance analysis (in batch mode)

Parameters can be set in $HOME/.db2toprc, type w in db2top to


generate resource configuration file

#-- Collect Mode in batch


db2top -d dbname -f collect.file.bin –C D -m 60 -u user -p password
#-- Replay mode with auto analysis:
db2top -f collect.file.bin -d dbname -b D -A
#-- Replay mode, jump to interesting time:
db2top -d dbname -f collect.file.bin /02:00:00
#-- Create snapshots and save in different output files
db2top -d dbname -f collect.file.bin -b d > dbout
db2top -d dbname -f collect.file.bin -b l > sessionout
db2top -d dbname -f collect.file.bin -b t > tbspaceout

© www.ruban.de, Boeblingen, Germany DB2 administrator’s Unix commands survival sheets for AIX and Solaris page 6
DB2 Administrator’s Unix Commands Surival Sheets 3/2014

Supported Languages and Locales: (Excerpt of important languages) Kernel Processes AIX 4.3/5.xL/6.xL (kprocs):
Codepage aios Relates to Asynchronous I/O kernel process
OS Language Country or category Locale cdpg A kernel daemon that deals with CDRFS filesystems and is started only when a
Codeset
IBM-1252 Windows German Germany de_DE.IBM-1252 CD based filesystem is mounted.
dlci A kernel process dealing with Data Link Control protocol. You will see this kproc
ISO8859-1 Unix German Germany de_DE
mostly on systems using old protocols such as SNA. Some old printers also use
ISO8859-15 Unix German Germany de_DE.8859-15 this protocol.
UTF-8 Unicode German Germany DE_DE dog A kproc spawned by the netinet driver and deals with IP packet switching. The
273|1141 z/OS German Germany IBM-273|IBM-1141 concept of dog process also came from Open Software Foundation (OSF).
IBM-1252 Windows English United States en_US.IBM-1252 gil GIL term is an acronym for "Generalized Interrupt Level" and was created by the
ISO8859-1 Unix English United States en_US Open Software Foundation (OSF), This is the networking daemon responsible for
processing all the network interrupts, including incoming packets, tcp timers, etc.
ISO8859-15 Unix English United States en_US.8859-15 lvmbb A kernel process associated with LVM device driver.
UTF-8 Unicode English United States EN_US jfsc This is a JFS daemon that does compression/decompression for compressed file
37|1140 z/OS English United States IBM-37|IBM-1140 systems. It is started when you mount a locally locally mounted compressed file
IBM-1252 Windows Italian Italy it_IT.IBM-1252 system. It should go away when there are no mounted compressed file systems.
ISO8859-1 Unix Italian Italy it_IT You can use the dumpfs command to check if you have any compressed file
© www.ruban.de

ISO8859-15 Unix Italian Italy it_IT.8859-15 systems.


j2pg Kernel process integral to processing JFS2 I/O requests.
UTF-8 Unicode Italian Italy IT_IT
jfsz JFS zero'ing kproc, allocate/zeros out disk blocks on 'bigfile' filesystems.
280|1144 z/OS Italian Italy IBM-280|IBM-1144 kbio NFS biod threads -- works just like a biod process.
IBM-1252 Windows French France fr_FR.IBM-1252 lrud Least recently Used Daemon or "page-stealer" is dispatched when the Virtual
ISO8859-1 Unix French France fr_FR Memory Manager (VMM) needs to free memory. There is one of these kprocs for
ISO8859-15 Unix French France fr_FR.8859-15 each memory pool (Default: number of CPUs/8, minimum number of memory
UTF-8 Unicode French France FR_FR pools1).
netm Network memory allocator that allocates pinned memory for use via netmalloc
297|1147 z/OS French France IBM-297|IBM-1147
kernel services.
IBM-1252 Windows Spanish Spain es_ES.IBM-1252 reaper A kernel process that deals with cleaning up defunct processes.
ISO8859-1 Unix Spanish Spain es_ES rtcm RPC transport connection manager used by the NFS kernel extension.
ISO8859-15 Unix Spanish Spain es_ES.8859-15 swapper Part of the kernel scheduler and schedules threads on the processors' run queue.
UTF-8 Unicode Spanish Spain ES_ES wlmsched Kernel process that aids Work Load Manager. Usually, inactive (but in process
284|1145 z/OS Spanish Spain IBM-284|IBM-1145 table) unless WLM is being used.
xmgc A kernel process that deals with garbage collection for kernel memory allocated via
xmalloc and xmfree kernel services.
There are some kprocs that directly influence performance. These kprocs still do not have a
user interface but their behavior can be influenced.
aios The min and max number of this kproc can be tuned via SMIT.
smit chgaio —> Minimum number of servers and MAXIMUM number of servers
lrud Behavior of this kproc can be influenced by vmtune/vmo's options. The most
common options are when it is dispatched (minfree) and what type of memory
pages ity prefers (maxperm and maxclient).
swapper The swapper's behavior can be influenced by tuning with schedtune or schedo.

© www.ruban.de, Boeblingen, Germany DB2 administrator’s Unix commands survival sheets for AIX and Solaris page 7

You might also like