Adding a New Column to my hobbit server
list Sanu Mathew
All, I have followed the method to add a new column from these links. http://en.wikibooks.org/wiki/System_Monitoring_with_Hobbit/Other_Docs/HOWTO/Custom_Monitoring_Scripts_for_Hobbit http://en.wikibooks.org/wiki/System_Monitoring_with_Hobbit/HOWTO/Custom_Monitoring_Scripts_for_Hobbit#Let.27s_start_coding http://www.hobbitmon.com/hobbit/help/hobbit-tips.html#scripts However, even after doing the above steps i do not get the new column. 1. Is there a way i can debug to find what went wrong? 2. Is there a way to know if the client is able to send the data to the hobbit server? 3. If the client is able to send the data to the hobbit server, why is it not displaying the new column. My client side script is running every 5 mins from $BBHOME/ext. Please assist and let me know if there is any more information required. Regards, Sanu
list Stef Coene
▸
On Tuesday 10 March 2009, Sanu Mathew wrote:
All, I have followed the method to add a new column from these links.
You can not 'add' a new column. If you send data to the hobbit server in your script, you have to make sure the syntax is correct. One of the rules is <client name>.<check name>. Client name is the name like it appears in bb-hosts, the check name will be the new column name.
1. Is there a way i can debug to find what went wrong?
Dump the bb command you execute in your script to stdout and check for errors. Try to execute the same command on the command line and check for errors.
▸
2. Is there a way to know if the client is able to send the data to the hobbit server?
You can search in the data directory of the hobbit server. Each server has a directory in the histlogs directory. In this directory is a sub-directory per check/column.
▸
3. If the client is able to send the data to the hobbit server, why is it not displaying the new column.
You can also check the ghost client list. There is an option in the top menu. Stef
list Steve Holmes
Try running your script by hand. Run it under the control of bbcmd (usually in the hobbit client bin directory). On unix it would be something like: su hobbit -c "<path-to-hobbit-client-bin>/bbcmd <your script>" If there is a problem you should see errors there. Also check the logs on the client. Steve.
▸
On Tue, Mar 10, 2009 at 3:58 PM, Sanu Mathew <user-648ac91bf759@xymon.invalid> wrote:
All, I have followed the method to add a new column from these links. http://en.wikibooks.org/wiki/System_Monitoring_with_Hobbit/Other_Docs/HOWTO/Custom_Monitoring_Scripts_for_Hobbit http://en.wikibooks.org/wiki/System_Monitoring_with_Hobbit/HOWTO/Custom_Monitoring_Scripts_for_Hobbit#Let.27s_start_coding http://www.hobbitmon.com/hobbit/help/hobbit-tips.html#scripts However, even after doing the above steps i do not get the new column. 1. Is there a way i can debug to find what went wrong? 2. Is there a way to know if the client is able to send the data to the hobbit server? 3. If the client is able to send the data to the hobbit server, why is it not displaying the new column. My client side script is running every 5 mins from $BBHOME/ext. Please assist and let me know if there is any more information required. Regards, Sanu
list Martin Flemming
Hi, Sanu !
1. Is there a way i can debug to find what went wrong?
- check the logfile of your client-script ( shell or perl ?) - test the script with ~hobbit/bin/bbcmd sh -x ext/test.sh or ~hobbit/bin/bbcmd perl -d ext/test.sh
▸
2. Is there a way to know if the client is able to send the data to the hobbit server?
on the client: telnet hobbitserver 1984 on the server: tcpdump -i eth0 host hobbit-client-ip
▸
3. If the client is able to send the data to the hobbit server, why is it not displaying the new column.
check on the server what he get from the client
/usr/lib/hobbit/server/bin/bbcmd hobbitd_channel --debug --channel=status hobbitd_capture --hosts=hobbit-client-name/ip
cheers,
martin
▸
On Wed, 11 Mar 2009, Sanu Mathew wrote:
All, I have followed the method to add a new column from these links. http://en.wikibooks.org/wiki/System_Monitoring_with_Hobbit/Other_Docs/HOWTO/Custom_Monitoring_Scripts_for_Hobbit http://en.wikibooks.org/wiki/System_Monitoring_with_Hobbit/HOWTO/Custom_Monitoring_Scripts_for_Hobbit#Let.27s_start_coding http://www.hobbitmon.com/hobbit/help/hobbit-tips.html#scripts However, even after doing the above steps i do not get the new column. 1. Is there a way i can debug to find what went wrong? 2. Is there a way to know if the client is able to send the data to the hobbit server? 3. If the client is able to send the data to the hobbit server, why is it not displaying the new column. My client side script is running every 5 mins from $BBHOME/ext. Please assist and let me know if there is any more information required. Regards, Sanu
list Sanu Mathew
Thanks Stef,
Here is my script.
#!/bin/sh
COLUMN=foo # Name of the column
COLOR=green # By default, everything is OK
MSG="foo is Down"
MSG1="foo is Good"
COLOR=red
$BB $BBDISP "status $MACHINE.$COLUMN $COLOR `date` ${MSG}"
sleep 60
COLOR=green
$BB $BBDISP "status $MACHINE.$COLUMN $COLOR `date` ${MSG1}"
fi
fi
Let me know if the above task is right.
▸
2. Is there a way to know if the client is able to send the data to the hobbit server?
You can search in the data directory of the hobbit server. Each server has a directory in the histlogs directory. In this directory is a sub-directory per check/column.
There is no sub directory with foo for that server name.
▸
1. Is there a way i can debug to find what went wrong?
Dump the bb command you execute in your script to stdout and check for errors. Try to execute the same command on the command line and check for errors.
Please help on this.
Regards,
Sanu
▸
On Wed, Mar 11, 2009 at 1:57 AM, Stef Coene <user-dbffe946c0f4@xymon.invalid> wrote:
On Tuesday 10 March 2009, Sanu Mathew wrote:All, I have followed the method to add a new column from these links.You can not 'add' a new column. If you send data to the hobbit server in your script, you have to make sure the syntax is correct. One of the rules is <client name>.<check name>. Client name is the name like it appears in bb-hosts, the check name will be the new column name.1. Is there a way i can debug to find what went wrong?Dump the bb command you execute in your script to stdout and check for errors. Try to execute the same command on the command line and check for errors.2. Is there a way to know if the client is able to send the data to the hobbit server?You can search in the data directory of the hobbit server. Each server has a directory in the histlogs directory. In this directory is a sub-directory per check/column.3. If the client is able to send the data to the hobbit server, why is it not displaying the new column.You can also check the ghost client list. There is an option in the top menu. Stef
list Sanu Mathew
Did that steve, i see no error
▸
On Wed, Mar 11, 2009 at 2:02 AM, Steve Holmes <user-5425c7b245e1@xymon.invalid> wrote:
Try running your script by hand. Run it under the control of bbcmd (usually in the hobbit client bin directory). On unix it would be something like: su hobbit -c "<path-to-hobbit-client-bin>/bbcmd <your script>" If there is a problem you should see errors there. Also check the logs on the client. Steve. On Tue, Mar 10, 2009 at 3:58 PM, Sanu Mathew <user-648ac91bf759@xymon.invalid>wrote:All, I have followed the method to add a new column from these links. http://en.wikibooks.org/wiki/System_Monitoring_with_Hobbit/Other_Docs/HOWTO/Custom_Monitoring_Scripts_for_Hobbit http://en.wikibooks.org/wiki/System_Monitoring_with_Hobbit/HOWTO/Custom_Monitoring_Scripts_for_Hobbit#Let.27s_start_coding http://www.hobbitmon.com/hobbit/help/hobbit-tips.html#scripts However, even after doing the above steps i do not get the new column. 1. Is there a way i can debug to find what went wrong? 2. Is there a way to know if the client is able to send the data to the hobbit server? 3. If the client is able to send the data to the hobbit server, why is it not displaying the new column. My client side script is running every 5 mins from $BBHOME/ext. Please assist and let me know if there is any more information required. Regards, Sanu
list Sanu Mathew
Cool Martin. Cheers.. ur third step helped me in fixing it Thanks
▸
Sanu
On Wed, Mar 11, 2009 at 2:02 AM, Martin Flemming <user-f286aaa49a76@xymon.invalid>wrote:
Hi, Sanu ! 1. Is there a way i can debug to find what went wrong?- check the logfile of your client-script ( shell or perl ?) - test the script with ~hobbit/bin/bbcmd sh -x ext/test.sh or ~hobbit/bin/bbcmd perl -d ext/test.sh 2. Is there a way to know if the client is able to send the data to thehobbit server?on the client: telnet hobbitserver 1984 on the server: tcpdump -i eth0 host hobbit-client-ip 3. If the client is able to send the data to the hobbit server, why is itnot displaying the new column.check on the server what he get from the client /usr/lib/hobbit/server/bin/bbcmd hobbitd_channel --debug --channel=status hobbitd_capture --hosts=hobbit-client-name/ip cheers, martin On Wed, 11 Mar 2009, Sanu Mathew wrote: All,I have followed the method to add a new column from these links. http://en.wikibooks.org/wiki/System_Monitoring_with_Hobbit/Other_Docs/HOWTO/Custom_Monitoring_Scripts_for_Hobbit http://en.wikibooks.org/wiki/System_Monitoring_with_Hobbit/HOWTO/Custom_Monitoring_Scripts_for_Hobbit#Let.27s_start_coding http://www.hobbitmon.com/hobbit/help/hobbit-tips.html#scripts However, even after doing the above steps i do not get the new column. 1. Is there a way i can debug to find what went wrong? 2. Is there a way to know if the client is able to send the data to the hobbit server? 3. If the client is able to send the data to the hobbit server, why is it not displaying the new column. My client side script is running every 5 mins from $BBHOME/ext. Please assist and let me know if there is any more information required. Regards, Sanu