I have noticed while working with CA Workload Control Center customers that one has to run multiple commands to recycle CA WCC services.
For example,
unisrvcntr stop/start CA-wcc-db
unisrvcntr stop/start CA-wcc-services
unisrvcntr stop/start CA-wcc
Although stopping one may stop the other, at times it is hard to remember which one goes first. Starting CA-wcc starts CA-wcc-services, CA-wcc-db has to be started/stopped independent of the other two and so on.
Just to simplify this a bit, I have attached two scripts to this document; one for WCC with native Derby DB (CA-WCC-DB) and the other (CA-WCC) for WCC using external DB (Oracle or MS SQL Server).
I have tested these scripts on Redhat and SuSE Linux server running WCC 11.3.6 and WCC 11.4. It is likely to work on AIX and Solaris as well, but I am yet to test it.
How to use these scripts?
1. Download and copy the script to /etc/init.d/ as "CA-WCC"
# ls -l /etc/init.d/CA-WCC
-rwxr-xr-x 1 root root 3522 Mar 20 11:35 /etc/init.d/CA-WCC
2. Edit the $CASHCOMP/csutils/config/casrvc.cfg file using a text editor (Ex: vim) and add the following line:
Main_Service_Entry | CA-WCC |
Note:
You may have other Main_Service_Entry lines based on other components installed on the WCC host.
For example:
Main_Service_Entry | CA-CCS |
Main_Service_Entry | CA-WAAE |
Do NOT remove these lines. Leave them as is.
3. Test the script using commands:
Monitor
unisrvncntr status CA-WCC
Example:
| CA Services Status Report |
| Component Name | Pid | Status |
------------------------------------ ------- --------------
CA-wcc-db Server | 8843 running |
CA-wcc-services Server | 8713 running |
CA-wcc Server | 8775 running |
Stop
# unisrvcntr stop CA-WCC
Example:
# unisrvcntr stop CA-WCC
Executed CA-wcc stop.............................................OK
Executed CA-wcc-services stop....................................OK
Executed CA-wcc-db stop..........................................OK
Start
# unisrvcntr start CA-WCC
Example:
# unisrvcntr start CA-WCC
Executed CA-wcc-db start.........................................OK
Executed CA-wcc-services start...................................OK
Executed CA-wcc start............................................OK
Restart
# unisrvcntr cycle CA-WCC
Example:
# unisrvcntr cycle CA-WCC
Executed CA-wcc stop.............................................OK
Executed CA-wcc-services stop....................................OK
Executed CA-wcc-db stop..........................................OK
Executed CA-wcc-services start...................................OK
Executed CA-wcc start............................................OK
Executed CA-wcc-db start.........................................OK
CAVEAT(S):
1) On Linux, do NOT execute chkconfig CA-WCC on command after placing the CA-WCC script under /etc/init.d/. Doing so will change the order WCC and other services are started during System reboot.
Execute chkconfig CA-WCC --list to ensure all run levels are off.
2) Backup the $CASHCOMP/csutils/config/casrvc.cfg file before updating.
3) Save a copy of the updated scripts elsewhere so they can be restored if a product maintenance regresses the changes.
BACK-OUT PROCEDURE:
> Remove /etc/init.d/CA-WCC script
> Undo the changes to $CASHCOMP/csutils/config/casrvc.cfg file.
DISCLAIMER:
The sample scripts provided here are not supported under any CA Technologies standard support program or service. All scripts are provided “AS IS” without warranty of any kind. CA Technologies further disclaims all implied warranties including, without limitation, any implied warranties of merchantability or of fitness for a particular purpose. The entire risk arising out of the use or performance of the sample scripts and documentation remains with you. In no event shall CA Technologies, its authors, or anyone else involved in the creation, production, or delivery of the scripts be liable for any damages whatsoever (including, without limitation, damages for loss of business profits, business interruption, loss of business information, or other pecuniary loss) arising out of the use of or inability to use the sample scripts or documentation, even if CA Technologies has been advised of the possibility of such damages.
Cheers,
Chandru