Draft: Aix 5.2 WLM examples for the
banking, based on business process
prioritization
Introduction:
This is a short example of how p690 with AIX 5.2ML01 can be configured on the business
needs trough WLM. Same ideas can be applied to any type of workload management. There
are many other possibilities by dynamic and static lpars, database internal scheduling etc, it is
important to use method which will best utilize all features of OS, database, application and
workload characteristics.

Purpose:
WLM can do good job on partitioning machine into separate “submachines”. Such policy,
presented in this paper, is based on the business purpose of the machine. It was essential to
do, since applications were migrated from different platforms to new machine (consolidated,
to use more appropriate word) it was not 100% clear how these applications will coexist. Also
there was no formal consolidation process.

There are more than one database instance on the machine with different business importance,
resources consumed by one instance must not interfere with behavior of other instances, and
e.g. more important database instance must have some minimal volume of the resources
available on request.

It is usual that machine is organized in batch/interactive class type of organization. Because of
some advanced AIX 5.2 WLM features we decide to organize machine into classes based on
business importance, and if there is a need for further sub-classification into batch/interactive
each business class already have such subclasses defined by WLM.

It is important to notice that WLM is not protection against hogs in one class and that WLM
limitations on IO and memory can cause more harm than actual hog. So system behavior must
be closely monitored.

Methodology:
Each process is classified automatically on start by WLM based on static rules and
inheritance. Because of special nature of the oracle user processes such process actually needs
at least one dynamic reclassification after database start to achieve appropriate class.
WLM is started at the system boot and each 5 minutes goes dynamic reclassification, and
naturally class statistics are collected too.

Literature:
AIX 5L Workload Manager (WLM), sg245977, Redbook
Examples:
WLM classes
                                                      Priority
Class          Description                                       Limits
                                                      (tier)
               Defined by system, all root process
System         which are not classified in other      0          Unlimited
               classes
               Defined by system, all not root
               process which are not classified in
Default                                               2          Unlimited
               other classes
               (bin, adm users)
               Defined by system - no active
Shared                                                0          Unlimited
               processes
                                                                                 soft hard
                                                                 Resource min
               Business critical processes, this class                           max max
biz_critical                                           1
               is the purpose of the machine                     CPU         80% 100% 100%
                                                                 diskIO      80% 100% 100%
              Ordinary business processes, as                                 soft hard
              example additional databases etc                   Resurs min
biz_important                                         4                       max max
              which are not
              primary purpose of the machine                     CPU      20% 100% 100%

                                                                              soft   hard
               All processes which are not in above              Resurs min
biz_regular                                         7                         max    max
               classes
                                                                 CPU      10% 20%    100%


Rules for dynamic reclassification (/etc/wlm/ma.conf)
# match string (instance or             class                    inheritance
subsystem)
prod1                                   biz_critical             yes
laguna                                  biz_important            yes
quiet                                   biz_important            yes
rman                                    biz_important            yes
Unicert1                                biz_regular              yes
tsm                                     biz_regular              yes

Rules for static classification (/etc/wlm/rules)
#         Class          User     Group     Application           Type       Tag
001       Biz_regula     -        -         /usr/bin/tar          -          -
002       Biz_regula     -        -         /usr/bin/dd           -          -
003       Biz_regula     -        -         /usr/tivoli/tsm/*     -          -
004       System         root     -          -                    -          -
005       Default        -        -          -                    -          -
Dynamic reclassification: wlm-oracle.ksh script

#!/usr/bin/ksh
# Sample script to perform manual assignment of processes whose different
# Instances can be differentiated by their output in ps -ef.
#
#
# Examples of this kind of processes are ORACLE database instances.
## Create a configuration file /etc/wlm/ma.conf with the following format:
# One line for each combination of:
#
# where:
#                o Instance Name is ORACLE instance.
#                o Class is the name of the class to assign the processes
to;
#                   Either `supername' for superclasses or
`supername.subname'
#                   for subclasses.
#                o Inheritance is a flag, which should be set to yes if you
#                   want all processes belonging to a process group, whose
#                   leader is the process being manually assigned, to be
#                   manually assigned too, or no, otherwise.
# MANUAL is an array of three positions, which one of them being:
#                o Position 0: Instance name.
#                o Position 1: Class name.
#                o Position 2: Inheritance flag.

#############################################################
# Source SG24-5977-01
# 15.06.2003 Version 0
# original
# a lot of bugs ...
# wrong magic cookie, wlassign processing, space to coma etc ...
#
#############################################################
# 20.06.2003 version 1
# changes in CONF file
# there can be comment lines start with hash
# there can be empty lines
# changes in script
# assignment for each process separately - bug in argument list
# comment and empty line processing in conf file
#
#############################################################


##
# DIRECTORIES
##
WLMDIR=/etc/wlm

##
# VARIABLES
##
CONFFILE=$WLMDIR/ma.conf
PATH=/usr/bin:/usr/sbin:$PATH

##
# FUNCTIONS
##

getpids()
{

#error
inst="$1"
test -z "$inst" && exit 1

echo $(ps -ef | grep "$inst" | grep -v grep | awk '{ print $2 }')
}

##
# MAIN -
##
egrep -v "^#" $CONFFILE| awk 'NF>0{print}'| (while read LINE
do
        set -A MANUAL $LINE

       echo "Changing the inheritance attribute on class ${MANUAL[1]}..."

        OLDINH=`lsclass -f ${MANUAL[1]} | grep inheritance | awk '{ print
$3 }' | sed "s/"//g"`

       [ ! "$OLDINH" ] && OLDINH="no"

       $ECHO chclass -a inheritance=${MANUAL[2]} ${MANUAL[1]}

       echo "Refreshing WLM..."

       wlmcntrl -u
       echo "Manually assigning the processes to class ${MANUAL[1]}..."

       echo "Getting PIDS' list for instance ${MANUAL[0]}..."

       n=0
       for p in $(getpids ${MANUAL[0]})
       do
               wlmassign -S ${MANUAL[1]} $p
               n=$(expr $n + 1)
       done

       echo "Assigning $n processes to class ${MANUAL[1]}..."
       echo "Resetting old inheritance value on class ${MANUAL[1]}..."
       chclass -a inheritance="$OLDINH" ${MANUAL[1]}
       echo "Refreshing WLM..."

       wlmcntrl -u
done

)

#######################

##logger WLM updated
exit 0

More Related Content

PDF
cmg_las
PPT
Ibm aix wlm idea
PPTX
Master db performance with wlm
PDF
Build Features, Not Apps
PPTX
Techno-Fest-15nov16
PPT
tuningfor_oracle
PPT
TSRT Crashes
PDF
Rails Application Optimization Techniques & Tools
cmg_las
Ibm aix wlm idea
Master db performance with wlm
Build Features, Not Apps
Techno-Fest-15nov16
tuningfor_oracle
TSRT Crashes
Rails Application Optimization Techniques & Tools

Similar to Aix workload manager (20)

DOCX
Must Read HP Data Protector Interview Questions
PPT
Batch file programming
PDF
Security Challenges of Antivirus Engines, Products and Systems
PPTX
10 Tips for AIX Security
PDF
Tuning systemd for embedded
PPTX
PowerShell - Be A Cool Blue Kid
PDF
1. What is the value of requiring the OS to provide status informati.pdf
PDF
How to debug systemd problems fedora project
DOCX
Project of deamon process
ODP
How to build an admin guy
PPT
SaltConf14 - Ben Cane - Using SaltStack in High Availability Environments
PDF
Inspection and maintenance tools (Linux / OpenStack)
PPT
Real life aws_user_data_auto_scale
PPT
Memory Management in OS
PPTX
Process management in linux
PDF
Linux on System z debugging with Valgrind
PDF
제2회난공불락 오픈소스 세미나 커널튜닝
PDF
Liferay hardening principles
Must Read HP Data Protector Interview Questions
Batch file programming
Security Challenges of Antivirus Engines, Products and Systems
10 Tips for AIX Security
Tuning systemd for embedded
PowerShell - Be A Cool Blue Kid
1. What is the value of requiring the OS to provide status informati.pdf
How to debug systemd problems fedora project
Project of deamon process
How to build an admin guy
SaltConf14 - Ben Cane - Using SaltStack in High Availability Environments
Inspection and maintenance tools (Linux / OpenStack)
Real life aws_user_data_auto_scale
Memory Management in OS
Process management in linux
Linux on System z debugging with Valgrind
제2회난공불락 오픈소스 세미나 커널튜닝
Liferay hardening principles
Ad

More from Damir Delija (20)

PDF
6414 preparation and planning of the development of a proficiency test in the...
PDF
6528 opensource intelligence as the new introduction in the graduate cybersec...
PDF
Uvođenje novih sadržaja u nastavu digitalne forenzike i kibernetičke sigurnos...
PPTX
Remote forensics fsec2016 delija draft
PDF
Ecase direct servlet acess v1
PPTX
Cis 2016 moč forenzičikih alata 1.1
PPTX
Draft current state of digital forensic and data science
PDF
Why i hate digital forensics - draft
DOCX
Concepts and Methodology in Mobile Devices Digital Forensics Education and Tr...
PPTX
Deep Web and Digital Investigations
PDF
Datafoucs 2014 on line digital forensic investigations damir delija 2
PDF
EnCase Enterprise Basic File Collection
PDF
Ocr and EnCase
PDF
Olaf extension td3 inisg2 2
PDF
LTEC 2013 - EnCase v7.08.01 presentation
PDF
Moguće tehnike pristupa forenzckim podacima 09.2013
PDF
Usage aspects techniques for enterprise forensics data analytics tools
PPT
Cis 2013 digitalna forenzika osvrt
PDF
2013 obrada digitalnih dokaza
PDF
Tip zlocina digitalni dokazi
6414 preparation and planning of the development of a proficiency test in the...
6528 opensource intelligence as the new introduction in the graduate cybersec...
Uvođenje novih sadržaja u nastavu digitalne forenzike i kibernetičke sigurnos...
Remote forensics fsec2016 delija draft
Ecase direct servlet acess v1
Cis 2016 moč forenzičikih alata 1.1
Draft current state of digital forensic and data science
Why i hate digital forensics - draft
Concepts and Methodology in Mobile Devices Digital Forensics Education and Tr...
Deep Web and Digital Investigations
Datafoucs 2014 on line digital forensic investigations damir delija 2
EnCase Enterprise Basic File Collection
Ocr and EnCase
Olaf extension td3 inisg2 2
LTEC 2013 - EnCase v7.08.01 presentation
Moguće tehnike pristupa forenzckim podacima 09.2013
Usage aspects techniques for enterprise forensics data analytics tools
Cis 2013 digitalna forenzika osvrt
2013 obrada digitalnih dokaza
Tip zlocina digitalni dokazi
Ad

Aix workload manager

  • 1. Draft: Aix 5.2 WLM examples for the banking, based on business process prioritization Introduction: This is a short example of how p690 with AIX 5.2ML01 can be configured on the business needs trough WLM. Same ideas can be applied to any type of workload management. There are many other possibilities by dynamic and static lpars, database internal scheduling etc, it is important to use method which will best utilize all features of OS, database, application and workload characteristics. Purpose: WLM can do good job on partitioning machine into separate “submachines”. Such policy, presented in this paper, is based on the business purpose of the machine. It was essential to do, since applications were migrated from different platforms to new machine (consolidated, to use more appropriate word) it was not 100% clear how these applications will coexist. Also there was no formal consolidation process. There are more than one database instance on the machine with different business importance, resources consumed by one instance must not interfere with behavior of other instances, and e.g. more important database instance must have some minimal volume of the resources available on request. It is usual that machine is organized in batch/interactive class type of organization. Because of some advanced AIX 5.2 WLM features we decide to organize machine into classes based on business importance, and if there is a need for further sub-classification into batch/interactive each business class already have such subclasses defined by WLM. It is important to notice that WLM is not protection against hogs in one class and that WLM limitations on IO and memory can cause more harm than actual hog. So system behavior must be closely monitored. Methodology: Each process is classified automatically on start by WLM based on static rules and inheritance. Because of special nature of the oracle user processes such process actually needs at least one dynamic reclassification after database start to achieve appropriate class. WLM is started at the system boot and each 5 minutes goes dynamic reclassification, and naturally class statistics are collected too. Literature: AIX 5L Workload Manager (WLM), sg245977, Redbook
  • 2. Examples: WLM classes Priority Class Description Limits (tier) Defined by system, all root process System which are not classified in other 0 Unlimited classes Defined by system, all not root process which are not classified in Default 2 Unlimited other classes (bin, adm users) Defined by system - no active Shared 0 Unlimited processes soft hard Resource min Business critical processes, this class max max biz_critical 1 is the purpose of the machine CPU 80% 100% 100% diskIO 80% 100% 100% Ordinary business processes, as soft hard example additional databases etc Resurs min biz_important 4 max max which are not primary purpose of the machine CPU 20% 100% 100% soft hard All processes which are not in above Resurs min biz_regular 7 max max classes CPU 10% 20% 100% Rules for dynamic reclassification (/etc/wlm/ma.conf) # match string (instance or class inheritance subsystem) prod1 biz_critical yes laguna biz_important yes quiet biz_important yes rman biz_important yes Unicert1 biz_regular yes tsm biz_regular yes Rules for static classification (/etc/wlm/rules) # Class User Group Application Type Tag 001 Biz_regula - - /usr/bin/tar - - 002 Biz_regula - - /usr/bin/dd - - 003 Biz_regula - - /usr/tivoli/tsm/* - - 004 System root - - - - 005 Default - - - - -
  • 3. Dynamic reclassification: wlm-oracle.ksh script #!/usr/bin/ksh # Sample script to perform manual assignment of processes whose different # Instances can be differentiated by their output in ps -ef. # # # Examples of this kind of processes are ORACLE database instances. ## Create a configuration file /etc/wlm/ma.conf with the following format: # One line for each combination of: # # where: # o Instance Name is ORACLE instance. # o Class is the name of the class to assign the processes to; # Either `supername' for superclasses or `supername.subname' # for subclasses. # o Inheritance is a flag, which should be set to yes if you # want all processes belonging to a process group, whose # leader is the process being manually assigned, to be # manually assigned too, or no, otherwise. # MANUAL is an array of three positions, which one of them being: # o Position 0: Instance name. # o Position 1: Class name. # o Position 2: Inheritance flag. ############################################################# # Source SG24-5977-01 # 15.06.2003 Version 0 # original # a lot of bugs ... # wrong magic cookie, wlassign processing, space to coma etc ... # ############################################################# # 20.06.2003 version 1 # changes in CONF file # there can be comment lines start with hash # there can be empty lines # changes in script # assignment for each process separately - bug in argument list # comment and empty line processing in conf file # ############################################################# ## # DIRECTORIES ## WLMDIR=/etc/wlm ## # VARIABLES ## CONFFILE=$WLMDIR/ma.conf
  • 4. PATH=/usr/bin:/usr/sbin:$PATH ## # FUNCTIONS ## getpids() { #error inst="$1" test -z "$inst" && exit 1 echo $(ps -ef | grep "$inst" | grep -v grep | awk '{ print $2 }') } ## # MAIN - ## egrep -v "^#" $CONFFILE| awk 'NF>0{print}'| (while read LINE do set -A MANUAL $LINE echo "Changing the inheritance attribute on class ${MANUAL[1]}..." OLDINH=`lsclass -f ${MANUAL[1]} | grep inheritance | awk '{ print $3 }' | sed "s/"//g"` [ ! "$OLDINH" ] && OLDINH="no" $ECHO chclass -a inheritance=${MANUAL[2]} ${MANUAL[1]} echo "Refreshing WLM..." wlmcntrl -u echo "Manually assigning the processes to class ${MANUAL[1]}..." echo "Getting PIDS' list for instance ${MANUAL[0]}..." n=0 for p in $(getpids ${MANUAL[0]}) do wlmassign -S ${MANUAL[1]} $p n=$(expr $n + 1) done echo "Assigning $n processes to class ${MANUAL[1]}..." echo "Resetting old inheritance value on class ${MANUAL[1]}..." chclass -a inheritance="$OLDINH" ${MANUAL[1]} echo "Refreshing WLM..." wlmcntrl -u done ) ####################### ##logger WLM updated exit 0