Skip to Content

PHP function ’exec’ is not available.

How to Resolve the ERROR: " PHP function 'exec' is not available." while Installing Ezeelogin.


Overview: This article describes steps to resolve the 'PHP function 'exec' is not available' error during Ezeelogin installation on Ubuntu by editing php.ini to enable the exec function.


If you encounter the error "PHP function 'exec' is not available. Please enable it." while installing Ezeelogin on Ubuntu, follow these steps:

This error occurs as your server doesn't have the exec function enabled.

Step 1: Open the php.ini file with a text editor. 

root@gateway:~# nano /etc/php/8.2/cli/php.ini

Step 2: Search for the disable_functions directive within the php.ini file and remove 'exec'

Before:

disable_functions = exec

  • Remove the exec function as mentioned below and save the file.

After:

disable_functions = 

Step 3: Restart the webserver to apply the changes. Depending on your setup, you might need to restart Apache.

root@gateway:~# systemctl restart apache2

By following these steps, you will enable the exec function in PHP, resolving the error encountered during the installation of Ezeelogin. Adjust the PHP version (8.2 in this example) as necessary based on your server configuration.

Feel free to get help from support if you encounter any issues or need further assistance!


Related Articles:

PHP-mcrypt is required

PHP-fatal error

Switch PHP versions in Ubuntu

Upgrade PHP to 8.1 in Ubuntu