Added 'timeout' logging to help debug SIGALARM exits.

Signed-off-by: digimer <mkelly@alteeve.ca>
Signed-off-by: Madison Kelly <mkelly@alteeve.com>
main
Madison Kelly 7 months ago
parent cfa3432e78
commit 4b82c5f2bf
  1. 18
      Anvil/Tools/Network.pm
  2. 4
      Anvil/Tools/System.pm
  3. 4
      share/words.xml

@ -4283,6 +4283,24 @@ sub ping
target => $target, target => $target,
is_local => $is_local, is_local => $is_local,
}}); }});
if ($timeout)
{
if ($is_local)
{
$anvil->Log->entry({source => $THIS_FILE, line => __LINE__, level => 2, secure => $secure, key => "log_0855", variables => {
shell_call => $shell_call,
timeout => $timeout,
}});
}
else
{
$anvil->Log->entry({source => $THIS_FILE, line => __LINE__, level => 2, secure => $secure, key => "log_0853", variables => {
shell_call => $shell_call,
timeout => $timeout,
target => $target,
}});
}
}
if ($is_local) if ($is_local)
{ {
### Local calls ### Local calls

@ -309,6 +309,10 @@ sub call
if ($timeout) if ($timeout)
{ {
# Prepend a timeout. # Prepend a timeout.
$anvil->Log->entry({source => $THIS_FILE, line => __LINE__, level => 2, secure => $secure, key => "log_0855", variables => {
shell_call => $shell_call,
timeout => $timeout,
}});
$shell_call = $anvil->data->{path}{exe}{timeout}." ".$timeout." ".$shell_call; $shell_call = $anvil->data->{path}{exe}{timeout}." ".$timeout." ".$shell_call;
$anvil->Log->variables({source => $THIS_FILE, line => __LINE__, level => $debug, secure => $secure, list => { shell_call => $shell_call }}); $anvil->Log->variables({source => $THIS_FILE, line => __LINE__, level => $debug, secure => $secure, list => { shell_call => $shell_call }});
} }

@ -2742,6 +2742,8 @@ new key: [#!variable!new_key!#]</key>
<key name="log_0852">Finished configuring bonds.</key> <key name="log_0852">Finished configuring bonds.</key>
<key name="log_0853">Now configuring bridges.</key> <key name="log_0853">Now configuring bridges.</key>
<key name="log_0854">The connection to the database: [#!variable!server!#] has been restored!</key> <key name="log_0854">The connection to the database: [#!variable!server!#] has been restored!</key>
<key name="log_0855">Calling: [#!variable!shell_call!#] via a 'timeout' of: [#!variable!timeout!#] seconds.</key>
<key name="log_0856">Calling: [#!variable!shell_call!#] on: [#!variable!target!#] via a 'timeout' of: [#!variable!timeout!#] seconds.</key>
<!-- Messages for users (less technical than log entries), though sometimes used for logs, too. --> <!-- Messages for users (less technical than log entries), though sometimes used for logs, too. -->
<key name="message_0001">The host name: [#!variable!target!#] does not resolve to an IP address.</key> <key name="message_0001">The host name: [#!variable!target!#] does not resolve to an IP address.</key>
@ -3109,7 +3111,7 @@ Are you sure that you want to delete the server: [#!variable!server_name!#]? [Ty
<key name="message_0263">Preparing to get server VM screenshot.</key> <key name="message_0263">Preparing to get server VM screenshot.</key>
<key name="message_0264">Finished getting server VM screenshot.</key> <key name="message_0264">Finished getting server VM screenshot.</key>
<key name="message_0265">Failed to get server VM screenshot; got non-zero return code.</key> <key name="message_0265">Failed to get server VM screenshot; got non-zero return code.</key>
<key name="message_0266">Finished attempting to get server VM screenshot; no operations happened because requirements not met.</key>>>> master <key name="message_0266">Finished attempting to get server VM screenshot; no operations happened because requirements not met.</key>
<key name="message_0267">Preparing to manage DR for a server.</key> <key name="message_0267">Preparing to manage DR for a server.</key>
<key name="message_0268">UUID Column counts for: [history.#!variable!table!#]:</key> <key name="message_0268">UUID Column counts for: [history.#!variable!table!#]:</key>
<key name="message_0269">Counting entries for each unique: [#!variable!column!#] in the table [#!variable!table!#]. Please be patient.</key> <key name="message_0269">Counting entries for each unique: [#!variable!column!#] in the table [#!variable!table!#]. Please be patient.</key>

Loading…
Cancel
Save