Messed up calendar(s)

Hello everybody!

Unfortunately I found out today that I messed up my calendars about three days ago while synchronizing between two Thunderbird instances. On my server I have a backup of both the Nextcloud directory and the database (mariaDB) from before the accident. However, I don’t want to completely restore the backup from four days ago, because otherwise I would miss the changes of the last three days. A solution I have in mind would be to compare both calendars and merge them back together manually. Do you have any ideas how I can best achieve this goal? In another post I read that the calendars are stored in the database. Can I extract them from there as calendar files without having to restore the whole Nextcloud?

Thank you in advance!

Yes, that is possible either by exporting the calendars from the webinterface or with the bash script calcardbackup.

Many thanks for your hint! Exporting the current calendar is of course quite easy via the web interface, but how do I get the old calendar backup (from the database backup) without resetting the complete Nextcloud?

Have a look at the README in the codeberg repository of calcardbackup to export calendars from a broken Nextcloud instance.

This could help as well:

Thanks again for the hint! If I get you right, you meant the “Does this also work with a broken ownCloud/Nextcloud instance” part of the README, right?

On my webserver I’ve done the following steps so far:

My hosting provider has backups of my databases with this scheme: “/path/to/mysql-backup/nextcloud_something.sql.xz”

Now how do I get the “nextcloud_dummy/config/config.php” to use the database from this backup instead the “live” database? I guess I have to restore the backup as a new database first and then adjust the “config.php” accordingly - but honestly I don’t know if this is right and how I do such restore.

Sorry for beeing such noobish person^^

Exactly. Have a look at this post for how to accomplish that: