A little post to describe how i install the tools provided by IBM to manage a RHEL 6 linux system on powerVM. I wanted to show how to do it in a “linux way” by using repositories to install packages with yum.

IBM repository package

If you have internet access on your linux system, the first step is to install the repository package provided by IBM.

yum install -y http://public.dhe.ibm.com/software/server/POWER/Linux/yum/IBM/RHEL/6/ppc64/ibm-power-repo-2.0.0-2.noarch.rpm

After that, update the packages :

[root@lgegpfs1 ~]# yum update

You will see the repositories added by the IBM package :

[root@lgegpfs1]# yum repolist
Loaded plugins: product-id, rhnplugin, subscription-manager
This system is receiving updates from RHN Classic or RHN Satellite.
repo id repo name status
Advance_Toolchain Advance Toolchain 183
IBM_Power_SDK_Tools IBM Power SDK Tools 7
IBM_Power_Tools IBM Power Tools 53
rhel-ppc64-server-6 Red Hat Enterprise Linux Server (v. 6 for IBM POWER) 13,251
rhel-ppc64-server-optional-6 RHEL Server Optional (v. 6 for IBM POWER) 7,342

systems without internet access

Here the best solution is to create a local repository on your system.

First, download all the packages from a system with internet access(here in /data/ibm_repo):

mkdir -p /data/ibm_repo
cd /data/ibm_repo
wget -A rpm -e robots=off -nd -r -l 1 http://public.dhe.ibm.com/software/server/POWER/Linux/yum/IBM/RHEL/6/ppc64/

For information, i use -e robots=off because IBM has a robots.txt file to block automatic file downloads by tools like wget. I admit i don’t know if a better location to download this packages exist.

Install createrepo package to generate the repository metadata:

yum install -y createrepo

Generate the repository metadata :

createrepo /data/ibm_repo

Create the repository file /etc/yum.repos.d/local_ibm.repo :

name=Local IBM tools x86_64

Clean yum cache first :

yum clean cache

list your repositories on the system :

# yum repolist
Loaded plugins: product-id, rhnplugin, subscription-manager
This system is receiving updates from RHN Classic or RHN Satellite.
local_ibm_tools | 2.9 kB 00:00 ...
local_ibm_tools/primary_db | 4.9 kB 00:00 ...
repo id repo name status
local_ibm_tools Local IBM tools x86_64 60
rhel-ppc64-server-6 Red Hat Enterprise Linux Server (v. 6 for IBM POWER) 13,251
rhel-ppc64-server-optional-6 RHEL Server Optional (v. 6 for IBM POWER) 7,342

powerpc-utils tools

Installing this package provides a lot of useful commands.

First install the package :

yum install -y powerpc-utils

After that, you can use commands like lsslot to list the adapters on your system :

[root@lgegpfs1]# lsslot
# Slot Description Linux Name Device(s)
U8203.E4A.658EE65-V6-C0 Virtual I/O Slot 30000000 vty
U8203.E4A.658EE65-V6-C2 Virtual I/O Slot 30000002 l-lan
U8203.E4A.658EE65-V6-C3 Virtual I/O Slot 30000003 v-scsi
U8203.E4A.658EE65-V6-C4 Virtual I/O Slot 30000004 v-scsi

Commands like ls-veth and ls-vscsi list respectively the virtual ethernet and scsi adapters :

[root@lgegpfs1]# ls-veth
eth0 U8203.E4A.658EE65-V6-C2-T1
[root@lgegpfs1]# ls-vscsi
host0 U8203.E4A.658EE65-V6-C3-T1
host1 U8203.E4A.658EE65-V6-C4-T1

Some commands will talk more to AIX admins.

Like lparstat, here with the -i option to give the partition configuration :

[root@lgegpfs1]# lparstat -i
Node Name : lgegpfs1
Partition Name : lgegpfs1
Partition Number : 6
Type : Shared
Mode : Uncapped
Entitled Capacity : 0.40
Partition Group-ID : 32774
Shared Pool ID : 0
Online Virtual CPUs : 1
Maximum Virtual CPUs : 2
Minimum Virtual CPUs : 1
Online Memory : 4142528 kB
Minimum Memory : 1024
Minimum Capacity : 0.10
Maximum Capacity : 2.00
Capacity Increment : 0.01
Active Physical CPUs in system : 2
Active CPUs in Pool : 2
Maximum Capacity of Pool : 2.00
Entitled Capacity of Pool : 200
Unallocated Processor Capacity : 0
Physical CPU Percentage : 40
Unallocated Weight : 0
Memory Mode : Shared
Total I/O Memory Entitlement : 4294967296
Variable Memory Capacity Weight : 0
Memory Pool ID : 65535
Unallocated Variable Memory Capacity Weight : 0
Unallocated I/O Memory Entitlement : 0
Memory Group ID of LPAR : 32774
Desired Variable Capacity Weight : 128

Another interesting command is bootlist. it allows to setup easily on what device the system will reboot.

By default, after system installation, you should see something like that :

[root@lgegpfs1 ~]# bootlist -m normal -o
    speed = auto
    duplex = auto
    BOOTP Server:

It’s easy to configure the system to boot on disk with bootlist :

[root@lgegpfs1 ~]# bootlist -m normal /dev/mapper/mpatha

Checking the new bootlist :

[root@lgegpfs1 ~]# bootlist -m normal -o

You see sda and sdb because it’s the physical path behind mpatha :

mpatha (SIBM 3303 NVDISa8ff55a920e269bfa407b1b22ffe10e4) dm-2 IBM,3303 NVDISK
size=30G features='1 queue_if_no_path' hwhandler='0' wp=rw
|-+- policy='round-robin 0' prio=0 status=active
| `- 0:0:3:0 sda 8:16 active undef running
`-+- policy='round-robin 0' prio=0 status=enabled
  `- 1:0:2:0 sdb 8:240 active undef running

dynamic partitioning

On power, it’s possible to resize dynamically cpu and memory or add/remove adapters dynamically on the system.

First you need to install the packages enabling this features on RHEL 6 :

yum install -y DynamicRM devices.chrp.base.ServiceRM ibm-power-managed-rhel6

You need to have network communication enabled between your hmc and your linux system.

you can check it by checking if the port rmc(port tcp 657) is open between your linux and hmc system :

telnet yourhmc 657

After the packages installation, you can check if the services are started with lssrc(another IBM tool):

[root@lgegpfs1 ~]# lssrc -a
Subsystem Group PID Status
 ctrmc rsct 15463 active
 IBM.DRM rsct_rm 15491 active
 ctcas rsct inoperative
 IBM.ERRM rsct_rm inoperative
 IBM.AuditRM rsct_rm inoperative
 IBM.SensorRM rsct_rm inoperative

But the best way to see if all is working is to check if your linux ssystem know his hmc :

[root@lgegpfs1 yum.repos.d]# lsrsrc IBM.MCP
Resource Persistent Attributes for IBM.MCP
resource 1:
 MNName = ""
 NodeID = 13314811803610589469
 KeyToken = "lgehmc01"
 IPAddresses = {""}
 ConnectivityNames = {""}
 HMCName = "7042CR5*65E421B"
 HMCIPAddr = ""
 HMCAddIPs = ""
 HMCAddIPv6s = ""
 ActivePeerDomain = ""
 NodeNameList = {"lgegpfs1"}

You will see messages in /var/adm/messages when a dynamic operation occurs.

When a new adapter is added, you will have a message similar to :

rpadlpar_io: slot U8203.E4A.658EE65-V6-C5 added

When a new virtual processor is added :

clockevent: decrementer mult[83126e97] shift[32] cpu[2]
Processor 2 found.
clockevent: decrementer mult[83126e97] shift[32] cpu[3]
Processor 3 found.

the end :)

I hope you liked this short description of the tools provided by IBM to allow you to use your linux system on Power in the best conditions.