- Community Home
- >
- Servers and Operating Systems
- >
- Operating Systems
- >
- Operating System - HP-UX
- >
- setting email alert when cluster failover to anoth...
Operating System - HP-UX
1754366
Members
4810
Online
108813
Solutions
Forums
Categories
Company
Local Language
юдл
back
Forums
Discussions
Forums
- Data Protection and Retention
- Entry Storage Systems
- Legacy
- Midrange and Enterprise Storage
- Storage Networking
- HPE Nimble Storage
Discussions
Discussions
Discussions
Forums
Forums
Discussions
юдл
back
Discussion Boards
Discussion Boards
Discussion Boards
Discussion Boards
- BladeSystem Infrastructure and Application Solutions
- Appliance Servers
- Alpha Servers
- BackOffice Products
- Internet Products
- HPE 9000 and HPE e3000 Servers
- Networking
- Netservers
- Secure OS Software for Linux
- Server Management (Insight Manager 7)
- Windows Server 2003
- Operating System - Tru64 Unix
- ProLiant Deployment and Provisioning
- Linux-Based Community / Regional
- Microsoft System Center Integration
Discussion Boards
Discussion Boards
Discussion Boards
Discussion Boards
Discussion Boards
Discussion Boards
Discussion Boards
Discussion Boards
Discussion Boards
Discussion Boards
Discussion Boards
Discussion Boards
Discussion Boards
Discussion Boards
Discussion Boards
Discussion Boards
Discussion Boards
Discussion Boards
Discussion Boards
Discussion Boards
Discussion Boards
Discussion Boards
Blogs
Information
Community
Resources
Community Language
Language
Forums
Blogs
Topic Options
- Subscribe to RSS Feed
- Mark Topic as New
- Mark Topic as Read
- Float this Topic for Current User
- Bookmark
- Subscribe
- Printer Friendly Page
- Mark as New
- Bookmark
- Subscribe
- Mute
- Subscribe to RSS Feed
- Permalink
- Report Inappropriate Content
тАО12-14-2010 12:44 AM
тАО12-14-2010 12:44 AM
setting email alert when cluster failover to another node
Hi..
I would like to know how to set the email alert so that i can receive email when the HP UX cluster failover to another node. Please Help
I would like to know how to set the email alert so that i can receive email when the HP UX cluster failover to another node. Please Help
2 REPLIES 2
- Mark as New
- Bookmark
- Subscribe
- Mute
- Subscribe to RSS Feed
- Permalink
- Report Inappropriate Content
тАО12-14-2010 01:26 AM
тАО12-14-2010 01:26 AM
Re: setting email alert when cluster failover to another node
simple script can check the package owner and send alert in case of failover.
Note:
1- save the script in a file, run it with nohup and in the background.
2- this will check the cluster every 1 hour. change the 3600 sec to the period you want.
===================================
#!/usr/bin/ksh
cmviewcl|grep cmspkg|awk -F " " '{ print $5 }' >/tmp/running
running=`cat /tmp/running`
while true
do
cmviewcl|grep cmspkg|awk -F " " '{ print $5 }' >/tmp/active
active=`cat /tmp/active`
if [ $active = $running ]
then
sleep 3600
continue
else
running=`cat /tmp/active`
echo " failover occured" > /tmp/sending
mailx -s "FileSystem Space Alert" "your email" < /tmp/sending&
sleep 3600
fi
done
=========================================
thanks
kamal
Note:
1- save the script in a file, run it with nohup and in the background.
2- this will check the cluster every 1 hour. change the 3600 sec to the period you want.
===================================
#!/usr/bin/ksh
cmviewcl|grep cmspkg|awk -F " " '{ print $5 }' >/tmp/running
running=`cat /tmp/running`
while true
do
cmviewcl|grep cmspkg|awk -F " " '{ print $5 }' >/tmp/active
active=`cat /tmp/active`
if [ $active = $running ]
then
sleep 3600
continue
else
running=`cat /tmp/active`
echo " failover occured" > /tmp/sending
mailx -s "FileSystem Space Alert" "your email" < /tmp/sending&
sleep 3600
fi
done
=========================================
thanks
kamal
- Mark as New
- Bookmark
- Subscribe
- Mute
- Subscribe to RSS Feed
- Permalink
- Report Inappropriate Content
тАО12-14-2010 01:50 AM
тАО12-14-2010 01:50 AM
Re: setting email alert when cluster failover to another node
Hi:
Adjust the control file of each cluster package: when initialize the package send a notice via email.
echo ""|mailx -m -s "Node \"$(hostname)\": Package PKG_XXXXXX start ERROR at $(date)" username@company.com
echo ""|mailx -m -s "Node \"$(hostname)\": Package PKG_XXXXXX start OK at $(date)" username@company.com
echo ""|mailx -m -s "Node \"$(hostname)\": Package PKG_XXXXXX halt ERROR at $(date)" username@company.com
echo ""|mailx -m -s "Node \"$(hostname)\": Package PKG_XXXXXX halt OK at $(date)" username@company.com
rgs,
Adjust the control file of each cluster package: when initialize the package send a notice via email.
echo ""|mailx -m -s "Node \"$(hostname)\": Package PKG_XXXXXX start ERROR at $(date)" username@company.com
echo ""|mailx -m -s "Node \"$(hostname)\": Package PKG_XXXXXX start OK at $(date)" username@company.com
echo ""|mailx -m -s "Node \"$(hostname)\": Package PKG_XXXXXX halt ERROR at $(date)" username@company.com
echo ""|mailx -m -s "Node \"$(hostname)\": Package PKG_XXXXXX halt OK at $(date)" username@company.com
rgs,
The opinions expressed above are the personal opinions of the authors, not of Hewlett Packard Enterprise. By using this site, you accept the Terms of Use and Rules of Participation.
News and Events
Support
© Copyright 2024 Hewlett Packard Enterprise Development LP