пятница, 25 ноября 2011 г.

PowerHA (HACMP) Commands

Взял здесь

Most commands should work on all PowerHA (HACMP prior to 5.5) versions.
If there is some syntax error, please consult the manual page for that command.


How to start cluster daemons (options in that order: clstrmgr, clsmuxpd, broadcast message, clinfo, cllockd):
root@gznode1:~# clstart -m -s -b -i -l

How to show cluster state and substate (depends on clinfo):
root@gznode1:~# clstat

SNMP-based tool to show cluster state:
root@gznode1:~# cldump

Similar to cldump, perl script to show cluster state:
root@gznode1:~# cldisp

How to list the local view of the cluster topology:
root@gznode1:~# cltopinfo

How to list the local view of the cluster subsystems:
root@gznode1:~# clshowsrv -a

How to show all necessary info about HACMP:
root@gznode1:~# clshowsrv -v

How to show HACMP version:
root@gznode1:~# lslpp -L | grep cluster.es.server.rte

How to verify the HACMP configuration:
root@gznode1:~# /usr/es/sbin/cluster/diag/clconfig -v -O

How to list app servers configured including start/stop scripts:
root@gznode1:~# cllsserv

How to locate the resource groups and display their status:
root@gznode1:~# clRGinfo -v

How to rotate some of the log files:
root@gznode1:~# clcycle

A cluster ping program with more arguments:
root@gznode1:~# cl_ping

Cluster rsh program that take cluster node names as argument:
root@gznode1:~# clrsh

How to find out the name of the local node:
root@gznode1:~# get_local_nodename

How to check the HACMP ODM:
root@gznode1:~# clconfig

How to put online/offline or move resource groups:
root@gznode1:~# clRGmove

How to list the resource groups:
root@gznode1:~# cllsgrp

How to create a large snapshot of the hacmp configuration:
root@gznode1:~# clsnapshotinfo

How to show short resource group information:
root@gznode1:~# cllsres

How to list the cluster manager state:
root@gznode1:~# lssrc -ls clstrmgrES

Cluster manager states:
ST_NOT_CONFIGURED Node never started
ST_INIT Node configured but down - not running
ST_STABLE Node up and running
ST_RP_RUNNING
ST_JOINING
ST_BARRIER
ST_CBARRIER
ST_VOTING
ST_RP_FAILED Node with event error

How to show heartbeat information:
root@gznode1:~# lssrc -ls topsvcs

How to check logs related to hacmp:
root@gznode1:~# odmget HACMPlogs

How to list all information from topology HACMP:
root@gznode1:~# lssrc -lstopsvcs

How to show all info about group:
root@gznode1:~# lssrc -ls grpsvcs

How to list the logs:
root@gznode1:~# cllistlogs

How to list the resources defined for all resource group:
root@gznode1:~# clshowres

How to show resource information by resource group:
root@gznode1:~# clshowres -g'RG'

How to show resource information by node:
root@gznode1:~# clshowres -n'NODE'

How to locate the resource groups and display status (-s):
root@gznode1:~# clfindres

How to list interface name/interface device name/netmask associated with a specified ip label / ip address of a specific node:
root@gznode1:~# clgetif

Cluster verification utility:
root@gznode1:~# clverify

How to list cluster topology information:
root@gznode1:~# cllscf

X utility for cluster configuration:
root@gznode1:~# xclconfig

X utility for hacmp management:
root@gznode1:~# xhacmpm

X utility for cluster status:
root@gznode1:~# xclstat

How to force shutdown cluster immediately without releasing resources:
root@gznode1:~# clstop -f -N

How to do graceful shutdown immediately with no takeover:
root@gznode1:~# clstop -g -N

How to do graceful shutdown immediately with takeover:
root@gznode1:~# clstop -gr -N

How to sync the cluster topology:
root@gznode1:~# cldare -t

How to do the mock sync of topology:
root@gznode1:~# cldare -t -f

How to sync the cluster resources:
root@gznode1:~# cldare -r

How to do the mock sync of resources:
root@gznode1:~# cldare -r -f

How to list the name and security level of the cluster:
root@gznode1:~# cllsclstr

How to list the info about the cluster nodes:
root@gznode1:~# cllsnode

How to list info about node69:
root@gznode1:~# cllsnode -i node69

How to list the PVID of the shared hard disk for resource group dataRG:
root@gznode1:~# cllsdisk -g dataRG

How to list all cluster networks:
root@gznode1:~# cllsnw

How to list the details of network ether1:
root@gznode1:~# cllsnw -n ether1

How to show network ip/nonip interface information:
root@gznode1:~# cllsif

How to list the details of network adapter node1_service:
root@gznode1:~# cllsif -n node1_service

How to list the shared vgs which can be accessed by all nodes:
root@gznode1:~# cllsvg

How to list the shared vgs in resource group dbRG:
root@gznode1:~# cllsvg -g dbRG

How to list the shared lvs:
root@gznode1:~# cllslv

How to list the shared lvs in the resource group dbRG:
root@gznode1:~# cllslv -g dbRG

How to list the PVID of disks in the resource group appRG:
root@gznode1:~# cllsdisk -g appRG

How to list the shared file systems:
root@gznode1:~# cllsfs

How to list the shared file systems in the resource group sapRG:
root@gznode1:~# cllsfs -g sapRG

How to show info about all network modules:
root@gznode1:~# cllsnim

How to show info about ether network module:
root@gznode1:~# cllsnim -n ether

How to list the runtime parameters for the node node1:
root@gznode1:~# cllsparam -n node1

How to add a cluster definition with name dcm and id 3:
root@gznode1:~# claddclstr -i 3 -n dcm

How to create resource group sapRG with nodes n1,n2 in cascade:
root@gznode1:~# claddgrp -g sapRG -r cascading -n n1 n2

Creates an application server ser1 with startscript as /usr/start and stop script as /usr/stop:
root@gznode1:~# claddserv -s ser1 -b /usr/start -e /usr/stop

How to change cluster definitions name to dcmds and id to 2:
root@gznode1:~# clchclstr -i 2 -n dcmds

How to change the cluster security to enhanced:
root@gznode1:~# clchclstr -s enhanced

How to delete the resource group appRG and related resources:
root@gznode1:~# clrmgrp -g appRG

How to remove the node node69:
root@gznode1:~# clrmnode -n node69

How to remove the adapter named node69_svc:
root@gznode1:~# clrmnode -a node69_svc

How to remove all resources from resource group appRG:
root@gznode1:~# clrmres -g appRG

How to remove the application server app69:
root@gznode1:~# clrmserv app69

How to remove all applicaion servers:
root@gznode1:~# clrmserv ALL

How to list the nodes with active cluster manager processes from cluster manager on node node1clgetaddr node1 returns a pingable address from node node1:
root@gznode1:~# clgetactivenodes -n node1

How to list the info about resource group sapRG:
root@gznode1:~# clgetgrp -g sapRG

How to list the participating nodes in the resource group sapRG:
root@gznode1:~# clgetgrp -g sapRG -f nodes

How to get the ip label associated to the resource group:
root@gznode1:~# clgetip sapRG

How to list the network for ip 192.168.100.2, netmask 255.255.255.0:
root@gznode1:~# clgetnet 192.168.100.2 255.255.255.0

How to list the VG of LV nodelv:
root@gznode1:~# clgetvg -l nodelv

How to add node5 to the cluster:
root@gznode1:~# clnodename -a node5

How to change the cluster node name node5 to node3:
root@gznode1:~# clnodename -o node5 -n node3

Комментариев нет: