0

We have a setup in which one application (coordinator) delegates task to another applications (worker) and they finish the task and push back the results over socket.

It works fine but on one machine we are getting broken pipe error for most of the workers. Everything is on the same machine and we have checked firewall settings as well and they look fine.

I was just wondering that if replacing the machine Name OR IP with loopbackaddress would help as loopbackaddress does not have any hardware associated?

Please share your views on it OR if you have any other suggestion.

Exception trace -

javax.servlet.ServletException: Error building response envelope: ClientAbortException:  java.net.SocketException: Broken pipe
at org.apache.soap.server.http.RPCRouterServlet.doPost(RPCRouterServlet.java:418)
at javax.servlet.http.HttpServlet.service(HttpServlet.java:637)
at javax.servlet.http.HttpServlet.service(HttpServlet.java:717)
at org.apache.catalina.core.ApplicationFilterChain.internalDoFilter(ApplicationFilterChain.java:290)
at org.apache.catalina.core.ApplicationFilterChain.doFilter(ApplicationFilterChain.java:206)
at org.apache.catalina.core.StandardWrapperValve.invoke(StandardWrapperValve.java:233)
at org.apache.catalina.core.StandardContextValve.invoke(StandardContextValve.java:191)
at org.apache.catalina.core.StandardHostValve.invoke(StandardHostValve.java:127)
at org.apache.catalina.valves.ErrorReportValve.invoke(ErrorReportValve.java:102)
at org.apache.catalina.core.StandardEngineValve.invoke(StandardEngineValve.java:109)
at org.apache.catalina.connector.CoyoteAdapter.service(CoyoteAdapter.java:298)
at org.apache.jk.server.JkCoyoteHandler.invoke(JkCoyoteHandler.java:190)
at org.apache.jk.common.HandlerRequest.invoke(HandlerRequest.java:291)
at org.apache.jk.common.ChannelSocket.invoke(ChannelSocket.java:774)
at org.apache.jk.common.ChannelSocket.processConnection(ChannelSocket.java:703)
at org.apache.jk.common.ChannelSocket$SocketConnection.runIt(ChannelSocket.java:896)
at org.apache.tomcat.util.threads.ThreadPool$ControlRunnable.run(ThreadPool.java:690)
at java.lang.Thread.run(Thread.java:619)

Appriciate your help

Thanks

Ouney
  • 1,164
  • 1
  • 10
  • 22
  • And what is the associated error message? – fge Dec 05 '14 at 12:33
  • Have edited and added the stack trace in the question. Thanks – Ouney Dec 05 '14 at 16:22
  • Uh, OK. So, the connection has been established but then brutally closed. Nice! – fge Dec 05 '14 at 16:39
  • Yes and everything is on the same machine. We are using machine name for establishing the connection. I was just think (may be silly) if using loop back address can be of any help as it does not relate to hardware. – Ouney Dec 05 '14 at 16:42
  • Don't you have any logs on the server side? It would be strange if there weren't. If not, well, configure it so as to add logging. – fge Dec 05 '14 at 16:50

1 Answers1

1

If you received broken pipe exception it is because a connection was established and the other side suddenly closed the connection and you are trying to send data through the channel. At TCP level, the other side already sent a RST message. After that the application is trying to send data through that socket/channel. Trying to stem information from your logs, I suppose the servlet is communicating with the worker through RPC and the worker somehow closed the connection.

rodolk
  • 5,606
  • 3
  • 28
  • 34