prestodb/presto · error · PrestoException
NATIVE_EXECUTION_PROCESS_LAUNCH_ERROR
NATIVE_EXECUTION_PROCESS_LAUNCH_ERROR
Error message
Cannot start native process: %s
What it means
DetachedNativeExecutionProcessFactory.createNativeExecutionProcess constructs a DetachedNativeExecutionProcess, which spawns the native worker executable via ProcessBuilder-like APIs. If the OS-level launch throws IOException (executable missing, not executable, argument/redirect problems), it is converted to PrestoException with code NATIVE_EXECUTION_PROCESS_LAUNCH_ERROR.
Source
Thrown at presto-spark-base/src/main/java/com/facebook/presto/spark/execution/nativeprocess/DetachedNativeExecutionProcessFactory.java:89
@Override
public NativeExecutionProcess createNativeExecutionProcess(Session session,
Duration maxErrorDuration, Optional<TempStorageHandle> nativeTempStorageHandle)
{
try {
return new DetachedNativeExecutionProcess(
getExecutablePath(),
getProgramArguments(),
session,
httpClient,
coreExecutor,
errorRetryScheduledExecutor,
serverInfoCodec,
maxErrorDuration,
workerProperty);
}
catch (IOException e) {
throw new PrestoException(NATIVE_EXECUTION_PROCESS_LAUNCH_ERROR, format("Cannot start native process: %s", e.getMessage()), e);
}
}
}
View on GitHub (pinned to 55bb57d202)
Solutions
- Verify the native executable path configured for native execution exists on every executor node.
- Check permissions: chmod +x on the binary, and confirm it matches the node architecture/OS.
- Run ldd on the binary on an executor node to confirm all shared libraries resolve.
- Check node logs for the wrapped IOException cause; fix the underlying exec failure it reports.
Example fix
// before: launch fails because binary missing on executor
new ProcessBuilder("/opt/presto-native/not-installed/velox_exec")...
// after: validate before launching
Path bin = Paths.get(executablePath);
if (!Files.isExecutable(bin)) {
throw new PrestoException(NATIVE_EXECUTION_PROCESS_LAUNCH_ERROR,
"Native executable missing or not executable: " + executablePath);
} Defensive patterns
Strategy: validation
Validate before calling
import java.nio.file.*;
public static void validateNativeExecutable(String path) {
Path bin = Paths.get(path);
if (!Files.isRegularFile(bin)) {
throw new IllegalStateException("Native executable not found: " + path);
}
if (!Files.isExecutable(bin)) {
throw new IllegalStateException("Native executable is not executable: " + path);
}
} Try / catch
try {
NativeExecutionProcess p = factory.getNativeExecutionProcess(session, tempStorageHandle);
} catch (PrestoException e) {
if (e.getErrorCode().getName().equals("NATIVE_EXECUTION_PROCESS_LAUNCH_ERROR")) {
// check cause IOException: missing binary, permission, or arch mismatch
log.error("Native launch failed: %s", e.getCause());
}
throw e;
} Prevention
- Deploy and verify the native executable on every executor node as part of image build.
- Set executable permissions and validate architecture (uname -m) against the binary in CI.
- Run ldd/otool checks on the binary to catch missing shared libraries before deployment.
- Catch NATIVE_EXECUTION_PROCESS_LAUNCH_ERROR and surface the wrapped IOException cause in alerts.
When it happens
Trigger: Calling getNativeExecutionProcess/createNativeExecutionProcess when new DetachedNativeExecutionProcess(...) throws IOException during process spawn — executable not found, no execute permission, or I/O error creating the native process.
Common situations: Wrong native-execution executable path configuration; native binary not deployed to Spark executor nodes; binary lacks +x permission or wrong architecture (arm64 vs x86_64); missing shared libraries causing exec to fail; read-only container filesystem.
Related errors
- NATIVE_EXECUTION_PROCESS_LAUNCH_ERROR
- NATIVE_EXECUTION_BINARY_NOT_EXIST
- Failed to acquire port on host
- GENERIC_INTERNAL_ERROR
- NATIVE_EXECUTION_PROCESS_LAUNCH_ERROR
AI-assisted analysis of prestodb/presto@55bb57d202 (2026-09-04).
Data as JSON: /api/errors/c1203fb5a5a5b31e.
Report an issue: GitHub.