Error: java.net.SocketException: "Permission denied: connect" when connecting to Nexus - Release Automation
search cancel

Error: java.net.SocketException: "Permission denied: connect" when connecting to Nexus - Release Automation

book

Article ID: 449268

calendar_today

Updated On:

Products

CA Release Automation - Release Operations Center (Nolio)

Issue/Introduction

When attempting to connect CA Release Automation (Nolio) to a Nexus 3 repository (e.g., using the "List Artifacts" or "List Repositories" actions), the connection fails with a socket exception.

Symptoms: The following error appears in the Release Operations Center (ROC) or the NAC/NES logs: Error occurred while execute [List Artifacts] : [java.net.SocketException: Permission denied: connect]

Environment

  • CA Release Automation (Nolio)
  • Sonatype Nexus 3

Cause

This error is typically caused by a network security restriction or firewall rule blocking the connection between the Release Automation server (NAC or NES) and the remote Nexus repository server.

Unlike a "Connection Timed Out" error, "Permission denied: connect" often indicates an active block by the local operating system or an intermediate firewall.

Resolution

  1. Verify the network path between the NAC/NES and the Nexus server.
  2. Check for firewall rules (iptables, firewalld, or hardware firewalls) blocking the specific port used by Nexus (default is often 8081).
  3. Ensure that the user account running the Release Automation service has the necessary permissions to open outbound sockets.
  4. If the connection is across environments (e.g., PROD to UAT), confirm that cross-zone traffic is permitted for the required ports.
  5. Validate connectivity using a tool like curl or telnet from the NAC/NES command line to the Nexus URL: curl -v http://####.####.####.####:8081/nexus

Additional Information