# -----------------------------------------------------------------------
#  Copyright 2003-2006 by Alex Peeters [alex.peeters@citap.be]
# -----------------------------------------------------------------------

# General - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - -

Author       : Alex Peeters [alex.peeters@citap.be]
Latest update: 01 Juni 2006
Version      : 3.000.009


# - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - -
# TODO  - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - -
# - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - -

Calculations for Trendline evolutions:
- AVG w(1-4) * 1.25
- if (current trendline < calculated trendline)
  -> new = calculated trendline 
- if (current trendline > calculated trendline)
  -> new = calculated trendline + (current trendline - calculated trendline) / 2 

500 SSL negotiation failed
- http://www.issociate.de/board/post/214066/LWP_and_SSL.html
- SSL: { if (index($resp->status_line, 'SSL negotiation failed') !=-1) { sleep 1; redo SSL unless $tries++ == 3; } }

depricate --httpdump & --dumphttp: tijdelijk voor backwards compatibiliteit !!!


# Plugins - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - -

Extra controle voor plugins.pl en/of generateConfig.pl
- controle of de opgegeven helpPluginFilename files bestaan op disk 
- upload van PDF's (WORD to PDF ?)

Restart Collector and Display:

Ledig geworden collector moet overal worden verwijderd !!!

Indien een mailtest offline is -> intresseert het resultaat ons niet, display offline, plugin toch draaien maar die mails deleten. 
MAW Bij plugin moet dit kunnen worden opgegeven als plugintype of iets dergelijks!!!

Warning and Critical: checking threshold range format

Performance Data: checking the expected format
- 'label'=value[UOM];[warn];[crit];[min];[max]

voor plugins, ook optie delete voorzien voor plugins dewelke door acrhiver na x maanden mogen opgekuist worden


# Display - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - -

multioffline, status in database offline -> in display als nog te testen weergaven

offline door holiday of scheduling niet in condenced view

offline door comment in condenced view

proxy caching statische pagina's

.cache files                                                     <- sound

applications/custom/display.pm                         <- custom function

On demand run icoontje naar de hamertjes & vraagtekens.

Openen van 'Help en Commands' into new window!


# Collector - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - -

nieuwe crontab optie: seconds om een crontab te kunnen verschuiven

Debug file for UNKNOWN !!!


# Reports - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - -

reports, deselecteren wat niet geselecteerd mag worden voor de datum keuze

mogelijkheid om bepaalde applicaties niet in de view te steken gedurende bepaalde uren. 

Bij Reports -> Problem details -> link maken naar 'Debug Report'

Statistics: Monthly Average <- ASAP

Een optie "send pdf by email" bij de repports. 

Ingeven downtimes, inetctrl, ..., die niet aangekondigd werden, ingeven op 
een later tijdstip.  Dit zou moeten mogelijk zijn om bv de statistieken te 
kunnen corrigeren.

Oproepen van voorgedefineerde stats:
-> http://asnmtap.citap.be/cgi-bin/detailedStatisticsReportGenerationAndCompareResponsetimeTrends.pl?pagedir=test&pageset=index&debug=F&CGISESSID=9d47b3a72238e67381c46df51b903baa&detailed=on&uKey1=DUMMY-T5&uKey2=none&uKey3=none&startDate=2005-12-31&endDate=&inputType=fromto&year=2005&week=52&month=12&quarter=4&statuspie=on&errorpie=off&bar=off&hourlyAvg=off&dailyAvg=off&details=off&topx=off&pf=off&htmlToPdf=1


# Applications  - - - - - - - - - - - - - - - - - - - - - - - - - - - - -

In collector daemon sheduling reports alleen de collectors laten zien voor overeenkomstige probe of server.

Comments kunnen zetten op een groep testen via multiselect

useraccounts flag voor wel of geen email

rename uKey of andere key plus overal waar gebruikt en delete plugin, ... met alle dependencies,

delete user gaat niet omwille van de contrains met comments en events. delet waarbij contrain tijdelijk afzetten

In view.pl -> selecteer + groeptitle toevoegen

In view.pl -> omvormen naar multiselect 'Display Daemon'

http://asnmtap.citap.be/asnmtap/nav/index/reports-index.html 
hier url naar de plugin times in plaatsen, is makkelijker om te onthouden 

fixRights script om rechten (chmod en chown) te zetten automatisch aanmaken and launch fixRights before restart daemon.

Debug files into glob field database.


# BUGS  - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - -

It's not a bug, it's a feature!

1) malformed header from script. Bad header=    : generateChart-new.pl, referer: http://asnmtap.citap.be/cgi-bin/detailedStatisticsReportGenerationAndCompareResponsetimeTrends-new.pl


# TODO CURRENT VERSION  - - - - - - - - - - - - - - - - - - - - - - - - -

# ASAP  - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - -

CRON items database-purge-perfdata, archiver.pl, generateCollectorDaemonSchedulingReports.pl, generateReports.pl & holidayBundleSetDowntimes.pl uitvoeren door de COLLECTOR test environment !!!

Awstats, ChartDirector, HTMLDOC and PerfParse installation ...


# General - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - -

Implementation from 'HTML::HTMLDoc::PDF ' located at 'http://search.cpan.org/~mfrankl/HTML-HTMLDoc-0.10/'

http://search.cpan.org/~bmorrow/PerlInterp-0.03/Perl.pm

Innodb Tranasction, bij mislukking is csv bestand wegschrijven en via archiver.pl importeren.


# NEW NEXT VERSION  - - - - - - - - - - - - - - - - - - - - - - - - - - -

Embedded Perl ondersteuning aangaande de plugins!!!

SNMP compatibility regarding the return status off the plugins

http://www.hswn.dk/hobbitsw/

Big Brother / Hobbit compatibility for easy addaptation off these plugins

  
Sending 'Notifications'
-----------------------

CREATE TABLE `timeperiods` (
  `timeperiod` varchar(15) NOT NULL default '',
  `name` varchar(64) NOT NULL default '',
  `sunday` varchar(15) default '',
  `monday` varchar(15) default '00:00-24:00',
  `tuesday` varchar(15) default '00:00-24:00',
  `wednesday` varchar(15) default '00:00-24:00',
  `thursday` varchar(15) default '00:00-24:00',
  `friday` varchar(15) default '00:00-24:00',
  `saturday` varchar(15) default '',
  `activated` tinyint(1) NOT NULL default '0',
  PRIMARY KEY  (`timeperiod`)
) TYPE=InnoDB;

# 00:00-24:00 or 00:00-09:00,17:00-24:00 or 00:00-09:00,12:00-44:00,17:00-24:00

plugins -> `timeperiod`, `notificationEnabled`, `notificationOptions`
users   -> `timeperiod`, `notificationEnabled`, `notificationOptions`, `notificationFormat`, `notificationWhen`,
                          [0|1]                   [1|2|3] or [W|C|U]    email to start ?      [n fails], after
                                          [WARNING|CRITICAL|UNKNOWN]    email, pager, sms     test fails n times
                         `notificationInterval`,                       `notificationRecovered`
                          [0|n min], 0 once                             [0|n|F], 
                          repeat every n min until problem solved       n: send notification when problem is solved after after n times ok, 
						                                                f: send notification when problem is solved using formule
                                                                           formule: min 3 <= (30 min / interval) <= max 9


Notification send where plugins->`notificationEnabled` is set
  to the users where users->`notificationEnabled` is set
  for the users->`pagedirs` into the range from plugins->`pagedirs`
    /<pagedir 1>/<pagedir 2>/<pagedir n>/ into the range from /<pagedir 1>/<pagedir 2>/<pagedir m>/
  for the plugins->`timeperiod` into the range from users->`timeperiod`


# /cgi-bin/admin/titles.pl  - - - - - - - - - - - - - - - - - - - - - - -
Webinterface to add, edit and delete titles


# - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - -

SNMPTT testing:
---------------

Try the following:

-Copy examples\snmptt.conf.generic to /etc/snmp/
-Change:

 snmptt_conf_files = <<END
 /etc/snmp/snmptt.conf
 /etc/snmp/snmptt-udc-snmp.conf
 /etc/snmp/snmptt-bea-weblogic.conf
 END

 to:

 snmptt_conf_files = <<END
 /etc/snmp/snmptt.conf.generic
 END

-shut down snmptt
-shut down snmptrapd
-extract the snmptt-unknown-300-test-traps.tgz file to /var/spool/snmptt/ (attached to this bug report)
-purge your snmptt_unknown table
-set statistics_interval = 10 in snmptt.ini to enable statistics monitoring (every 10 seconds)
-start snmptt in daemon mode
-wait until /var/spool/snmptt is empty
-wait 30 seconds
-check syslog to see how many traps were processed.  You *should* see:
 Total traps received=300,Total traps translated=0,Total traps ignored=0,Total unknown traps=300
-check the snmptt_unknown table to see how many records there are.  You should see 300.

# - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - -

