Koozali.org: home of the SME Server

Contribs.org Forums => Koozali SME Server 10.x Contribs => Topic started by: Mace on August 19, 2021, 11:48:13 AM

Title: Quick Nextcloud update question
Post by: Mace on August 19, 2021, 11:48:13 AM
Would the manual update explained in the following link work if using the 20.0.12 tarball to update the version installed by the contrib (20.0.1) or are there template expansions in /usr/share/nextcloud that need to be preserved?

https://docs.nextcloud.com/server/20/admin_manual/maintenance/manual_upgrade.html
Title: Re: Quick Nextcloud update question
Post by: TerryF on August 19, 2021, 12:34:26 PM
I suspect it may have an adverse impact..

I just updated my sme10 install of nextcloud to latest version using the inbuilt updater, so far so good
Title: Re: Quick Nextcloud update question
Post by: Jean-Philippe Pialasse on August 19, 2021, 12:57:12 PM
only use online update as administrator of nextcloud.
Title: Re: Quick Nextcloud update question
Post by: Mace on August 19, 2021, 01:42:25 PM
Thanks for the replies. I tried the online update using my personal account that I had added to the admin group and it failed on the backing up step of the update. Would I need to use the SME admin account that was added to nextcloud or the built-in nextcloudadmin account maybe?
Title: Re: Quick Nextcloud update question
Post by: TerryF on August 19, 2021, 02:19:13 PM
Thanks for the replies. I tried the online update using my personal account that I had added to the admin group and it failed on the backing up step of the update. Would I need to use the SME admin account that was added to nextcloud or the built-in nextcloudadmin account maybe?

I used my SME admin acct, all OK
Title: Re: Quick Nextcloud update question
Post by: Jean-Philippe Pialasse on August 19, 2021, 11:30:50 PM
have you tried once or also retried few times immediately and same result?

you need to investigate the error from logs

nextcloud logs in /home/e-smith/files/nextcloud/
php logs in /var/log/php/

also sometime the detailed log can be displayed when expanding the error screen during the update process


from what to what are you trying to update?
Title: Re: Quick Nextcloud update question
Post by: Mace on August 20, 2021, 02:16:03 AM
Thanks for pointing me to nextcloud logs. I looked in /var/log/php/nextcloud/error.log and saw that one file could not be read by apache:www. it was a config.php.org that i had left owned by root:root with permissions set to 640. After fixing that it all went without a hitch.

I was updating from 20.0.1 to 20.0.12, seems version 21+ required Centos 8.
Title: Re: Quick Nextcloud update question
Post by: TerryF on August 20, 2021, 04:14:38 AM
Good outcome, lesson to remember 👍
Title: Re: Quick Nextcloud update question
Post by: sages on August 20, 2021, 04:49:09 AM
fwiw I had (on sme9.2) upgraded Nextcloud to v21.01, yep living dangerously  :-P
It worked fine. It has migrated over to sme10 and is still working as expected but I mainly use it for managing a few file xfers between my laptop and mobile phone, calender and tasks.
I had the occasional issue on sme9.2 when an upgrade failed or timed out, the trick to resolve it was to run the update again from the command line. ie OCC upgrade
If that reported that there was no update available and the web interface said there was an update then ignoring it for a day or so and trying again seemed to sort it out.
The latest update is 21.04 but I haven't gone there yet. Recovering to a previous version is a pain in the ass. Don't try it on a production server.
And yes it does throw warnings on the web update page about the database not being supported anymore.
Title: Re: Quick Nextcloud update question
Post by: TerryF on August 20, 2021, 04:56:38 AM
All good info for future users...
Title: Re: Quick Nextcloud update question
Post by: Mace on August 20, 2021, 08:42:52 AM
fwiw I had (on sme9.2) upgraded Nextcloud to v21.01, yep living dangerously  :-P
It worked fine. It has migrated over to sme10 and is still working as expected but I mainly use it for managing a few file xfers between my laptop and mobile phone, calender and tasks.
I had the occasional issue on sme9.2 when an upgrade failed or timed out, the trick to resolve it was to run the update again from the command line. ie OCC upgrade
If that reported that there was no update available and the web interface said there was an update then ignoring it for a day or so and trying again seemed to sort it out.
The latest update is 21.04 but I haven't gone there yet. Recovering to a previous version is a pain in the ass. Don't try it on a production server.
And yes it does throw warnings on the web update page about the database not being supported anymore.

I run SME in a QEMU/KVM VM and I always make a "Checkpoint" snapshot before doing anything that may break my setup, and it has proven very useful a couple of times. :)
Title: Re: Quick Nextcloud update question
Post by: TerryF on August 20, 2021, 09:12:07 AM
All my test setups are Promox VMs, when sure goes onto the home server and aprod server for a NFP
Title: Re: Quick Nextcloud update question
Post by: ReetP on August 20, 2021, 11:12:12 AM
Quote
And yes it does throw warnings on the web update page about the database not being supported anymore.

Yes, I believe that is what prevents upgrade. I think there is a note or bug somewhere.

We'll look at addressing it in due course.

https://docs.nextcloud.com/server/21/admin_manual/installation/system_requirements.html

MySQL 8.0+ or MariaDB 10.2/10.3/10.4/10.5 (recommended)

PHP 8.0 (recommended)

We have PHP 8 but think Maria DB only have rpms for Maria 10.1.x on CentOS 7.

Not sure if Remi will do some.
Title: Re: Quick Nextcloud update question
Post by: Jean-Philippe Pialasse on August 20, 2021, 01:13:57 PM
up to mariadb 10.5 is available via sclo on centos 7.

juste need to make contribs to add them. 


ther eis a thin line with forcing update with older db in nextcloud. you can bork your install particularly with plugins.
some will softly fails and give the error and the mysql command they executed so you can force manually an index creation with a lower key size (frequent error is that older db does not support key size of any size)
but sole will fail without hint.


could you please open a bug for the file permission if you believe you were not the ome wrongly setting the perms on the file? so we can fix this for others

Title: Re: Quick Nextcloud update question
Post by: Mace on August 20, 2021, 04:59:54 PM
...
could you please open a bug for the file permission if you believe you were not the ome wrongly setting the perms on the file? so we can fix this for others

This was entirely my fault. I was changing/adding some config.php options and made a config.php.org backup in case I needed to revert back to the original one, and I changed perms on it for security. I've decided to store backups like that elsewhere, outside of my Nextcloud directory from now on.
Title: Re: Quick Nextcloud update question
Post by: Jean-Philippe Pialasse on August 20, 2021, 08:22:00 PM
update process is really picky i term of security. if the backup had not failed the upgrade would have failed for file not referenced in their manifest.  do not add anything manuallly there. 

Title: Re: Quick Nextcloud update question
Post by: Mace on August 22, 2021, 01:44:39 AM
update process is really picky i term of security. if the backup had not failed the upgrade would have failed for file not referenced in their manifest.  do not add anything manuallly there.

Ah yeah, that does make sense, thanks :)