phalcon/cphalcon · error · Phalcon\Logger\Adapter\Exceptions\SyslogOpenFailed
Cannot open syslog for name
Error message
Cannot open syslog for name [{name}] and facility [{facility}] What it means
Thrown by the Syslog adapter::process when openlog() fails for the configured name and facility, so messages cannot be written to the system logger. Verify the syslog identity and facility values are valid for the platform.
Solutions
- Verify the facility value maps to a valid LOG_* constant
- Check that syslog is available/permitted in the environment (containers often lack it)
Defensive patterns
Strategy: retry
When it happens
Trigger: Thrown at phalcon/Logger/Adapter/Syslog.zep:83 when the library encounters an invalid state.
Common situations: See trigger scenarios.
AI-assisted analysis of phalcon/cphalcon@b7419de9cd (2026-08-21).
Data as JSON: /api/errors/0e7e7ce6ba5d7ef1.
Report an issue: GitHub.
Appendix: source
Thrown at phalcon/Logger/Adapter/Syslog.zep:83
}
return closelog();
}
/**
* Processes the message i.e. writes it to the syslog
*
* @throws SyslogOpenFailed
*/
public function process(<Item> item) -> void
{
var level, message, result;
let message = this->getFormattedItem(item),
result = this->openlog(this->name, this->option, this->facility);
if (!result) {
throw new SyslogOpenFailed(this->name, this->facility);
}
let this->opened = true,
level = this->logLevelToSyslog(item->getLevel());
syslog(level, message);
}
/**
* Open connection to system logger
*/
protected function openlog(string ident, int option, int facility) -> bool
{
return openlog(ident, option, facility);
}
/**
* Translates a Logger level to a Syslog levelView on GitHub (pinned to b7419de9cd)