<keyname="scan_apc_pdu_log_0002">[ Note ] - The APC PDU associated with the fence device: [#!variable!name!#] with 'scan_apc_pdu_uuid': [#!variable!uuid!#] is a duplicate, removing it from the database(s).</key>
<!-- Message entries (usually meant to be alerts) -->
<keyname="scan_apc_pdu_message_0001">No APC PDUs found as configured fence devices, nothing to do.</key>
@ -44,7 +45,7 @@ NOTE: All string keys MUST be prefixed with the agent name! ie: 'scan_apc_pdu_lo
<keyname="scan_apc_pdu_message_0019">The PDU: [#!variable!name!#] appears to have rebooted. The uptime changed from; [#!variable!old_uptime!#] to: [#!variable!new_uptime!#]. Was the power restored after a power outage?</key>
<keyname="scan_apc_pdu_message_0020">The wattage draw through the PDU: [#!variable!name!#] has changed from: [#!variable!old_total_wattage_draw!#] to: [#!variable!new_total_wattage_draw!#].</key>
<keyname="scan_apc_pdu_message_0021">The phase number: [#!variable!phase!#] on the PDU: [#!variable!name!#] has returned.</key>
<keyname="scan_apc_pdu_message_0022">The maximum amperage threshold on the phase: [#!variable!phase!#] of the PDU: [#!variable!name!#] has changed from: [#!variable!old_phase_max_amperage#] to: [#!variable!new_phase_max_amperage!#].</key>
<keyname="scan_apc_pdu_message_0022">The maximum amperage threshold on the phase: [#!variable!phase!#] of the PDU: [#!variable!name!#] has changed from: [#!variable!old_phase_max_amperage!#] to: [#!variable!new_phase_max_amperage!#].</key>
<keyname="scan_apc_pdu_message_0023">The amperage draw on phase: [#!variable!phase!#] of the PDU: [#!variable!name!#] has changed from: [#!variable!old_phase_current_amperage!#] to: [#!variable!new_phase_current_amperage!#].</key>
<keyname="scan_apc_pdu_message_0024">The amperage drawing through the phase: [#!variable!phase!#] of the PDU: [#!variable!name!#] is below the low-warning threshold. This is not a concern for the Anvil!, but would only happen if a user configured a low draw alert. So this could be a concern to a user of this Anvil! system.</key>
<keyname="scan_apc_pdu_message_0025">The amperage drawing through the phase: [#!variable!phase!#] of the PDU: [#!variable!name!#] has rised over the high critical alert threshold!</key>
my $results = $anvil->Database->query({query => $query, source => $THIS_FILE, line => __LINE__});
my $count = @{$results};
$anvil->Log->variables({source => $THIS_FILE, line => __LINE__, level => 2, list => {
$anvil->Log->variables({source => $THIS_FILE, line => __LINE__, level => 3, list => {
results => $results,
count => $count,
}});
@ -154,18 +154,18 @@ OR
{
my $variable_uuid = $row->[0];
my $variable_name = $row->[1];
$anvil->Log->variables({source => $THIS_FILE, line => __LINE__, level => 2, list => {
$anvil->Log->variables({source => $THIS_FILE, line => __LINE__, level => 3, list => {
's1:variable_name' => $variable_name,
's2:variable_uuid' => $variable_uuid,
}});
# Find out of there are any records to remove at all.
my $query = "SELECT history_id FROM history.variables WHERE variable_uuid = ".$anvil->Database->quote($variable_uuid)." AND modified_date <= '".$old_timestamp."';";
$anvil->Log->variables({source => $THIS_FILE, line => __LINE__, level => 2, list => { query => $query }});
$anvil->Log->variables({source => $THIS_FILE, line => __LINE__, level => 3, list => { query => $query }});
my $results = $anvil->Database->query({uuid => $uuid, query => $query, source => $THIS_FILE, line => __LINE__});
my $count = @{$results};
$anvil->Log->variables({source => $THIS_FILE, line => __LINE__, level => 2, list => {
$anvil->Log->variables({source => $THIS_FILE, line => __LINE__, level => 3, list => {
results => $results,
count => $count,
}});
@ -174,11 +174,11 @@ OR
{
# Find how many records will be left. If it's 0, we'll use an OFFSET 1.
my $query = "SELECT history_id FROM history.variables WHERE variable_uuid = ".$anvil->Database->quote($variable_uuid)." AND modified_date > '".$old_timestamp."';";
$anvil->Log->variables({source => $THIS_FILE, line => __LINE__, level => 2, list => { query => $query }});
$anvil->Log->variables({source => $THIS_FILE, line => __LINE__, level => 3, list => { query => $query }});
my $results = $anvil->Database->query({uuid => $uuid, query => $query, source => $THIS_FILE, line => __LINE__});
my $count = @{$results};
$anvil->Log->variables({source => $THIS_FILE, line => __LINE__, level => 2, list => {
$anvil->Log->variables({source => $THIS_FILE, line => __LINE__, level => 3, list => {
results => $results,
count => $count,
}});
@ -186,7 +186,7 @@ OR
{
# At least one record will be left, we can do a simple delete.
my $query = "DELETE FROM history.variables WHERE variable_uuid = ".$anvil->Database->quote($variable_uuid)." AND modified_date <= '".$old_timestamp."';";
$anvil->Log->variables({source => $THIS_FILE, line => __LINE__, level => 2, list => { query => $query }});
$anvil->Log->variables({source => $THIS_FILE, line => __LINE__, level => 3, list => { query => $query }});
push @{$queries}, $query;
}
else
@ -195,10 +195,10 @@ OR
foreach my $row (@{$results})
{
my $history_id = $row->[0];
$anvil->Log->variables({source => $THIS_FILE, line => __LINE__, level => 2, list => { history_id => $history_id }});
$anvil->Log->variables({source => $THIS_FILE, line => __LINE__, level => 3, list => { history_id => $history_id }});
my $query = "DELETE FROM history.variables WHERE variable_uuid = ".$anvil->Database->quote($variable_uuid)." AND history_id = '".$history_id."';";
$anvil->Log->variables({source => $THIS_FILE, line => __LINE__, level => 2, list => { query => $query }});
$anvil->Log->variables({source => $THIS_FILE, line => __LINE__, level => 3, list => { query => $query }});
push @{$queries}, $query;
}
}
@ -206,7 +206,7 @@ OR
}
my $commits = @{$queries};
$anvil->Log->variables({source => $THIS_FILE, line => __LINE__, level => 2, list => { commits => $commits }});
$anvil->Log->variables({source => $THIS_FILE, line => __LINE__, level => 3, list => { commits => $commits }});
@ -2054,6 +2054,8 @@ The file: [#!variable!file!#] needs to be updated. The difference is:
<keyname="log_0661">Our most recent database dump is newer than any from our peers. As such, we'll just start the database without a load.</key>
<keyname="log_0662">Retrying to connect to the database.</key>
<keyname="log_0663">The target can be reached on the dedicated migration network: [#!variable!target!#] via the IP address: [#!variable!ip!#], switching to use that for the RAM copy.</key>
<keyname="log_0664">[ Note ] - The IP address: [#!variable!ip!#] with 'ip_address_uuid': [#!variable!uuid!#] is a duplicate, removing it from the database(s).</key>