cancel
Showing results for 
Search instead for 
Did you mean: 

Enabling http Proxy in SMD Agent

Former Member
0 Kudos

Hi

I have installed the Diagnostic Agent 7.3 on a managed SAP system and have connected it to our Solution Manager 7.1 system. However, the SAP system is not directly accessable by the Solution Manager due to our company network restrictions. I am connecting it via our saprouter which works fine except the SMD Agent is also trying to access the Solman system using URL http://<solman host>:52200/sap/bc/srt/scs/sap/e2e_dcc_push?sap-client=<client>

I notice in smdsetup.sh there are some settings output for http proxy.

_________________________________________________________________________

SAP Solution Manager - Diagnostics Agent  - Copyright (c) 2012 SAP AG

_________________________________________________________________________

------- VM Properties ----------

OS                            : Linux

OS Version                    : 2.6.32.49-0.3-default

OS Architecture               : amd64

OS data model                 : 64

Java Vendor                   : SAP AG

Java Home                     : /usr/sap/<SID>/SMDA97/exe/sapjvm_6/jre

Java Version                  : 1.6.0_41

Java Classpath                : .:lib/patch_7.10.8.0.20130129152302/launcher/smdagentlauncher.jar:lib/patch_7.10.8.0.20130129152302/sapxmltoolkit.jar:lib/patch_7.10.8.0.20130129152302/smdagent.jar:lib/patch_7.10.8.0.20130129152302/tc_sec_secstorefs.jar:lib/patch_7.10.8.0.20130129152302/iaik_jce_export.jar:lib/patch_7.10.8.0.20130129152302/smdserver.jar:lib/patch_7.10.8.0.20130129152302/logging.jar:lib/patch_7.10.8.0.20130129152302/exception.jar:lib/patch_7.10.8.0.20130129152302/sldclient.jar:lib/patch_7.10.8.0.20130129152302/sldserv.jar:lib/patch_7.10.8.0.20130129152302/jARM.jar:lib/patch_7.10.8.0.20130129152302/httpclient.jar:lib/patch_7.10.8.0.20130129152302/sapj2eeclient.jar:

Java Runtime version          : 6.1.047

Java Specfic. version         : 1.6

File Encoding                 : UTF-8

Console Encoding              : null

HTTP Proxy                    : null

HTTP Proxy port               : null

HTTP non Proxy hosts          : null

Does anyone know how to set the HTTP Proxy and port. I thought it was via the smdagent.properties via parmameter

smdagent.javaParameters=-DP4ClassLoad=P4Connection -Dhttp.proxyHost=<proxy> -Dhttp.proxyPort=<proxyport> -Xmx256m -Xms256m -XX:MaxPermSize=128m

but this did not seem to work. Any ideas welcome.

regards,

Accepted Solutions (0)

Answers (2)

Answers (2)

Former Member
0 Kudos

Hi Richard (and all the others trying to use a http proxy for SMD2SolMan communication),

I am facing a similar problem: some SMD agents (only those in the DMZ, but not the ones in the intranet!) have to connect ot our SolMan via saprouter. Thus they also should use a http (reverse)proxy (SAP Webdispatcher) for http communication to SolMan. As far as I understand, this SAP Webdispatcher can be maintained centrally at "SOLMAN_SETUP--> Configure Connectivity--> Configure Web Dispatcher". However when maintaining a SAP Webdispatcher in SOLMAN_SETUP, this would be used by ALL SMD agents! And this would not be working in our landscape. I opened an according OSS incident (new wording!) for this matter.

Best regards,

Jan

Former Member
0 Kudos

You can use saprouter to connect to sap solution manager. Check smdsetup addsaprouter option.

Former Member
0 Kudos

Hi Roman,

thanks for your response.

I have done this and it works. However, the SMD Agent also tries to execute the URL

http://<solman host>:52200/sap/bc/srt/scs/sap/e2e_dcc_push?sap-client=<client> and port 52200 is blocked in our network between the Managed System and Solution Manager. So I am trying to get this URL to go through our proxy. I identified in SMD Agent Administration where I can change the above URL (com.sap.smd.agent.application.global.configuration->dpc.url) but I am trying to configure the SMD Agent to use the HTTP Proxy to access this URL.

Any ideas?

regards,

Richard Deguara

bxiv
Active Contributor
0 Kudos

Have you tried enforcing the proxy information via the SolMan SMD Admin page?

michael_sachs2
Explorer
0 Kudos

Hi Billy,

I am facing exactly the same problem. Where in the SMD Agent Administration would you enter that information? I skipped through the different tabs, but could not find any suitable setting or property.

Moreover, there is also a hint in the troubleshooting guide to set the properties http.proxy.host, http.proxy.port and http.proxy.enable, but it does not say where to to this.

Cheers,

Michael

bxiv
Active Contributor
0 Kudos

Did you try the following application?  com.sap.smd.agent.application.global.configuration  like @Richard pointed out in the post?

michael_sachs2
Explorer
0 Kudos

The http.proxy.* properties are not present in com.sap.smd.agent.application.global.configuration. Nevertheless I added them manually, but without success. The proxy configuration is still displayed as "null" in the agent check.

I also tried to add the settings in smdagent.properties, runtime.properties, the instance profile and as -D parameters in the java command line as well, all without success.

And yes, I did a restart of the agent after each change. I still got the famous "connection timed out" message in the agent log.

Former Member
0 Kudos

For smdsetup script you need to use proxyHost and proxyPort properties without http. prefix, e.g.

java -DproxyHost= -DproxyPort= ...

Former Member
0 Kudos

Hi Michael,

I performed the same changes as you also without success.

Hi Roman,

can you be a bit more specific on the setting I should make? You mention in the smdsetup script these changes should be made. But the script has no option to set the java parameters. Should I update the smdagent.properties file as :

smdagent.javaParameters=-DP4ClassLoad=P4Connection -Xmx256m -Xms256m -XX:MaxPerm

Size=128m -DproxyHost=<proxyhost> -DproxyPort=<proxyport>

regards

Richard

Former Member
0 Kudos

Try this and report the result.

michael_sachs2
Explorer
0 Kudos

Hi Richard,

a SAP consultant pointed us to the properties wsnotify.proxy.enable, wsnotify.proxy.host and wsnotify.proxy.port. These properties can be set in step 4 of the End-User Experience setup guided procedure. The step is called "Monitoring". The settings are available in the "Global" tab using the "Add" button.

After configuring these settings (and restarting the agents of course), our SMD agents were able to report back the script results and also proper alerts were triggered. We got rid of the agent log error message for the service "ai_eem_bulk_notification", however the error message for service "e2e_dpc_push" persists.

Hope that helps.

Best regards,

Michael

Former Member
0 Kudos

Hi Michael,

thanks for your update. This does not relate directly to my problem but I will take note of the mentioned parameters for future reference.

After many months of trying to resolve this issue I think I am close to identifying how to configure SMD agents using a http proxy for web services. Based on SAP note 1396827 ,and as we have suspected, the following JVM parameters should be set.

- http.proxyHost
- http.proxyPort
- http.proxyUserName
- http.proxyPassword
- http.nonProxyHosts


The errors I am getting hint that the SMD Agent is using the JAXM API for web services

        at com.sap.engine.services.webservices.jaxm.soap.HTTPSocket.initStreamsFromSocket(HTTPSocket.java:695)

        at com.sap.engine.services.webservices.jaxm.soap.HTTPSocket.initializeStreams(HTTPSocket.java:512)

        at com.sap.engine.services.webservices.jaxm.soap.HTTPSocket.getOutputStream(HTTPSocket.java:469)


For JAXM API the method used to get the proxy settings is from the above JVM parameters


To set these parameters I made the following addition to the SMD Agent profile parameter located in /usr/sap/<SID>/SYS/profile/<SID>_SMDA97_<host>

jstartup/vm/parameters = -Dhttp.proxyHost=<my proxy host> -Dhttp.proxyPort=8080  -XtraceJdkInternals

The -XtraceJdkInternals will output the JDK internals to std_smdagent_<hostname>.out in the work directory. This can be used to confirm you have correctly set the http parameters.

I restarted the Agent and tested again. However, the problem has not been resolved. I have now raised an OSS message to see if there is a bug in the SMD Agent or applications running on it.

To confirm I am not the only one experiencing the problem can someone else try the changes I made above and let me know if you are able to get this to work.

For reference I am using Solman 7.1 SP08. I see SP10 is coming out so I wonder if either SP09 or SP10 also have this problem with proxies.

Any feedback would be appreciated.

regards,

Richard

michael_sachs2
Explorer
0 Kudos

Hi Richard,

I also tried adding http.proxy* parameters to the SMD agent profile before being referred to the wsnotify.proxy* properties, but without success (see my reply dated Sep 2, 2013 2:56 PM). But maybe your problem is a bit different from mine. Please report what SAP suggested as solution.

Best regards,

Michael