NicToolServer on Centos 5.1 i386

Started by squegie, April 11, 2008, 10:27:26 PM

Previous topic - Next topic

squegie

Hello,

I am mostly just looking for some guidance on what I need to look at next.  I haven't run across this before.

I am migrating NicTool from a FreeBSD system to a newer system running Centos 5.1.  NicToolClient seems to be working fine, but NicToolServer gives a 500 error.  I even pointed the NicToolClien on the Centos machine back to the FreeBSD NicToolServer and that worked.  But when the request goes to the NicToolServer on the Centos machine, it returns a 500.

The '2s': NicTool 2.06/Apache2/mod_perl2/Apache2::SOAP

specificallY:

Apache 2.2.4
Perl 5.8.8
mod_perl-2.0.3
Apache-DBI-1.06
Apache2-SOAP-0.72
DBD-mysql-4.006
DBI-1.604
RPC-XML-0.60
SOAP-Lite-0.71
XML-LibXML-1.66
XML-Parser-2.36


When I enable debug and watch the error_log, I get the following:

Calling soap function "login" with params:, referer: https://www.ytnoc.net/nictool/index.cgi
$VAR1 = {, referer: https://www.ytnoc.net/nictool/index.cgi
           'nt_protocol_version' => '1.0',, referer: https://www.ytnoc.net/nictool/index.cgi
           'password' => 'password',, referer: https://www.ytnoc.net/nictool/index.cgi
           'username' => 'username', referer: https://www.ytnoc.net/nictool/index.cgi
         };, referer: https://www.ytnoc.net/nictool/index.cgi
, referer: https://www.ytnoc.net/nictool/index.cgi
[Fri Apr 11 22:13:04 2008] [error] [client 65.40.71.221] HTTP::Message content not bytes at /usr/lib/perl5/site_perl/5.8.8/SOAP/Transport/HTTP.pm line 424\n
SOAP result SCALAR: $VAR1 = ', referer: https://www.ytnoc.net/nictool/index.cgi
syntax error at line 1, column 49, byte 49 at /usr/lib/perl5/site_perl/5.8.8/i386-linux-thread-multi/XML/Parser.pm line 187, referer: https://www.ytnoc.net/nictool/index.cgi
<!DOCTYPE HTML PUBLIC "-//IETF//DTD HTML 2.0//EN">, referer: https://www.ytnoc.net/nictool/index.cgi
<html><head>, referer: https://www.ytnoc.net/nictool/index.cgi
<title>500 Internal Server Error</title>, referer: https://www.ytnoc.net/nictool/index.cgi
</head><body>, referer: https://www.ytnoc.net/nictool/index.cgi
<h1>Internal Server Error</h1>, referer: https://www.ytnoc.net/nictool/index.cgi
<p>The server encountered an internal error or, referer: https://www.ytnoc.net/nictool/index.cgi
misconfiguration and was unable to complete, referer: https://www.ytnoc.net/nictool/index.cgi
your request.</p>, referer: https://www.ytnoc.net/nictool/index.cgi
<p>Please contact the server administrator,, referer: https://www.ytnoc.net/nictool/index.cgi
  support@yourtech.us and inform them of the time the error occurred,, referer: https://www.ytnoc.net/nictool/index.cgi
and anything you might have done that may have, referer: https://www.ytnoc.net/nictool/index.cgi
caused the error.</p>, referer: https://www.ytnoc.net/nictool/index.cgi
<p>More information about this error may be available, referer: https://www.ytnoc.net/nictool/index.cgi
in the server error log.</p>, referer: https://www.ytnoc.net/nictool/index.cgi
</body></html>, referer: https://www.ytnoc.net/nictool/index.cgi
';, referer: https://www.ytnoc.net/nictool/index.cgi
, referer: https://www.ytnoc.net/nictool/index.cgi


(I also tried it under http for good measure).

The problem seems to be in the SOAP handling.

Finally, for completeness, here is the config file loaded by Apache.


LoadModule perl_module modules/mod_perl.so

<IfDefine !MODPERL2>
   PerlFreshRestart On
</IfDefine>
PerlTaintCheck Off
   
Listen 8082

PerlRequire /usr/local/NicToolServer/nictoolserver.conf
PerlRequire /usr/local/NicToolClient/lib/nictoolclient.conf

Alias /nictool/images/ "/usr/local/NicToolClient/htdocs/images/"
Alias /nictool/ "/usr/local/NicToolClient/htdocs/"

<Directory /usr/local/NicToolClient/htdocs/>
        DirectoryIndex  index.cgi index.html
</Directory>


<VirtualHost 65.40.71.221:8082>
    KeepAlive Off
    <Location />
        SetHandler perl-script
        PerlResponseHandler NicToolServer
    </Location>
    <Location /soap>
        SetHandler perl-script
        # ATTENTION: Comment out one or the other!
        #PerlResponseHandler Apache::SOAP
        PerlResponseHandler Apache2::SOAP
        # /ATTENTION
        PerlSetVar dispatch_to "/usr/local/NicToolServer, NicToolServer::SOAP"
    </Location>
</VirtualHost>



Finally, if I go to http://www.ytnoc.net:8082/   I get an XML response page (please login)
If I go to http://www.ytnoc.net:8082/soap  I get an Internal server error and this log entry:

Handler for perl-script returned invalid result code 1
The LENGTH argument can't be negative at /usr/lib/perl5/site_perl/5.8.8/SOAP/Transport/HTTP2.pm line 103.\n