Perl: Soap deserialization error

Sometimes the following error is displayed, if application uses the old version of CPAN SOAP module:
“Client Application failed during request deserialization: no element found at line 1, column 0, byte -1 at XML/Parser.pm”

The possilbe solution is to change SOAP::Transport::HTTP module (SOAP/Transport/HTTP.pm), function “handle”:

[cc lang=”perl”]
sysread( STDIN, $buffer, $length )
[/cc]

should be replaced by

[cc lang=”perl”]
read( STDIN, $buffer, $length )
[/cc]

Search for Oracle errors in the alert log

Search for Oracle errors in the last $NUM lines.


NUM=1000
SIGNAL_LIST='^(...-|Error|Starting.*instance)|terminating instance'

tail -$NUM alert_${ORACLE_SID}.log | awk '
BEGIN {prev="" ; ret=1 }
/'"$SIGNAL_LIST"'/ { if ( prev !~ /'"$SIGNAL_LIST"'/ ) { print "" ; print prev;} print $0;ret=0}
{prev=$0}
END { exit ret } '

On Unix Oracle alert log is normally located in bdump/alert_{ORACLE_SID}.log