Wednesday, April 2, 2014

java.net.SocketException: Network is unreachable: connect Error for EPMSYSTEM domain


Recently, I faced an issue on the Epmsystem domain on  Weblogic for Hyperion on one server which had APS,EAS, Planning and Calculation Manager installed on it. All of the sysout logs contained no error messages  but none of the services seemed to be funcitoning. While investigating, The Epmsystem.log was full of error messages of this order, and this seemed to repeat for all projects, like in this instance, i am referring to AnalyticProviderServices1  but the error was the same for EssbaseAdministrationService1, Calculation Manager1, Planning1 etc.

#### <[ACTIVE] ExecuteThread: '0' for queue: 'weblogic.kernel.Default (self-tuning)'> <> <> <> <1393517864032> java.net.SocketException: Network is unreachable: connect
at java.net.PlainSocketImpl.socketConnect(Native Method)
at java.net.PlainSocketImpl.doConnect(PlainSocketImpl.java:351)
at java.net.PlainSocketImpl.connectToAddress(PlainSocketImpl.java:213)
at java.net.PlainSocketImpl.connect(PlainSocketImpl.java:200)
at java.net.SocksSocketImpl.connect(SocksSocketImpl.java:366)
at java.net.Socket.connect(Socket.java:529)
at weblogic.socket.SocketMuxer.newSocket(SocketMuxer.java:374)
at weblogic.socket.SocketMuxer.newClientSocket(SocketMuxer.java:384)
at weblogic.socket.ChannelSocketFactory.createSocket(ChannelSocketFactory.java:86)
at weblogic.socket.ChannelSocketFactory.createSocket(ChannelSocketFactory.java:56)
at weblogic.net.http.HttpClient.openServer(HttpClient.java:323)
at weblogic.net.http.HttpClient.openServer(HttpClient.java:425)
at weblogic.net.http.HttpClient.New(HttpClient.java:252)
at weblogic.net.http.HttpURLConnection.connect(HttpURLConnection.java:213)
at weblogic.cluster.HTTPExecuteRequest.connect(HTTPExecuteRequest.java:63)
at weblogic.cluster.HTTPExecuteRequest.run(HTTPExecuteRequest.java:82)
at weblogic.work.ExecuteThread.execute(ExecuteThread.java:256)
at weblogic.work.ExecuteThread.run(ExecuteThread.java:221)
>

The root cause was found to be that the machine though dualstacked and supporting just Ipv4 was somehow binding to the IPv6 Address of the machine.

Resolution - In the SetDomainEnv.cmd file, force the usage of IPv4 on the machine. 

"-Djava.net.preferIPv4Stack=true" is the keyword to be added to the JAVA_OPTIONS Section. An example of the usage will be, 
set JAVA_OPTIONS=%JAVA_OPTIONS% %JAVA_PROPERTIES% -Dwlw.iterativeDev=%iterativeDevFlag% -Dwlw.testConsole=%testConsoleFlag% -Dwlw.logErrorsToConsole=%logErrorsToConsoleFlag% -Djava.net.preferIPv4Stack=true

The Original line will not contain the -Djava.net.preferIPv4Stack=true is not present. After this, a complete restart of services is needed and this will help in resolving the issue.

No comments:

Post a Comment