Objective
Today in a group saw someone introduced Pagerduty, introduced to the slack. Integration can be more convenient and team work. So I think come taste fresh.
"What is Pagerduty?" "
Pagerduty is a software that sends reminders when a server goes down. In the event of a problem, the reminders include screen displays, phone calls, SMS notifications, email notifications, and so on, and automatically increase the alert level when no one answers. The software monitors the problem through a control panel. Official website: http://www.pagerduty.com, remind this is not a free lunch ha.
"Register "
1. Open page https://signup.pagerduty.com/accounts/new to register
2, fill in the relevant content, completed, you will get a level two domain name for management.
3, then use the two-level domain name to log in, complete your data, add users. There's nothing here.
4. Select service, add Nagios service configuration, get key.
After selecting the Add service, get the key.
All right, a series of registrations are done.
the deployment "
Installing the Pagerduty agent
Demo download for CentOS.
1, modify the source of Yum.
?
| 12345678 |
sudo sh-c ' cat > /etc/yum .repos.d /pdagent Code class= "Bash plain" >.repo <<eof [pdagent] name=pdagent baseurl=http: //packages .pagerduty.com /pdagent/rpm enabled=1 gpgcheck=1 gpgkey=http: //packages .pagerduty.com /gpg-key-rpm-pagerduty eof ' |
2. Yum Installation
?
| 1 |
yum installpdagent pdagent-integrations |
3. View status
?
| 12 |
service pdagent status pd-queue status #看队列情况 |
Well, this thing is written in Python, understand can look, write more neat.
Add the following log under/var/log/pdagent/.
Configure Nagios
1. Get the Nagios configuration file.
?
| 1 |
wget https://raw.githubusercontent.com/PagerDuty/pdagent-integrations/master/pagerduty_nagios.cfg |
2. Move the configuration to a place below Nagios's etc.
?
| 1 |
mvpagerduty_nagios.cfg /etc/nagios |
3, modify the configuration of nagios.cfg Add.
?
| 1 |
cfg_file=/etc/nagios/pagerduty_nagios.cfg |
4. Configure Nagios to notify Nagios on PD. Refer to the following:
?
| 12345 |
define contactgroup{ contactgroup_name admins alias Nagios Administrators members nagiosadmin,pagerduty ; Add pagerduty here } |
5. Restart Nagios to see Wow.
Authentication
See the status of PD on the server.
?
| 1234 |
shell# pd-queue status Service Key Pending Success In Error ================================================================= 这个是秘密字段 0 9 0 |
Look at the information on the front-end Administration page
There is also detailed information, click to view
These ticket can be tagged for resolution, can be reassigned, and so on.
At the same time, there are clients, support client notification Oh, ease?
Look at the client for the guys!
Transfer from http://www.anbooks.cn/topic/4144774684493.html
A preliminary study on integrating Pagerduty and Nagios under CentOS (On-call and experience)