How to find source of Connection Reset Error - clojure

Where can I go look to find the source of a connection reset error? Here are the details:
I have a Clojure applet that uses clj-http.client.
I need to track down what is sending the following error
Feb 14, 2013 5:16:04 PM
org.apache.http.impl.client.DefaultRequestDirector execute
INFO: I/O exception (java.net.SocketException)
caught when processing request: Connection reset
Feb 14, 2013 5:16:04 PM
org.apache.http.impl.client.DefaultRequestDirector execute
INFO: Retrying request
We have looked through the server's IIS logs, and cannot find any error indicating a connection reset. We've also looked at the server's Event Logs, and cannot find an error that matches the error I'm getting in the client. As a matter of fact, the IIS logs look OK. I can see my address verification "GET" requests right in the log.

It's just a guess, though I often get that error message when the web server is configured to respond to the wrong host name. If it is serving for www.example.com/my/service and I open a connection to 1.2.3.4/my/service then it hangs up with "connection reset".

Related

Agent Unreachable after restore VMware Horizon Connection Server

After a power outage I got both of my View Connection Servers unbootable with BSOD and I could not recovery it and also I don't have backup of it.
After all steps below I could not get things fixed, all VMs are "Agent Unreachable"
Created a new VM for connection server (WITH THE SAME NAME AS THE OLD "VIEWCS01")
Before doing it correctly I connected the base disk, and not the last
snapshot, to the new VM and broke up the whole thing with the error
"file system specific implementation of ioctl [file] failed", I solved
this correcting the CID - https://kb.vmware.com/s/article/1007969
Installed Windows (Same version)
As in https://kb.vmware.com/s/article/76770:
Installed Connection Server (Same Version)
Restored LDF backup
Removed all View Connection Servers and all Security Servers (vdmadmin -S -s -r viewcs01, viewss01 and viewcs02)
Uninstalled the connection server
Reinstalled the connection server reusing the AD LDS
I did removed the "viewcs01" because with my previous tests I was not removing it, I think because of >this, after the recovery steps done no console was opening, In previous tests I also not using the old >machine name, instead of it I was using "viewcs03".
Ok, Console opened, I changed the vCenter credentials (Just putting password was not working with error - https://kb.vmware.com/s/article/60152 - Log below:
2020-12-31T18:23:48.108-02:00 ERROR (18F8-0D0C) <MessageFrameWorkDispatch> [ws_java_bridgeDLL] BCryptDecrypt FAILED, status={Data Error}
An error in reading or writing data occurred. (0xC000003E)
2020-12-31T18:23:48.109-02:00 ERROR (18F8-0C54) <VCHealthUpdate> [SecurityManagerUtil] decryptAsText: com.vmware.vdi.crypto.SecurityManagerException: decrypt: Cannot decrypt: Cipher scheme decryption failed.
2020-12-31T18:23:48.109-02:00 DEBUG (18F8-0C54) <VCHealthUpdate> [ServiceConnection25] Connecting instance VCHealth Test instance at URL https://vcenterd.DOMAIN.net:443/sdk
Corrected Composer credentials, and added license.
All machines are "Agent Unreachable" - Connection Server Log below:
2020-12-31T18:23:49.160-02:00 DEBUG (18F8-1A6C) <DesktopControlJMS> [DesktopTracker] CHANGEKEY message from agent/bda3fbe6-029c-41f8-b9f8-017af574f56b accepted as key and thumbprints match machine record
2020-12-31T18:23:49.162-02:00 DEBUG (18F8-1A6C) <DesktopControlJMS> [DesktopTracker] found broker thumbprints: 0f:9e:80:5d:f6:33:c7:1b:a2:d5:8c:9a:9f:12:45:16:0f:6f:c0:2b:46:8d:d0:33:62:87:53:a9:48:8d:57:8c#SHA_256;51:c5:d0:44:02:7f:ca:6d:5a:ad:5b:f6:8d:f5:11:23:e8:aa:e1:91:d0:5c:ff:71:3b:fb:e2:4b:f4:12:5e:d5#SHA_256
2020-12-31T18:23:49.162-02:00 WARN (18F8-1A6C) <DesktopControlJMS> [JMSMessageSecurity] Failed to sign message: Cannot sign message
2020-12-31T18:23:49.162-02:00 DEBUG (18F8-1A6C) <DesktopControlJMS> [DesktopTracker] CHANGEKEY message from agent/bda3fbe6-029c-41f8-b9f8-017af574f56b result: true (success)
Excerpt from VM agent log:
2020-12-31T19:53:44.322-03:00 DEBUG (1EDC-0FA8) <Thread-4> [AgentJmsConfig] Using paired signing key
2020-12-31T19:53:44.322-03:00 DEBUG (1EDC-0FA8) <Thread-4> [AgentMessageSecurityHandler] Configuring message security (ENHANCED).
2020-12-31T19:53:44.369-03:00 DEBUG (1EDC-0FA8) <Thread-4> [BrokerUpdateUtility] Published CHANGEKEY request
2020-12-31T19:53:59.386-03:00 DEBUG (1EDC-0FA8) <Thread-4> [BrokerUpdateUtility] Timeout waiting for success response
2020-12-31T19:59:33.944-03:00 DEBUG (1430-2558) <Thread-4> [JmsManager] Using connection broker viewcs01.DOMAIN.net
2020-12-31T19:59:33.944-03:00 DEBUG (1430-2494) <MessageFrameWorkDispatch> [MessageFrameWork] KeyVault service got operation=getEndEntityCertificates, ok=1, msecs=0
2020-12-31T19:59:33.944-03:00 DEBUG (1430-2494) <MessageFrameWorkDispatch> [MessageFrameWork] KeyVault service got operation=getEndEntityCertificates, ok=1, msecs=0
2020-12-31T19:59:33.975-03:00 DEBUG (1430-2558) <Thread-4> [JmsManager] username for swiftmq connection is: agent/90916ab8-704c-4fe3-a605-c4a7745b246e
2020-12-31T19:59:33.975-03:00 DEBUG (1430-2558) <Thread-4> [AgentJmsConfig] Skipping pair operation: already paired
2020-12-31T19:59:33.975-03:00 DEBUG (1430-2558) <Thread-4> [AgentMessageSecurityHandler] Configuring message security (ENHANCED).
2020-12-31T19:59:33.975-03:00 DEBUG (1430-2558) <Thread-4> [JmsManager] Re-connecting using secure port 4002
2020-12-31T19:59:34.381-03:00 DEBUG (1430-2780) <SwiftMQ-ConnectorPool-2> [AgentSSLSocketFactory] Received cert with subject cn=router/viewcs01
2020-12-31T19:59:34.381-03:00 WARN (1430-2780) <SwiftMQ-ConnectorPool-2> [AgentSSLSocketFactory] Certificate thumbprint verification failed, no matching thumbprint. Presented identity: router/viewcs01
2020-12-31T19:59:34.381-03:00 DEBUG (1430-2558) <Thread-4> [JmsManager] Unable to connect to JMS server viewcs01.DOMAIN.net com.vmware.vdi.logger.Logger.debug(Logger.java:44)
javax.net.ssl.SSLHandshakeException: java.security.cert.CertificateException: Unexpected certificate: router/viewcs01
2020-12-31T19:59:34.381-03:00 WARN (1430-2558) <Thread-4> [JmsManager] Unable to connect to any listed host. The agent will continue to retry: [viewcs02.DOMAIN.net, viewcs01.DOMAIN.net]
Reinstalled the agent and also tried the command below, as mentioned in https://kb.vmware.com/s/article/2038679, nothing has worked at all.
vdmadmin -A -d desktop-pool-name -m name-of-machine-in-pool -resetkey
Update to question:
Some piece (That I don't have now) of the log lead me to This KB, so I have uninstalled the Connection Server, remove all certificates and reinstalled it again, nothing changed.
After reading the following links [1], [2], [3]:
I've changed the security mode to Mixed, nothing changed.
But after change it to mixed and after reinstalling the Agent (I've reinstalled it before change to mixed and it didn't worked) from the VM have turned it to Available, I still not able to access machine with tunnel errors (Changed tunnel configurations also).
Updated the Connection Server to 7.13, stopped to open console.
Started the whole process from zero, now machine name is viewcs04, not worked also.
For any who encounter the same problem, I decided to create a new Connection Server and I will create manual pools, so people can work and I will migrate everyone to new linked-clone pools.
Just to mention, I cannot just create new pools, all pools are dedicated and have manually installed applications, printers etc.

org.springframework.web.client.ResourceAccessException: I/O error: com.ibm.websphere.ssl.protocol.SSLSocketFactory

I am trying to connect to SSL web service via Java batch on unix server.
I have setup all certs in my JRE keystore and setup the system property in my code:
System.setProperty("javax.net.ssl.keyStore", keyfile);
System.setProperty("javax.net.ssl.keyStorePassword",password);
Now when I am trying to access this webservice by calling it sequenctially for like 50 records, 30 records got successfully processed, but for remaining 20, I got following exception:
Exception:
org.springframework.web.client.ResourceAccessException: I/O error: com.ibm.websphere.ssl.protocol.SSLSocketFactory; nested exception is java.net.SocketException: com.ibm.websphere.ssl.protocol.SSLSocketFactory
Not sure why its coming intermittently.
Please help.

Atmosphere.js 501 Websocket protocol not supported

On Atmosphere 2.2.0 running on Jetty with a Python websocket-client-0.20.0 client, sometimes, although rarely, we get a situation where our logs fill up with the following:
12:18:01.105 WARN org.atmosphere.websocket.WebSocket: Unable to write 501 Websocket protocol not supported
12:18:01.106 WARN o.a.w.protocol.SimpleHttpProtocol: Status code higher or equal than 400. Unable to deliver the websocket messages to installed component. Status 501 Message Websocket protocol not supported
This spamming happens really fast, at about 5ms intervals, and if this occurs in production there is no other way than to take the system down. So we really need to avoid this.
It may be an issue in our client, but what I'm wondering is if there is a way to recognize these kinds of errors at the server back-end and to just close the connection, if we can't come up with a fix to the root cause?
... edit, some six months later: This issue seems to arise from an earlier Jetty exception:
11:05:54.363 ERROR o.a.container.Jetty9WebSocketHandler: {}
org.eclipse.jetty.websocket.api.WebSocketTimeoutException: Timeout on Read at org.eclipse.jetty.websocket.common.io.AbstractWebSocketConnection.onReadTimeout(AbstractWebSocketConnection.java:521) [devi
ce-interaction-service-1.0.jar:na]
at org.eclipse.jetty.io.AbstractConnection.onFillInterestedFailed(AbstractConnection.java:258) [device-interaction-service-1.0
.jar:na]
at org.eclipse.jetty.websocket.common.io.AbstractWebSocketConnection.onFillInterestedFailed(AbstractWebSocketConnection.java:4
97) [device-interaction-service-1.0.jar:na]
at org.eclipse.jetty.io.AbstractConnection$ReadCallback$1.run(AbstractConnection.java:420) [device-interaction-service-1.0.jar
:na]
at org.eclipse.jetty.util.thread.QueuedThreadPool.runJob(QueuedThreadPool.java:601) [device-interaction-service-1.0.jar:na]
at org.eclipse.jetty.util.thread.QueuedThreadPool$3.run(QueuedThreadPool.java:532) [device-interaction-service-1.0.jar:na]
at java.lang.Thread.run(Thread.java:745) [na:1.8.0_51]
11:05:54.365 DEBUG o.a.w.DefaultWebSocketProcessor: Unable to properly complete 2d48f7ce-6150-42c2-b815-93acf94bdb93
11:05:55.156 WARN org.atmosphere.websocket.WebSocket: Unable to write 501 Websocket protocol not supported
11:05:55.157 WARN o.a.w.protocol.SimpleHttpProtocol: Status code higher or equal than 400. Unable to deliver the websocket messages to installed component. Status 501 Message Websocket protocol not supported
11:05:55.201 WARN org.atmosphere.websocket.WebSocket: Unable to write 501 Websocket protocol not supported
11:05:55.202 WARN o.a.w.protocol.SimpleHttpProtocol: Status code higher or equal than 400. Unable to deliver the websocket messages to installed component. Status 501 Message Websocket protocol not supported
11:05:55.203 WARN org.atmosphere.websocket.WebSocket: Unable to write 501 Websocket protocol not supported
...
It also does seem to me that the connection is left hanging, and no #Disconnect method gets called on my #ManagedService.
I wonder how to intercept this and to just shut down the connection, forcing the client to reconnect.
Write your own WebSocketProtocol or extends the SimpleHttpProtocol#onError https://github.com/Atmosphere/atmosphere/wiki/Writing-WebSocket-Sub-Protocol

server1 instance in websphere shuts down regularly

i have a WSDL web service in the server1 instance of websphere.
this server1 instance shuts down regularly. there are no error logs being generated every time the shutdown occurs.
however, whenever the server1 instance of websphere is started, these errors and exceptions are generated:
The certificate (Owner: "CN=SOAPRequester, OU=TRL, O=IBM, ST=Kanagawa, C=JP") with alias "soaprequester" from keystore "D:\IBM\WEBSPH~1\APPSER~1\etc\ws-security\samples\dsig-sender.ks" has expired: java.security.cert.CertificateExpiredException: NotAfter: Sat Oct 01 19:24:06 CST 2011
The certificate (Owner: "CN=SOAPProvider, OU=TRL, O=IBM, ST=Kanagawa, C=JP") with alias "soapprovider" from keystore "D:\IBM\WEBSPH~1\APPSER~1\etc\ws-security\samples\dsig-receiver.ks" has expired: java.security.cert.CertificateExpiredException: NotAfter: Sat Oct 01 19:30:39 CST 2011
Method createManagedConnctionWithMCWrapper caught an exception during creation of the ManagedConnection for resource jms/BPECF, throwing ResourceAllocationException. Original exception: javax.resource.spi.ResourceAdapterInternalException: createQueueConnection failed
com.ibm.mqservices.MQInternalException: MQJE001: An MQException occurred: Completion Code 2, Reason 2063
MQJE027: Queue manager security exit rejected connection with error code 23
javax.jms.JMSSecurityException: MQJMS2013: invalid security authentication supplied for MQQueueManager
my questions are:
1. is MQ required by the WSDL service?
2. are any of these 5 errors possible for causing the frequent downtimes?
As far as I understand you have WebSphere Process Server configured with WebSphere MQ as message bus.
MQ Queue might be represented as JMS binding in SOAP over JMS configuration. IBM article.
Regarding errors:
First 2 errors are simple - certificates have expired. You should update it.
I assume 3 -5 exception are 1 error - there is answer to this question stackoverflow
2063 is security related problems.

An exception occurred when setting up mail server parameters.: cfpop

the below code was working until a few days back, but it started giving exception
<cfpop
action="getall"
name="qMessage"
server="mail.forestweb.com"
port="995"
username="email***#industryintel.com"
password="******"
timeout="30"
/>
I am running this code every 10 minutes to fetch the emails. And getting following exceptions:
Message: An exception occurred when setting up mail server parameters.
Detail : This exception was caused by: javax.mail.MessagingException:
Connect failed; nested exception is: java.net.SocketTimeoutException: Read timed out.
Can anyone please tell me why this is happening and if it has any solutions.
The root cause for me, when I had this problem, was that my harddrive was nearly full combined with the fact that there were some invalid spool files in the spool directory.
I cleared some space on the harddrive that my cf server was on and the email started sending again.
Port 995 is typically used for SSL secured connections. Natively, CFPOP does not support SSL. However, there is a way, check out this post http://www.thecfguy.com/post.cfm/ssl-support-with-cfpop
Hope that helps.