I’m using the standard docker-compose version of OpenEdX and this morning when installing the backup plugin for OpenEdX, which the installation seemed to go fine and I admit that at that point I didn’t check to see if the site was working.
My maintenance window came and went while I worked on an error that was being generated by the backup plugin:
2061, 'RSA Encryption not supported - caching_sha2_password plugin was built with GnuTLS support'.
Once I got past that error and made my first backup, I noticed that the Caddy directory was very small and immediate checked the site and got a 502 error.
I thought “No problem, I still have my /data/caddy backup here I’ll just replace it” but that directory was also empty.
The databases, however, are intact.
Now it comes down to my question:
Assuming we have the media that was deleted, videos, photos, etc-- is there a way we can “reconstitute” everything then re-embed or re-upload our media?
Edit: For example, I have a complete mongodb dump, mysql dump, and… an empty caddy directory.
I’m wondering if the caddy directory was gone before I ever got my first backup.
It seems that there is a misunderstanding. Caddy is not used for storing videos, images, etc. Caddy is the web proxy of the Open edX platform. The Caddy data directory stores only certificates information. And that data is probably automatically generated because Caddy generates certificates with certbot.
I do not understand how you came to the conclusion that the supposedly missing Caddy data was causing the 502 errors. That conclusion is probably mistaken. What are the logs coming from the caddy container? tutor local logs --tail=100 caddy
Looks like the database connections are failing because I changed the user to connect with native mysql passwords. I can probably just fix that by regenerating the database user.
I recreated – but probably still did it wrong because I get the error:
drop user 'root'@'%';
drop user 'root'@'localhost';
create user 'root'@'%' identified with caching_sha2_password by 'password';
create user 'root'@'localhost' identified with caching_sha2_password by 'password';
rm /etc/my.cnf -- (As I had created a custom my.cnf)
tutor local restart
I’m glad things seem to be working for you again. You should be aware that it is very likely that your database is going to be failing again next time you run tutor local launch or tutor local do init. That’s because the root user password is going to be re-defined.