Verify and switch PHP versions?

Trying to get ready to upgrade my version of NC and wanted to verify and switch PHP versions. But…I’m VERY confused. I’m running Ubuntu and when I run, “php -v” I get:
“PHP 8.3.4 (cli) (built: Mar 16 2024 08:40:08) (NTS)
Copyright (c) The PHP Group
Zend Engine v4.3.4, Copyright (c) Zend Technologies
with Zend OPcache v8.3.4, Copyright (c), by Zend Technologies”

However, when I go into NC, Admin, system I see:
"Version: 8.1.27

Memory limit: 512 MB

Max execution time: 3600

Upload max size: 100 GB

Extensions: Core, date, libxml, openssl, pcre, zlib, filter, hash, json, Reflection, SPL, session, standard, sodium, apache2handler, mysqlnd, PDO, xml, apcu, bcmath, calendar, ctype, curl, dom, mbstring, FFI, fileinfo, ftp, gd, gettext, gmp, iconv, igbinary, imagick, intl, ldap, exif, mysqli, pdo_mysql, Phar, posix, readline, redis, shmop, SimpleXML, smbclient, sockets, sysvmsg, sysvsem, sysvshm, tokenizer, xmlreader, xmlwriter, xsl, zip, libsmbclient, Zend OPcache"

Does this mean that I have 8.3 installed, but not enabled?
How can I check to make sure that if I switch to 8.3 that I have all the correct extensions?

I tried last week to do a bunch of upgrades of NC from 27 to 29 and at the end I had a system that, “sorta” worked. LOL. NC would run, but had a bunch of errors, links weren’t working, etc. So, I restored from backup back to 27. I’d like to not repeat those mistakes.

I think Php-updater - a script to upgrade php in a safe way will help you with switching php versions.

1 Like