I had an issue where Nextcloud hang in a loop with the message “update in process”. After trying so many things, I decided to update manually.
I should say that Nextcloud runs on a FreeNas jail. When I login via PuTTy (see second picture), I have to use the command iocage console nextcloud for me to update, reinstall, or edit Nextcloud.
I have downloaded, saved data files and folders, and I’m ready to start the actual upgrade. The issue is that I need to do sudo -u www-data php occ upgrade but I get the following"
The thing is, sudo is installed but on a different path:
My question is, how to I point to the sudo command in order to install Nextcloud?
For freeBSD you can use su, make sure before on which user Nextcloud is running. www-data is the default user for Ubuntu/Debian systems. In FreeBSD it is just www, but for FreeNAS it can be different. The owner of the Nextcloud files and more specifically the owner of the files in data is most likely this user.
I can’t use sudo or su. I get the same error message. I also read the post you directed me to but even when I tried installing sudo with the command pkg install sudo I get an error:
Maybe you can fix it with pkg bootstrap -f or pkg-static bootstrap -f
But I’m not an expert when it comes to FreeBSD and iocgae. I do use TrueNAS, but only for storage.
Btw… The fact that you are talking about FreeNAS, tells me that your jails are still based on FreeBSD 11.x. Maybe it’s time to upgrade to TrueNAS Core…?
Regarding the pkg issue, I also tried several commands including the ones you suggested but I get the same error. Why is this so hard?
Since yesterday, I’ve been trying to update from 11.3 to 12.0 but I get a “base-os” error that I do not know how to solve.
Currently, I can’t update Nextcloud because I need PHP 7.3 or higher but I can’t install php either because the ‘pkg update’ command won’t work either. I want to cry.
I managed to fix the pkg error. Before, it was expecting php to be at least 7.3 (it is now 7.4 after I upgraded it) and when I try to upgrade nextcloud with the same command it says that it could not open the file?
I assume you have already tried this in the meantime. And yes you should either specify the exact path to the occ file in the command or run the command from inside the directory where it resides. If it still doesn’t work, I don’t know what else it could be. Unfortunately I don’t know FreeBSD very well.
I don’t know either… Maybe you have to configure it first in order for it to work properly. But you don’t need sudo to execute those commands. Just use su -m www -c 'insert command here'
The example in your screenshot is meant to be used on Ubuntu/Debian based Linux distributions. Other distributions have diffrent names for the Apache user. In RedHat based distributions for example it’s called “httpd”, and in FreeBSD, which isn’t a Linux distribution btw, it’s called “www” apparently.
Yes. but “occ” is missing, among other things that should be there. And honestly, I’m not sure why that is, but you could try to execute the “updater.phar” directly…
su -m www -c 'php /usr/local/www/nextcloud/updater/updater.phar'
I just marked one of the solutions where the right command is. Regarding the packet manager and such stuff, that is more related to your operating system.
Perfect. We want to avoid endless threads with different issues mixed together.