Connection closed before acknowledgement sent
Hello,
Our Jenkins Controller is running on ec2 in AWS and we used this plugin to create a cloud in ECS Fargate - used same VPC and subnets.
The master/controller is currently an IP address with http protocol - non NLB yet.
The ECS agent container gets spun up on demand but it does not connect to master and gives below errors in agent log. On exec into that container and manually running the commands , the jobs work 👍
Please help.
Thanks
curl -sO ht: 10.24.149/jnlpJars/agent.jar
java -jar agent.jar -url http://10.198.24.149/ -secret ba39d7b5089b4c4d93e762b1fb1d15b32fea26aeaec6f77d50a4c26637cf216e -name "myaaa-ecs-workers-slave1-r5qq7" -webSocket
May 09, 2025 3:44:48 PM hudson.remoting.Launcher createEngine INFO: Setting up agent: myadp-ecs-workers-slave1-r5qq7 May 09, 2025 3:44:48 PM hudson.remoting.Engine startEngine INFO: Using Remoting version: 3283.v92c105e0f819 May 09, 2025 3:44:48 PM hudson.remoting.Engine startEngine WARNING: No Working Directory. Using the legacy JAR Cache location: /root/.jenkins/cache/jars May 09, 2025 3:44:49 PM hudson.remoting.Launcher$CuiListener status INFO: WebSocket connection open May 09, 2025 3:44:49 PM hudson.remoting.Launcher$CuiListener status INFO: Connected
the errors in agent log after agent startup are below
2025-05-09T11:49:59.194-04:00 | May 09, 2025 3:49:59 PM hudson.remoting.Launcher$CuiListener status -- | -- | 2025-05-09T11:49:59.194-04:00 | INFO: Connecting to 10.198.24.149:80 | 2025-05-09T11:49:59.195-04:00 | May 09, 2025 3:49:59 PM hudson.remoting.Launcher$CuiListener status | 2025-05-09T11:49:59.195-04:00 | INFO: Server reports protocol JNLP4-connect-proxy not supported, skipping | 2025-05-09T11:49:59.195-04:00 | May 09, 2025 3:49:59 PM hudson.remoting.Launcher$CuiListener status | 2025-05-09T11:49:59.195-04:00 | INFO: Trying protocol: JNLP4-connect | 2025-05-09T11:49:59.196-04:00 | May 09, 2025 3:49:59 PM org.jenkinsci.remoting.protocol.impl.BIONetworkLayer$Reader run | 2025-05-09T11:49:59.196-04:00 | INFO: Waiting for ProtocolStack to start. | 2025-05-09T11:49:59.202-04:00 | May 09, 2025 3:49:59 PM org.jenkinsci.remoting.protocol.impl.AckFilterLayer abort | 2025-05-09T11:49:59.203-04:00WARNING: [JNLP4-connect connection to ip-10-198-24-149.us-west-2.compute.internal/10.198.24.149:80] Incorrect acknowledgement sequence, expected 0x000341434b got 0x485454502f | WARNING: [JNLP4-connect connection to ip-10-198-24-149.us-west-2.compute.internal/10.198.24.149:80] Incorrect acknowledgement sequence, expected 0x000341434b got 0x485454502f | 2025-05-09T11:49:59.204-04:00 | May 09, 2025 3:49:59 PM hudson.remoting.Launcher$CuiListener status | 2025-05-09T11:49:59.204-04:00 | INFO: Protocol JNLP4-connect encountered an unexpected exception | 2025-05-09T11:49:59.204-04:00 | java.util.concurrent.ExecutionException: org.jenkinsci.remoting.protocol.impl.ConnectionRefusalException: Connection closed before acknowledgement sent | 2025-05-09T11:49:59.204-04:00 | at org.jenkinsci.remoting.util.SettableFuture.get(SettableFuture.java:222) | 2025-05-09T11:49:59.204-04:00 | at hudson.remoting.Engine.innerRun(Engine.java:1028) | 2025-05-09T11:49:59.204-04:00 | at hudson.remoting.Engine.run(Engine.java:587) | 2025-05-09T11:49:59.204-04:00 | Caused by: org.jenkinsci.remoting.protocol.impl.ConnectionRefusalException: Connection closed before acknowledgement sent | 2025-05-09T11:49:59.204-04:00 | at org.jenkinsci.remoting.protocol.impl.AckFilterLayer.onRecvClosed(AckFilterLayer.java:290)
I'll admit I'm still working on getting my agents working, but reading on your error log, my gut tells me that 00 | INFO: Server reports protocol JNLP4-connect-proxy not supported, skipping is where you should start your debugging. Clearly what follows is probably related to this. What machine is the .149? Are the master and slaves on the same network?