pentaho/pentaho-kettle · error · SshTimeoutException
SSH connection failed while waiting with no configured…
Error message
SSH connection failed while waiting with no configured timeout
What it means
Thrown by waitForConnection when the ConnectFuture never reaches connected state and no connectTimeout was configured (>0). Since there is no timeout, the wait loop ended through some other exit path without ever becoming connected, so the library fails fast with a descriptive message rather than hanging.
Solutions
- Set an explicit positive connectTimeout in the SSH connection config
- Check remote sshd logs for connections being dropped at accept time
- Test the same connection with a plain ssh client to confirm reachability
- Inspect the ConnectFuture exception path — look for a related 'SSH connection failed' cause in logs
Example fix
// before SshConfig cfg = new SshConfig(host, user); // connectTimeout defaults to 0 // after cfg.setConnectTimeout(15000); // fail fast with clear timeout instead of open-ended wait
Defensive patterns
Strategy: validation
Validate before calling
// before connect()
if ( config.getConnectTimeout() <= 0 ) {
throw new IllegalArgumentException( "connectTimeout must be set (>0) to get a bounded, diagnosable connect" );
} Try / catch
try { conn.connect(); }
catch ( SshTimeoutException e ) { log.error( "SSH wait failed with no timeout configured: {}", e.getMessage() ); } Prevention
- Never leave the timeout field at 0/default; set an explicit value
- Standardize SSH connection configs via a shared template
- Check remote sshd limits (MaxStartups) if connections drop at accept
- Test connectivity with the ssh CLI first
When it happens
Trigger: connect() invoked with connectTimeout == 0 (or unset) and the connection wait loop terminates without connected becoming true — e.g. the future completes with a disconnect/exception before any timeout applies.
Common situations: Users leaving the timeout field empty/default 0 in the SSH connection dialog; hosts that accept TCP then immediately close the connection (tcpwrappers, MaxStartups limits).
Understand the failure class
Background: "is required", "must be set", "missing required field": configuration validation errors across open-source libraries — this error's family across 36 libraries.
- Timeouts: ETIMEDOUT, deadlines, and hung requests — what actually expires when a request times out.
Related errors
- SSH connection timed out after ms
- Command execution timed out after
- Failed to download file:
- Failed to open SFTP session
- Failed to parse SSH key content
AI-assisted analysis of pentaho/pentaho-kettle@f3058517a1 (2026-09-13).
Data as JSON: /api/errors/c30e3b1f009a5d08.
Report an issue: GitHub.
Appendix: source
Thrown at engine/src/main/java/org/pentaho/di/core/ssh/mina/MinaSshConnection.java:264
// until the connection is established with no deadline imposed.
long connectTimeout = config.getConnectTimeoutMillis();
boolean connected;
try {
if ( connectTimeout > 0 ) {
connected = cf.await( connectTimeout );
} else {
connected = cf.await();
}
} catch ( IOException e ) {
throw new SshConnectionException( "SSH connection failed during await", e );
}
if ( !connected ) {
if ( connectTimeout > 0 ) {
throw new SshTimeoutException( "SSH connection timed out after " + connectTimeout + "ms" );
}
throw new SshTimeoutException( "SSH connection failed while waiting with no configured timeout" );
}
if ( !cf.isConnected() ) {
Throwable cause = cf.getException();
throw new SshConnectionException( "SSH connection failed", cause );
}
}
private ClientSession establishSession( ConnectFuture cf ) throws SshConnectionException {
ClientSession s = cf.getSession();
if ( s == null ) {
throw new SshConnectionException( "SSH connection failed - session is null" );
}
return s;
}
View on GitHub (pinned to f3058517a1)