Insight Remote Support
1821547 Members
2711 Online
109633 Solutions
New Discussion юеВ

Re: Bad magic error on mad.log

 
uts
Advisor

Bad magic error on mad.log

I am configuring ISEE on a new server and I get the following errors in the mad.log:

211003 10:33:07.231 ERROR,[Comm] install failed for server: isee.europe.hp.com auth_key: guest
211003 10:33:07.231 ERROR,[Comm] NetworkException (20): bad magic!

211003 10:33:07.232 ERROR,[Comm] NetworkException (20): bad magic!

211003 10:33:07.232 ERROR,[Comm] sendReceive FAILED

These are coupled with network errors when I go to the start.html page. These do not look like normal network configuration errors to me. Any ideas?

Thanks,
Debbie
14 REPLIES 14
Frauke Denker_2
Esteemed Contributor

Re: Bad magic error on mad.log

Hello Debbie,
this NetworkException (20) does not always mean an error. I have seen plenty systems reporting this error and transferring data without any problems. So if you have any problems with the transfer, if might be something else than this error. Generally this error means, that the mad expects a http reply but gets something different, like NT authentication request.
It might be neccessary to raise the loglevel of the mad to see more in the /var/opt/hpservices/log/mad.log. Therefor
stop the mad "/sbin/init.d/hpservices stop"
enter LOG_LEVEL=5 in the /opt/hpservices/etc/motprefs in the "GlobalSettings" section
start the mad "/sbin/init.d/hpservices/start"
start a transfer by /opt/hpservices/RemoteSupport/bin/iseeConnectivityTest.sh and check the mad.log.

Please, do not forget to lower the loglevel to 1 after troubleshooting.
Hope that help
Frauke
uts
Advisor

Re: Bad magic error on mad.log

Hi Frauke,

Thanks for the advice. The log file shows the following just before the error:

211003 04:24:16.343 INFO,[Comm] opening new connection to isee.americas.hp.com
211003 04:24:16.355 DEBUG,[Comm] connecting to www.us.proxy.cargill.com (10.25.2
06.155)...
211003 04:24:16.358 INFO,[Comm] connected to proxy server
211003 04:24:16.358 STDOUT,[Comm] writing request headers: 258 bytes
211003 04:24:16.359 STDOUT,[Comm] writing data: 836 bytes
211003 04:24:16.503 INFO,[Comm] STATUS: 407 REASON Proxy authorization required^
M
211003 04:24:16.505 STDOUT,[Comm] Socket::close()
211003 04:24:16.505 ERROR,[Comm] mmsg.cpp:34 NetworkException (20): bad magic!

So, does this indicate a problem with my proxy id & password?

Thanks,
Debbie
Stefan Stechemesser
Honored Contributor

Re: Bad magic error on mad.log

Hi Debbie,

looks like you have (again) the same problem as in:

http://forums1.itrc.hp.com/service/forums/questionanswer.do?threadId=226886

We are aware of a problem that the proxy password is erased each time you enter the configuration area in the user interface. Until a new client is distributed, you should always type in the proxy password before you submit any configuration changes with the ISEE UI.

Best regards

Stefan

uts
Advisor

Re: Bad magic error on mad.log

Hi Stefan,

I agree - it sounds the same but even when I re-enter the proxy information I get the same problem. I don't know if this is relevant or not, but I have tried this on 2 servers this morning both running 11.11. These are the first I have tried on this OS. Version 11.0 works just great.

Thanks,
Debbie
Stefan Stechemesser
Honored Contributor

Re: Bad magic error on mad.log

Hi Debbie,

please compare the Value of "PROXY_AUTHSTR" in /etc/opt/hpservices/etc/motprefs between the 11.0 and 11.i systems. It should be the same (if the same username and passowrd for the proxy is used). If nothing helps, try to copy the encrypted PROXY_AUTHSTR value from 11.0 server to the 11.i server and restart /sbin/init.d/hpservices (stop, then start).

Hope this helps,

Stefan
uts
Advisor

Re: Bad magic error on mad.log

Stefan - the string is the same on both OS levels.
Stefan Stechemesser
Honored Contributor

Re: Bad magic error on mad.log

If the PROXY_AUTHSTR is the same as on a working ISEE system, then the user interface correctly encoded the username and password.
I have attached a Java Class "CheckCon.class" that can be used to check the connection via the proxy. The Syntax is:

/opt/hpservices/jre/bin/java CheckCon [AP|EMEA|NA|other URL] proxy proxyPort proxyLogin proxyPassword

I think EMEA is the correct Server for you.
The output should be something like:

# /opt/hpservices/jre/bin/java CheckCon EMEA web-proxy.grc.hp.com 8088
Will attempt to connect to URL with these specs: Protocol: http
Host Name: isee.europe.hp.com
Port: 80
Path Name: /mots/motserv
Query: null
Reference: null
User Info: null
Proxy Host: web-proxy.grc.hp.com
Proxy Port: 8088
Proxy Login: null
Proxy Psswd: null
Proxy Auth: :
Proxy Auth Encode:
Attempting to connect...
Connection successful! Printing first 10 lines of returned data:
Front End Summary Page for Vendor HP_Services

Front End Statistics for Vendor HP_Services


Per Front End Statistics


Since: 12-Sep-2002 19:21:23









If this script does also not work, then you should check with your proxy admin why some host are authorized and others not. If it works, it may be a good idea to open a call in your local response center for further troubleshooting of this unusual problem.

best regards

Stefan
Best regards

Stefan
Front EndRequestsBytes SentBytes ReceivedErrors
isee-front.br.itc.hp.com:2112 10061453628

uts
Advisor

Re: Bad magic error on mad.log

Stefan,

This is the output I got after all the initial information:

Attempting to connect...
Cannot connect. Printing error stream contents:
There is no Error Stream content:java.io.FileNotFoundException: http://isee.americas.hp.com/mots/motserv

I just wanted to check I was running the script correctly. In this instance I am trying to configure a server in the US.

Thanks,
Debbie
Stefan Stechemesser
Honored Contributor

Re: Bad magic error on mad.log

Hi Debbie,

I was not able to reproduce the error message by writing garbage in the command line. What was the exact command line and output of the script (you can X-out the proxy user, password and hostname) ?
uts
Advisor

Re: Bad magic error on mad.log

Hi Stefan,

I put the following:

/opt/hpservices/jre/bin/java CheckCon NA proxyserver proxyport proxyid proxypwd


The file you sent me is in /tmp called CheckCon.class. I renamed this as it was something like 12838.class.

Thanks,
Debbie
Frauke Denker_2
Esteemed Contributor

Re: Bad magic error on mad.log

Hello Debbie,
please check the "Proxy Auth" the scripts give you before it tries to connect to the server. This should be the same as in the motprefs.
Are you using a cases-sensitive proxy? The CheckCon.class script does not support upper cases.
Another way to check what string is send to proxy during the ISEE transfer is using nettl. Try the following:
1) Check if nettl is running on the system. You should get a status output. If not, you can start it with "nettl -start":
#> /usr/sbin/nettl -status

2) There should be a minimum space of 10MB under /tmp for the trace file that is created during the monitoring phase. Of course you may even use another directory for that. Start the trace:
#> /usr/sbin/nettl -tn pduin pduout -tm 10000 -e ns_ls_ip -f /tmp/trace

3) Start any kind of transfer like /opt/hpservices/RemoteSupport/bin/iseeHello.sh

4) Stop the trace after a transfer: #> /usr/sbin/nettl -tf -e all

5) Create a filter with the Proxy IP address before formating the trace file to get only the connections to or from the Proxy Server (see opt/hpservices/etc/motprefs for the Proxy IP address):
#> vi /tmp/filter:
filter ip_daddr
filter ip_saddr

6) Check under /tmp how the trace file is named (e.g. trace.TRC000) and format it to make it readable:
#> /usr/sbin/netfmt -c filter -N -l -f /tmp/trace.TRC000 >/tmp/trace.txt


Another way to have a look at the trace is to use ethereal (you can downlad this tool from the following website: http://www.ethereal.com/download.html).

You will see the response from you proxy in the traceoutput!

Regards
Frauke
uts
Advisor

Re: Bad magic error on mad.log

Hi Frauke,

The auth string from the script does match what is in the motprefs file. The proxy is not upper case so that should not be a problem either.

I have run the trace you requested which produced the attached file. I can't really understand it but you may be able to tell me if it is working or not!

Thanks,
Debbie
Frauke Denker_2
Esteemed Contributor

Re: Bad magic error on mad.log

Hello Debbie,
it looks like your systems sends the autorisation strings ut the proxy does not accept this. We need to compare the informationin the motprefs with the infos in the unfiltered trace to check wether the informations send by the system are the same like the data in the motprefs. It might be necessary to open a call for this problem.
Regards
Frauke
uts
Advisor

Re: Bad magic error on mad.log

OK Frauke - for now I will leave it and at least get my 11.0 servers working. Thanks for your help so far.