mirror of
https://github.com/plan-player-analytics/Plan.git
synced 2024-11-21 18:15:25 +01:00
Page:
Preparation for update with database schema changes
Pages
4.0.0 Set Up after 3.6.4
APIv4
APIv5 DataExtension API
APIv5 DataExtension API by Example
APIv5 PageExtension API
APIv5 Query API
APIv5
Architectural Decision Records
Bukkit Configuration
Bukkit Set Up
Bungee Configuration
Bungee Set Up
Commands & Permissions
Contribution Guidelines
DataExtension API Getting started
DataExtension API Builders
Database Schema
Database management
External WebServer Use
External Webserver use: Reverse proxy
Get Started
Home
How to configure X
How to update supported fabric version for curseforge release pipeline
How to update the plugin
Html Customization migration guide to React
Html Customization
Localization
Migration guide from Version 4.x.x to Version 5.0
Migration guide from Version 5.5 to 5.6
Migration guide to Version 5.1 build 768
PlaceholderAPI
Possible GDPR Privacy Policy section
Preparation for update with database schema changes
Project Architecture
Project Setup
Query API Getting started
SSL Certificate (HTTPS) Set Up
Supported Plugins
Themes
Web permissions
5
Preparation for update with database schema changes
Aurora Lahtela edited this page 2022-10-30 11:32:00 +02:00
Preparation for update with database schema changes
If an update has backwards incompatible database schema changes it is mentioned in the change log.
- Backup your database
- Stop all servers
- Update all servers
- Start one server with Plan and wait until Patching has completed (
"All database patches applied successfully."
) - Start rest of the servers
If you need a rough estimate how long patching will take, you can run query SELECT COUNT(*) as row_count FROM <table name mentioned in change log>
and estimate.
Patching the database usually takes ~1 second per 20000 rows of data.
How to Backup your database
SQLite
- Stop your server
- Go to Plan plugin directory
- Make sure that
database.db-shm
anddatabase.db-wal
files are not present- If they are the server didn't shut down properly, restart the server and stop it.
- Copy
database.db
to your backup folder
How to restore if something goes wrong
- Stop your server
- Go to Plan plugin directory
- Make sure that
database.db-shm
anddatabase.db-wal
files are not present- If they are the server didn't shut down properly, restart the server and stop it.
- Copy
database.db
to your Plan folder from your backup folder
MySQL
- https://dev.mysql.com/doc/refman/8.0/en/mysqldump.html
mysqldump {login options} {plan database name} > backup-plan-dump.sql
- Copy the dump file to your backup folder
How to restore if something goes wrong
- Login to mysql
mysql> drop database {broken plan database};
mysql> source /path/to/backup-plan-dump.sql
Documentation
Tutorials
Configuration
- Game server Set-up
- Network Set-up
- Game server Configuration
- Network Configuration
- Login / HTTPS Set-Up
- Commands & Permissions
- Database management
- PlaceholderAPI