You are on page 1of 2

AIX QuickSheet Devices Networking

Version: 2.0.0 List all devices on a system The entX is the physical device. It is associated with physical layer
Date: 8/28/9 lsdev settings such as link speed, and duplex. enX and etX determine the
List all disk devices on a system (See next item for a list of classes) frame type run on entX . IP addresses are configured on enX (Standard
Filesystems lsdev -Cc disk Ethernet) or etX (802.3). Typically only enX is used.
hd1 /home List all customized (existing) device classes (-P for complete list) The examples here assume that the default TCP/IP configuration
hd2 /usr lsdev -C -r class (rc.net) method is used. If the alternate method of using rc.bsdnet
hd3 /tmp Remove hdisk5 is used then some of these examples may not apply.
hd4 / root rmdev -dl hdisk5 Determine if rc.bsdnet is used over rc.net
hd5 BLV (Boot Logical Volume) Get device address of hdisk1 lsattr -El inet0 -a bootup option
hd6 Paging space getconf DISK DEVNAME hdisk1 or bootinfo -o hdisk1 TCP/IP related daemon startup script
hd8 JFS2 log Get the size (in MB) of hdisk1 /etc/rc.tcpip
hd9var /var getconf DISK SIZE /dev/hdisk1 or bootinfo -s hdisk1 To view the route table
hd10opt /opt List all disks belonging to scsi0 netstat -r
hd11admin /admin New in 6.1 lsdev -Cc disk -p scsi0 To view the route table from the ODM DB
livedump /var/adm/ras/livedump New in 6.1 TL3 Find the slot of a PCI Ethernet adapter lsattr -EHl inet0 -a route
/proc procfs pseudo filesystem lsslot -c pci -l ent0 Temporarily add a default route
Find the (virtual) location of an Ethernet adapter route add default 192.168.1.1
Remove mount point entry and the LV for /mymount lscfg -l ent1 Temporarily add an address to an interface
rmfs /mymount (Add -r to remove mount point) Find the location codes of all devices in the system ifconfig en0 192.168.1.2 netmask 255.255.255.0
Grow the /var filesystem by 1 Gig lscfg Temporarily add an alias to an interface
chfs -a size=+1G /var List all MPIO paths for hdisk0 ifconfig en0 192.168.1.3 netmask 255.255.255.0 alias
Grow the /var filesystem to 1 Gig lspath -l hdisk0 To permanently add an IP address to the en1 interface
chfs -a size=1G /var Find the WWN of the fcs0 HBA adapter chdev -l en1 -a netaddr=192.168.1.1 -a netmask=0xffffff00
Find the file usage on a filesystem lscfg -vl fcs0 | grep Network Permanently add an alias to an interface
du -smx / Temporarily change console output to /console.out chdev -l en0 -a alias4=192.168.1.3,255.255.255.0
List filesystems in a grep-able format swcons /console.out (Use swcons to change back.) Remove a permanently added alias from an interface
lsfs Get statistics and extended information on fcs0 chdev -l en0 -a delalias4=192.168.1.3,255.255.255.0
Get extended information about the /home filesystem fcstat fcs0 List ODM (next boot) IP configuration for interface
lsfs -q /home lsattr -El en0
Create a log device on datavg VG Tasks Permanently set the hostname
mklv -t jfs2log -y datalog1 datavg 1 Change port type of HBA (This may vary by HBA vendor) chdev -l inet0 -a hostname=bombay
Format the log device just created rmdev -d -l fcnet0 List networking devices
logform /dev/datalog1 rmdev -d -l fscsi0 lsdev -Cc tcpip
chdev -l fcs0 -a link type=pt2pt List Network Interfaces
Kernel Tuning cfgmgr lsdev -Cc if
no is used in the following examples. vmo, no, nfso, ioo, raso, and Mirroring rootvg to hdisk1 List attributes of inet0
schedo all use similar syntax. lvmo uses different syntax. extendvg rootvg hdisk1 lsattr -Ehl inet0
Reset all networking tunables to the default values mirrorvg rootvg List (physical layer) attributes of ent0
no -D (Changed values will be listed) bosboot -ad hdisk0 lsattr -El ent0
List all networking tunables bosboot -ad hdisk1 List (networking layer) attributes of en0
no -a bootlist -m normal hdisk0 hdisk1 lsattr -El en0
Set a tunable temporarily (until reboot) Mount a CD/DVD ROM to /mnt Set (desired) speed is found through the entX device
no -o use isno=1 mount -rv cdrfs /dev/cd0 /mnt (for a CD) lsattr -El ent0 -a media speed
Set a tunable at next reboot mount -v udfs -o ro /dev/cd0 /mnt (for a DVD) Find actual (negotiated) speed, duplex, and link
no -r -o use isno=1 , Note the two different types of read-only flags. Either is Ok. entstat -d ent0
Set current value of tunable as well as reboot Create a VG, LV, and FS, mirror, and create mirrored LV , The interface must be up (ifconfig en0 up) for stats to be valid
no -p -o use isno=1 mkvg -s 256 -y datavg hdisk1 (PP size is 1/4 Gig) Set the ent0 link to Gig full duplex
List all settings, defaults, min, max, and next boot values mklv -t jfs2log -y dataloglv datavg 1 chdev -l ent0 -a media speed=1000 Full Duplex -P
no -L logform /dev/dataloglv , Auto Negotiation is another option
List all sys0 tunables mklv -t jfs2 -y data01lv datavg 8 (2 Gig LV) Turn off Interface Specific Network Options
lsattr -El sys0 crfs -v jfs2 -d data01lv -m /data01 -A yes no -p -o use isno=0
Get information on the minperm% vmo tunable extendvg datavg hdisk2 Get (long) statistics for the ent0 device (remove -d for shorter results)
vmo -h minperm% mklvcopy dataloglv 2 (Note use of mirrorvg in next example) entstat -d ent0 or netstat -v ent0
Change the maximum number of user processes to 2048 mklvcopy data01lv 2 , The results of entstat vary by device type. Virtual, physical, and
chdev -l sys0 -a maxuproc=2048 syncvg -v datavg IVE (LHEA) devices all produce different results.
Check to see if SMT is enabled lsvg -l datavg will now list 2 PPs for every LP List all open, and in use TCP and UDP ports
smtctl mklv -c 2 -t jfs2 -y data02lv datavg 8 (2 Gig LV) netstat -anf inet
Directory containing tunables settings crfs -v jfs2 -d data02lv -m /data02 -A yes List all LISTENing TCP ports
/etc/tunables/ mount -a netstat -na | grep LISTEN
Move a VG from hdisk1 to hdisk2 Remove all TCP/IP configuration from a host
ODM extendvg datavg hdisk2 rmtcpip
Query CuDv for a specific item mirrorvg datavg hdisk2 Flush the netcd DNS cache
odmget -q name=hdisk0 CuDv , Wait for mirrors to synchronize netcdctrl -t dns -e hosts -f
Query CuDv using the like syntax unmirrorvg datavg hdisk1 Hostname lookup order is determined using /etc/irs.conf,
odmget -q "name like hdisk?" CuDv reducevg datavg hdisk1 /etc/netsvc.conf and then $NSORDER. irs.conf and $NSORDER
Query CuDv using a complex query Find the free space on PV hdisk1 are typically not used.
odmget -q "name like hdisk? and parent like vscsi?" CuDv lspv hdisk1 (Look for FREE PPs) IP packets can be captured using iptrace / ipreport or tcpdump
Error Logging smitty FastPaths Memory / Swapfile
Error logging is provided through: alog, errlog and syslog. Find a smitty FastPath by walking through the smitty screens to List size, summary, and paging activity by paging space
alog - boot, console messages, NIM, others get to the screen you wish. Then Hit F8. The dialog will tell you lsps -a
errlog - hardware, kernel, and some apps what FastPath will get you to that screen. (F3 closes the dialog.) List summary of all paging space
syslog - Internet dameons, and apps lvm - LVM Menu lsps -s
Display the contents of the boot log mkvg - Screen to create a VG List the total amount of physical RAM in system
alog -o -t boot configtcp - TCP/IP Configuration lsattr -El sys0 -a realmem
Display the contents of the console log eadap - Ethernet adapter section Create a new paging device on rootvg of 64 PPs
alog -o -t console fcsdd - Fibre Channel adapter section mkps -a -s 64 -n rootvg
List all log types that alog knows chgsys - Change / Show characteristics of OS Extend the existing paging space by 8 PPs
alog -L users - Manage users (including ulimits) chps -s 8 hd6
Display the contents of the system error log devdrpci - PCI Hot Plug manger
errpt (Add -a or -A for varying levels of verbosity) etherchannel - EtherChannel / Port Aggregation NFS
Clear all errors up until x days ago. List all exported file systems
errclear x System Resource Controller exportfs
List info on error ID FE2DEE00 (IDENTIFIER column in errpt output) Most SRC based services are started from /etc/rc.tcpip Refresh exports after editing /etc/exports
errpt -aDj FE2DEE00 Start the xntpd service exportfs -av
Put a tail on the error log startsrc -s xntpd Temporarily export the /proj directory, allowing root access by server1
errpt -c Stop the NFS related services exportfs -i -o rw root=server1 /proj
List all errors that happened today stopsrc -g nfs (un)share(all) are symlinks to exportfs for Unix compatibility.
errpt -s date +%m%d0000%y Refresh the named service [mk|rm|ch]nfs are provided to maintain /etc/exports
To list all errors on hdisk0 refresh -s named
errpt -N hdisk0 List all registered services on the system Getting info about the system
To list details about the error log lssrc -a Find the OS, (ML/)TL (-r), and service pack version / date (-s)
/usr/lib/errdemon -l Show status of ctrmc subsystem oslevel -r or oslevel -s
To change the size of the error log to 2 MB lssrc -l -s ctrmc List all attributes of system
/usr/lib/errdemon -s 2097152 getconf -a
syslog.conf line to send all messages to log file Performance Monitoring (Denotes trace based tools.) Find the type of kernel loaded (use -a to get all options)
*.debug /var/log/messages CPU getconf KERNEL BITMODE
, AIX uses *.debug for all, not *.* mpstat, topas -P, w, lparstat, ps, iostat -tT 1, tprof, curt , bootinfo and getconf can return much of the same information,
Memory getconf returns more and has the grepable -a option.
vmstat, svmon, ps -o fields , topas, ipcs -m Find the level of firmware on a system
LVM Network I/O invscout or lscfg -pv
Put a PVID on a disk [ent|tok|fddi|atm]stat, netstat, netpmon, topas -E List all attributes for the kernel device
chdev -l hdisk1 -a pv=yes Disk I/O lsattr -El sys0
, PVIDs are automatically placed on a disk when added to a VG iostat, fcstat, lvmstat, filemon, fileplace, topas -D Print a dump of system information
Remove a PVID from a disk Application prtconf
chdev -l hdisk1 -a pv=clear truss, probevue, tprof, svmon -P pid , ps -o fields -p pid Get all page sizes supported on this system
List all PVs in a system (along) with VG membership topas pagesize -a
lspv The ~ character toggles to nmon-mode in topas
Create a VG called datavg using hdisk1 using 64 Meg PPs Other Users and Groups
mkvg -y datavg -s 64 hdisk1 Check for disk stat history collection List all settings for root user in grepable format
Create a LV on (previous) datavg that is 1 Gig in size lsattr -HEl sys0 -a iostat lsuser -f root
mklv -t jfs2 -y datalv datavg 16 Enable historical disk statistic collection List just the user names
List all LVs on the datavg VG chdev -l sys0 -a iostat=true lsuser -a id ALL | sed s/ id.*$//
lsvg -l datavg Find the fsize value for user wfavorit
List all PVs in the datavg VG Working with Packages lsuser -a fsize wfavorit
lsvg -p datavg List all files in bos.games fileset. Change the fsize value for user wfavorit
Take the datavg VG offline lslpp -f bos.games chuser fsize=-1 wfavorit
varyoffvg datavg Find out what fileset fortune belongs to. (/usr)/bin/sh and (/usr)/bin/ksh are the same file. Use bsh for
Remove the datavg VG from the ODM lslpp -w /usr/games/fortune the Bourne shell.
exportvg datavg List packages that are above the current OS level
Import the VG on hdisk5 as datavg oslevel -g Additional Information
importvg -y datavg hdisk5 Find packages below a specified (ML/)TL http://publib.boulder.ibm.com/infocenter/systems/scope/aix
Vary-on the new datavg VG (can use importvg -n) oslevel -rl 5300-05 http://www.redbooks.ibm.com/portals/unix
varyonvg datavg List all filesets Display error codes can be found in the Diagnostic Information for
List all VGs (known to the ODM) lslpp -L Multiple Bus Systems manual
lsvg List all filesets in a grepable or awkable format
List all VGs that are on line lslpp -Lc About this QuickSheet
lsvg -o Find the package that contains the filemon utility Created by: William Favorite (wfavorite@tablespace.net)
Check to see if underlying disk in datavg has grown in size which fileset filemon Updates at: http://www.tablespace.net/quicksheet/
chvg -g datavg Install the database (from CD/DVD) for which fileset Disclaimer: This document is a guide and it includes no express war-
Move a LV from one PV to another installp -ac -d /dev/cd0 bos.content list ranties to the suitability, relevance, or compatibility of its contents with
migratepv -l datalv01 hdisk4 hdisk5 Create a mksysb backup of the rootvg volume group any specific system. Research any and all commands that you inflict
Delete a VG by removing all PVs with the reducevg command. mksysb -i /mnt/server1.mksysb.date +%m%d%y upon your command line.
reducevg hdisk3 (-d removes any LVs that may be on that PV) Cleanup after a failed install Distribution: The PDF version is free to redistribute as long as credit
Note: See additional examples in tasks section. installp -C to the author and tablespace.net is retained in the printed and viewable
versions. LATEXsource not distributed at this time.

You might also like