I’ve got an instance running on v1.0.0-beta.10.pre.3, here, with about 80 Gb of videos.
I plan to migrate to a new server, and I would like to upgrade to latest (2.4.0) version.
I was planning the following :
- Install fresh new instance of Peertube 2.4 on my new server
- Dump SQL data from old server
- Move data file from old to new server (80 Gb of data)
- Restore SQL data to new server
I was not expecting it to be easy obviously …
I guess DB schema has changed in the meaning … and it has.
I get the following errors :
So my questions are :
- How do I get the migration script executed on my old server without breaking anything ?
- I was looking migration scripts in the code (*sql or something) but did not find any.
- Is migration from 1.0.0 supported ?
- Is my strategy OK ?
- Do I also need some reencoding ?
Thanks in advance for your help.
i follow the post, i’m sorry but i’m a noob and i want to learn!
The safest way is to upgrade to every version and follow the IMPORTANT NOTES of the changelog. After the each upgrade, restart peertube so it executes migrations.
Export and reimport SQL data won’t work.
Only the DB.
No sorry, you’ll have to run peertube
I have just setup a local clone of v1.0.0-beta with DB data restored from my prod installation.
I have (successefully !!) upgraded to 2.1 at once, and the DB migrationq have been applied smoothly (yeah) !
About the script to be run for 2.1 (migrations/peertube-2.1.js), should it be run from my running prod app (which is still not migrated), or can run it locally / offline on my local docker ?
What is supposed to be updated here ? data Files ? Db ?
Thanks for the clarification.
You’re supposed to run it from your prod server. It will generate torrents from HLS related files (fragmented mp4) and will update the DB.