Knowledgebase

Cannot get extensions list for version "7.4". Please make sure that native php works fine

The error message you provided suggests that there might be an issue with the native PHP installation on your server, which is preventing CloudLinux from retrieving the list of available extensions for PHP version 7.4.

Here are some steps you can take to troubleshoot and resolve this issue:

  1. Verify PHP Installation:

    • Confirm that PHP 7.4 is installed and working correctly on your server. You can do this by running:

      bash

 

    • php -v
    • Ensure that PHP 7.4 is the active version.

  • Check PHP Configuration:

    • Review the configuration files for PHP 7.4. The main configuration file is typically located in /etc/php/7.4/cli/php.ini.
  • Restart PHP-FPM:

    • If you're using PHP-FPM, restart it to ensure that any recent changes to PHP configuration take effect:

      bash
    • systemctl restart php-fpm7.4
  • Check PHP-FPM Logs:

    • Review the PHP-FPM error logs for any specific error messages related to PHP 7.4.

      lua
    • tail -f /var/log/php-fpm/error.log
  • Ensure Repository Availability:

    • Confirm that the repository providing PHP 7.4 is accessible and properly configured in your server's package manager.
  • Update Repository Metadata:

    • Refresh the repository metadata to ensure that your server has the latest information about available packages:

      bash

 

    • sudo yum clean metadata
  1. Check for Network Issues:

    • Ensure that your server has proper internet connectivity and can access external repositories. Firewall rules or network configurations might be blocking access.
  2. Check SELinux and Firewalls:

    • Verify that SELinux or any firewalls are not blocking PHP or the repositories.
  3. Test Native PHP:

    • Run a basic PHP script using the native PHP version (7.4) to ensure it's working without any issues.
  4. Contact Support:

    • If none of the above steps resolve the issue, consider reaching out to CloudLinux support or your hosting provider's support for further assistance.

Remember to back up any critical files before making changes to your server's configuration.

  • 0 Users Found This Useful
Was this answer helpful?