Changeset 30446 for branches/eam_branches/ipp-20101205/tools/roboczar.pl
- Timestamp:
- Jan 31, 2011, 2:51:48 PM (15 years ago)
- File:
-
- 1 edited
Legend:
- Unmodified
- Added
- Removed
-
branches/eam_branches/ipp-20101205/tools/roboczar.pl
r29804 r30446 7 7 8 8 # local classes 9 use czartool::Config; 9 10 use czartool::CzarDb; 10 11 use czartool::Gpc1Db; … … 15 16 use czartool::StageMetrics; 16 17 17 my $czarDbName = "czardb"; # TODO variables for other Db stuff, host etc18 18 my $save_temps = 0; 19 19 20 GetOptions ( 21 "dbname|d=s" => \$czarDbName, 22 ); 23 24 my $czarDb = new czartool::CzarDb($czarDbName, "ippdb01", "ipp", "ipp", 0, $save_temps); # TODO last arg here is save_temps, should get as arg 25 26 $czarDb->setDateFormat("%Y%m%d-%H%i%s"); 20 my $config = new czartool::Config(); 21 my $czarDb = $config->getCzarDbInstance(); 27 22 28 23 my @stages = ("burntool", "chip", "cam", "fake", "warp", "stack", "diff", "magic", "magicDS", "dist"); # TODO get from Pantasks … … 41 36 $message = ""; 42 37 43 if (anyStoppedServers( "20 MINUTE", \$serversMessage)) {38 if (anyStoppedServers($config->getRoboczarServerInterval(), \$serversMessage)) { 44 39 45 40 $message .= "\n\n" . $serversMessage; 46 41 $anythingToReport = 1; 47 42 } 48 if (anyStuckStages("2 HOUR", \$stuckMessage)) {43 # if (anyStuckStages("2 HOUR", \$stuckMessage)) { 49 44 50 $message .= "\n\n" . $stuckMessage;51 $anythingToReport = 1;52 }45 # $message .= "\n\n" . $stuckMessage; 46 # $anythingToReport = 1; 47 # } 53 48 54 49 if ($anythingToReport && $message ne $lastMessage) { … … 56 51 print "\n\n$message\n\n"; 57 52 58 sendEmail( 59 "ps-ipp-ops\@ifa.hawaii.edu", 53 sendEmail($config->getRoboczarEmail(), 60 54 "Roboczar warnings", 61 55 "$message\n"); … … 82 76 my $anyStuckStages = 0; 83 77 84 # exception - we don't care if burntool is stalled before 6:30am 78 # exception - we don't care if burntool is stalled before 6:30am TODO we do now 85 79 my $burntime = strftime('%Y-%m-%d 06:35', localtime); 86 80 my $worryAboutBurntool = $czarDb->isBefore($burntime, $end);
Note:
See TracChangeset
for help on using the changeset viewer.
