Wednesday, May 26, 2010

Configuring the TBSM 4.2.1 Discovery Library Toolkit to work with TADDM 7.1.1 and later

EDIT: Corrected the information after re-testing on a clean machine.

On a Windows TBSM server (I haven't tested this on other platforms), you need to copy the taddm-api-client.jar AND platform-api.jar files from the TADDM SDK into TWO different directories on the TBSM data server to get the Discovery Library Toolkit to work. Specifically, you need to copy taddm-api-client.jar to:

D:\ibm\tivoli\tbsm\XMLToolkit\sdk\clientlib

and copy platform-model.jar to:

D:\ibm\tivoli\tbsm\XMLToolkit\sdk\lib

I found that if you only copy the first file, the toolkit won't work at all, and won't generate any errors or messages of any use.

Scheduled Wakeup in Ubuntu

Well, this is hardly related to Tivoli, but just thought of sharing this cool stuff. I have a 5-year old desktop running Ubuntu Lucid used mainly for running scheduled jobs off of cron. So, basically it plays some music everyday for couple of hours and sits idle for the rest of the day. Ideally, I wanted to put the system on standby all the time and waking it up only when the scheduled job needs run. It is relatively easy to do it in Ubuntu (especially if your BIOS supports it).

Here are the exact steps needed on my Lucid Lynx. Please note that you need to have Kernel 2.6.22 or later for this to work.

1) Install the Power management interface tools.
sudo apt-get install powermanagement-interface
2) Copy the following code somewhere in your filesystem and save it as "suspend_x_hours.sh".
#!/bin/bash
# This script puts the system under standby mode for x hours
usage() {
echo "usage: $0 <n-hours>"
echo "where <n-hours> is the number of hours to be on standby"
exit 0

}
if [ $# -ne 1 ]
then
usage
fi

PATH=$PATH:/usr/sbin
hours=$1
echo 0 > /sys/class/rtc/rtc0/wakealarm
echo `date '+%s' -d "+ $hours hours"` > /sys/class/rtc/rtc0/wakealarm
pmi action suspend

3) Schedule the script in root's crontab. e.g the following crontab entry runs at 8PM and puts the system in sleep for 10 hours, waking it up at 6:00 AM.
00 20 * * * /home/venkat/bin/suspend_x_hours.sh 10 2>/dev/null

That's it. It takes only about 10 seconds to resume from sleep and it even restores your SSH sessions when it comes back from sleep!
Hope you find it useful.

Sunday, May 16, 2010

ITM Tip: Disabling default situations during install time

Many ITM sites want to disable default ITM situations so that unnecessary alerts are not sent to the operations.  In old days, we usually disable the situations by running a simple script. One such example of the script is posted below.

http://blog.gulfsoft.com/2008/03/disable-all-default-situations.html

This task is much easier with ITM 6.2.2.  While seeding application support, ITM asks you to whether you want to add the default managed system groups to the situation distribution. If you answer no, the default situations will not be distributed to any managed system unless you explicitly assign them! However, this feature is applicable only for fresh installation of ITM 6.2.2 and may not apply to those who are upgrading from old version  of ITM.