The upgade of synapse 1.98.0~ynh1 to 104.0~ynh1 removed the app

When I look at these two URL cache folder, I see Matrix-Synapse/media/url_cache/ is more updated (so seems in use) but it lack of two folders present in /synapse/media/url_cache the /24-04-10 and the /24-04-11 folders

Could this be because of the failed upgrade and the restoration of an old backup (I lost 5 days of conversations) ?
So my guess will be the /synapse/ folder has been created during the failed migration to 104.0~ynh1 and has not been removed by the scriptd when it entirely removed my Synapse application after failing the upgrade.

Could this be possible ?

root@nos:/home/yunohost.app/matrix-synapse# du -sh /home/yunohost.app/*synapse
3.4G    /home/yunohost.app/matrix-synapse
3.4G    /home/yunohost.app/synapse

I think the /synapse folder was created by the failed upgrade script, doesn’t it?

It contains almost the same information up to 11th April, and the /matrix-synapse seems to have the same information, expect the 7-11th April period (lost information due to 5 days old backup).

I would means I could remove the /synapse folder (or move to a backup location). And the try again the upgrade.
Do you think it is reasonable ?

Well,

Here are the solution that I would apply if I was in this case, but well honestly I don’t really what happen in your case.

# copy all data which are in matrix-synapse into synapse so we are sure that we don't lost any data
cp -r /home/yunohost.app/matrix-synapse/* /home/yunohost.app/synapse/
# Remove legacy directory
rm -r /home/yunohost.app/matrix-synapse

Thanks for this advice :slightly_smiling_face:
Does this means the new /synapse/ folder will have data from /matrix-synapse/ + data from /synapse/ (from 7-11th April period) that was not on /matrix-synapse/ ?

If yes, this seems a nice move!

I am doing a backup of the /home/yunohost.app/synapse/ in case with cp -pr /home/yunohost.app/synapse/* /home/yunohost.app/synapse-backup/

I do a full backup of Synapse application.

Then I will follow your suggested process with some slight modification.

# copy all data which are in matrix-synapse into synapse so we are sure that we don't lost any data
cp -pr /home/yunohost.app/matrix-synapse/* /home/yunohost.app/synapse/
# backup legacy directory in case...
mv /home/yunohost.app/matrix-synapse /home/yunohost.app/matrix-synapse-backup

And finally, I’ll try the upgrade of Synapse and I hope to come back to you with goo news.
:slightly_smiling_face:

A great great thanks to you @Josue … the upgrade of Synapse worked !

I wish you a nice wee-end and I really thank you again a lot for all your work on synapse for so many years.

:hugs:

1 Like

That did the trick, I should have thought about it.
It all went great until … I tried to upgrade mautrix-synapse. It should probably deserve it’s own post though but in case @Josue is the maintainer here is a head’s up: the update might break other bridges.

Relevant part of the log

2024-04-21 00:06:29,878: INFO - [############++......] > Registering Synapse app-service
2024-04-21 00:06:29,879: DEBUG - + /var/www/mautrix_signal/venv/bin/python3 -m mautrix_signal -g -c /var/www/mautrix_signal/config.yaml -r /etc/matrix-synapse/app-service/mautrix_signal.yaml
2024-04-21 00:06:31,270: DEBUG - Registration generated and saved to /etc/matrix-synapse/app-service/mautrix_signal.yaml
2024-04-21 00:06:31,413: DEBUG - + /opt/yunohost/matrix-synapse/update_synapse_for_appservice.sh
2024-04-21 00:06:34,366: WARNING - Job for synapse.service failed because the control process exited with error code.
2024-04-21 00:06:34,367: WARNING - See "systemctl status synapse.service" and "journalctl -xe" for details.
2024-04-21 00:06:34,367: DEBUG - + ynh_die 'Synapse can'\''t restart with the appservice configuration'
2024-04-21 00:06:34,389: DEBUG - + ynh_exit_properly
2024-04-21 00:06:34,389: DEBUG - + [[ upgrade =~ ^install$|^upgrade$|^restore$ ]]
2024-04-21 00:06:34,389: WARNING - Synapse can't restart with the appservice configuration
2024-04-21 00:06:35,897: ERROR - Could not upgrade mautrix_signal: An error occurred inside the app upgrade script

This topic was automatically closed 15 days after the last reply. New replies are no longer allowed.