Reading your logs, the error message
Connection refused
is meaning that the Driver is working fine, but there is a connection issue and in your case, using the Secure Gateway, you should investigate both the AS400 server and the Secure gateway instance
- #1 is the TCP port 15XXX (the one tried to connect to by the driver following the JDBC url) mapped correctly on the Secure Gateway instance
- #2a if the #1 is true, is the AS400 server listening on the same TCP port for incoming connections?
- #2b if #2a is false, is the AS400 server listening on a different TCP port?
- #3 according to the TCP port listened on by the AS400 server (#2a or #2b) is this port mapped correctly on the Secure Gateway instance, allowing the requests sent to the TCP 15XXX through the Secure Gateway routed correctly to the right port on the AS400 server?
- #4 if #3 is true, has the AS400 server an internal firewall preventing incoming connections?