A site fails with “Call to undefined function exec()”
A site fails with Call to undefined function exec() or the same error for shell_exec, system, passthru, proc_open, or popen. UrbeStack disables those functions by default, and you can allow one in the domain's PHP settings.
Symptoms
The page returns 500 Internal Server Error. Run urbestack-domain-log --name example.com --type php to see the error in the domain's PHP log.
[30-Nov-2026 08:13:53 UTC] PHP Fatal error: Uncaught Error: Call to undefined function exec() in /home/USER/files/web/example.com/public_html/ex.php:1
Stack trace:
#0 {main}
thrown in /home/USER/files/web/example.com/public_html/ex.php on line 1Cause
UrbeStack sets disable_functions to exec,passthru,shell_exec,system,proc_open,popen by default for sites. These six functions let PHP run shell commands.
In PHP 8, a disabled function behaves as if it did not exist, so calling it produces the error in the log. Commands run from the shell or from cron are outside the scope of this setting.
Resolution
To allow the function for this domain, set
disable_functionsto the list with that function omitted. This command allowsexec.urbestack-domain-set --name example.com --php-setting disable_functions=passthru,shell_exec,system,proc_open,popendisable_functions=noneallows all six functions. An allowed function lets the site's code run commands as the domain's owner, so allow only what the site needs.Set an empty value to return to the server's list.
urbestack-domain-set --name example.com --php-setting disable_functions=