Upgraded the server from Ubuntu 18.04 to Ubuntu 20.04 which automatically upgraded php 7.2 to 8.1 and broke the NC 15 upgrade path.
Lesson learned:
1st do not upgrade Ubuntu 20.04 which default installs php 7.4 and prevents NC 15 to 16 upgrades because prefers php 7.2 and not 7.4
Error:Thiis version of Nextcloud is not compatible with > PHP 7.3
Had to do comment out code in so I can upgrade:
sudo /var/www/nextcloud/lib/versioncheck.php
Once I got to NC 25.0.1, I made sure the php8.1 modules installed matched php 7.4
Manually select the php version to use
sudo update-alternatives --config php
I am prepared for the end of Nov 2022 when php7.4 is no longer supported.
Planning to switch to Ubuntu 22.04 when NC 25.0.1 can reliably support php8.1