Topics: Hardware, Installation
Power 5 color codes
Ever noticed the different colors on parts of Power5 systems? Some parts are orange, others are blue. Orange means: you can touch it, open it, remove it, even if the system is running. Blue means: don't touch it if the system is active.
An AIX system should have a single default gateway defined. However, sometimes, it does occur that a system has multiple default gateways. Here's information to detect multiple default gateways and how to get rid of them:
First, obtain how many gateways there are:
# odmget -q "attribute=route" CuAt
CuAt:
name = "inet0"
attribute = "route"
value = "net,-hopcount,0,,0,192.168.0.1"
type = "R"
generic = "DU"
rep = "s"
nls_index = 0
CuAt:
name = "inet0"
attribute = "route"
value = "net,-hopcount,0,,0,192.168.0.2"
type = "R"
generic = "DU"
rep = "s"
nls_index = 0
If there are more than one, you need to remove the excess route. For example, to remove the default route to 192.168.0.2:
# chdev -l inet0 -a delroute="net,-hopcount,0,,0,192.168.0.2"
Method error (/usr/lib/methods/chginet):
0514-068 Cause not known.
0821-279 writing to routing socket: The process does not exist.
route: not in table or multiple matches
0821-207 chginet: Cannot add route record to CuAt.
Then verify again:
# odmget -q "attribute=route" CuAt
CuAt:
name = "inet0"
attribute = "route"
value = "net,-hopcount,0,,0,192.168.0.1"
type = "R"
generic = "DU"
rep = "s"
nls_index = 0
If you get this error, you probably have one of the following things wrong:
- You've forgotten the slash and semicolon in the find command. Use find command like this:
# find /tmp -mtime +5 -type f -exec rm {} \;
- If you get this error from crontab, then you should add an extra slash to the slash and semicolon. Use the find command like this:
0 2 * * * find /tmp -mtime +5 -type f -exec rm {} \\;
If you wish to clone a system with a mksysb, then you can do so, but you do not want your cloned system to come up with the same TCP/IP information. Just issue rmtcpip before creating the mksysb, and you have a perfect image for cloning to another system. Be sure to issue this command at a terminal, as you will lose your network connection!
There are times that you would like to create some "load" on the system. A very, very easy way of keeping a processor very busy is:
# yes > /dev/nullThe yes command will continiously echo "yes" to /dev/null. This is a single-threaded process, so it will put load on a single processor. If you wish to put load on multiple processors, why not run yes a couple of times?
Topics: AIX, Monitoring, System Admin↑
Cec Monitor
To monitor all lpars within 1 frame, use:
# topas -C
Topics: AIX, SSA, Storage, System Admin↑
Renaming pdisks
If, for some reason, the pdisk and hdisk numbering of SSA disks is not sequential anymore, then there's a way to bring order in to chaos. Usually, the pdisk and hdisk numbering order are screwed up when you replace multiple disks together. Especially on HACMP clusters, a correct numbering of pdisks and hdisks on all nodes of the cluster, comes in handy.
Unmount all file systems on the specific disks, then varyoff the volume group:
# /usr/lib/methods/cfgssar -l ssarIf this doesn't help (it sometimes will), then renumber the disks manually:
Write down the pdisk names, hdisk names, location of the disks in the SSA drawer and the connection ID's of the disks. You can use lsdev -Cc pdisk to show you all the pdisks and the drawer and location codes. Use lsdev -Clpdiskx -Fconnwhere to show the connection ID of a pdisk. Then, figure out, how you want all disks numbered.
Remove the pdisks and hdisks with the rmdev -dl command.
Create the pdisks again:
# mkdev -p ssar -t scsd -c pdisk -s ssar -w [connection-ID] -l pdisk1Create the hdisks again:
# mkdev -p ssar -t hdisk -c disk -s ssar -w [connection-ID] -l hdisk3Test with:
# ssaxlate -l pdisk1if it shows hdisk3 (Usually the hdisk number is 2 higher than the pdisk number if you use 2 SCSI disks in the rootvg).
If you've done all disks this way, check with lsdev -Cc pdisk. If you're happy, then varyon the volume group again and mount all filesystems.
Sometimes, when you create an mksysb, you receive an error like this one:
/dev/ipldevice not foundDevice /dev/ipldevice is a hard link to the disk your system booted from. Mksysb tries to determine the size of the boot logical volume with the bosboot -qad /dev/ipldevice command. Via lslv -m hd5 you can see from which disk was booted (or via bootlist -m normal -o).
To resolve this problem: re-create the hard link yourself:
# ln /dev/bootdevice /dev/ipldeviceFor example:
ln /dev/rhdisk0 /dev/ipldeviceNote: Use "rhdisk" and not "hdisk".
Another way to solve this problem: reboot your system and the /dev/ipldevice will be created automatically for you (Your users may prefer the first solution...).
To quickly show you the processor speed, cpu type, amount of memory and other system information, type:
# lsconfYou can also use prtconf.
If the lines in your text file are too long, you may want to word wrap them. In AIX this command is called fold:
# fold -sw 72 longfile > shortfileThis command will keep the longest line up to 72 characters and will not break a word in half. Without -w 72 lines will be wrapped to 80 characters.
Displaying results: 281 - 290.


