phacility/phabricator · error · PhutilArgumentUsageException
No `%s` or `%s` binary was found in %s. You must install Nod
Error message
No `%s` or `%s` binary was found in %s. You must install Node.js to start the Aphlict server.
What it means
Thrown by getNodeBinary() when neither `nodejs` nor `node` can be found in $PATH. Aphlict's server is a Node.js application launched by this PHP management workflow, so Node.js is a hard dependency; the '%s' slots are filled with 'nodejs', 'node', '$PATH'.
Source
Thrown at src/applications/aphlict/management/PhabricatorAphlictManagementWorkflow.php:527
$console->writeErr("%s\n", pht('Sending %s a SIGKILL.', $pid));
posix_kill($pid, SIGKILL);
unset($pid);
}
Filesystem::remove($this->getPIDPath());
return 0;
}
private function getNodeBinary() {
if (Filesystem::binaryExists('nodejs')) {
return 'nodejs';
}
if (Filesystem::binaryExists('node')) {
return 'node';
}
throw new PhutilArgumentUsageException(
pht(
'No `%s` or `%s` binary was found in %s. You must install '.
'Node.js to start the Aphlict server.',
'nodejs',
'node',
'$PATH'));
}
private function getAphlictScriptPath() {
$root = dirname(phutil_get_library_root('phabricator'));
return $root.'/support/aphlict/server/aphlict_server.js';
}
private function getNodeArgv() {
$argv = array();
$hint = idx($this->configData, 'memory.hint');
$hint = nonempty($hint, 256);View on GitHub (pinned to 5720a38cfe)
Solutions
- Install Node.js (distro package or nodesource) and confirm `which node nodejs`
- If installed but not found: export PATH=$PATH:/usr/local/bin (or similar) in the launching shell/unit; for systemd add Environment=PATH=/usr/local/bin:/usr/bin:/bin to the unit
- For sudo contexts, check sudoers secure_path includes the directory containing node
Example fix
# before $ bin/aphlict start # -> No `nodejs` or `node` binary was found in $PATH # after (Debian/Ubuntu) $ sudo apt-get install -y nodejs $ bin/aphlict start # systemd unit fix: # [Service] # Environment=PATH=/usr/local/bin:/usr/bin:/bin
Defensive patterns
Strategy: validation
Validate before calling
if (!Filesystem::binaryExists('nodejs') && !Filesystem::binaryExists('node')) {
throw new InvalidArgumentException(
'Node.js not found in PATH; install it before starting aphlict');
}
// shell: command -v node nodejs Prevention
- Include Node.js in provisioning and assert `command -v node` in deploy pre-flight
- For systemd/cron launches, set an explicit Environment=PATH that includes the node binary's directory
When it happens
Trigger: Node.js not installed on the host, or installed but not on the PATH of the context launching aphlict (cron with minimal PATH, systemd unit without environment, sudo resetting PATH via secure_path).
Common situations: Fresh server provisioning that skipped the Node.js step of the install docs; Debian-family systems naming the binary nodejs while custom PATHs expect node; systemd units lacking Environment=PATH.
Related errors
- Specify a user to notify with "--user".
- No user with username "%s" exists.
- Specify a message to send with "--message".
- Failed to read configuration file. %s
- Configuration file is not properly formatted JSON. %s
AI-assisted analysis of phacility/phabricator@5720a38cfe (2026-08-21).
Data as JSON: /api/errors/430781cd1bada0ce.
Report an issue: GitHub.