Home  >  Q&A  >  body text

Ubuntu VirtualMin - Unable to detect correct PhP version

<p>I installed a fresh Ubuntu server with Virtualmin. It automatically installed Php version 7.2, but I need 7.4. So I installed version 7.4. When I check the version using the -v command, it shows 7.4. However, Webmin and WordPress still only see and use version 7.2. I tried uninstalling version 7.2 but the command failed and told me the module doesn't exist, but I can see it in the list of installed versions in ssh. When I try to change the php version, it doesn't show up as an option in Virtualmin, only the 7.2 version. </p> <p>Any suggestions on how to resolve this issue? I'm confused. Thanks! </p>
P粉647449444P粉647449444389 days ago459

reply all(1)I'll reply

  • P粉821231319

    P粉8212313192023-08-27 00:19:32

    You can try the following commands:

    sudo update-alternatives --set php /usr/bin/php7.4

    For more detailed information, you can also refer to the following link:

    https://hackthestuff.com/article/how-to-change-php-version-from-command-line-in-ubuntu

    reply
    0
  • Cancelreply