Migration tips: Difference between revisions

From Fundamental Ramen
Jump to navigation Jump to search
No edit summary
No edit summary
Line 1: Line 1:
=== Update database by installer. ===
=== Update database by installer ===
# Backup old database.
# Backup old database.
# Install the latest LTS version.
# Install the latest LTS version.
Line 5: Line 5:
# Press continue to upgrade database by installer.
# Press continue to upgrade database by installer.


=== Update database by maintenance tool. ===
=== Update database by maintenance tool ===
# Backup old wiki.
# Backup old wiki.
# Install the latest LTS version.
# Install the latest LTS version.
Line 12: Line 12:
# Run '''php maintenance/update.php'''.
# Run '''php maintenance/update.php'''.


=== Trouble shooting. ===
=== Trouble shooting ===
If a new primary key or unique key was defined in new version.
If a new primary key or unique key was defined in new version.


Line 22: Line 22:
# Run '''php maintenance/update.php'''.
# Run '''php maintenance/update.php'''.
# Import data manually.
# Import data manually.
=== Using Docker ===

Revision as of 12:43, 19 February 2019

Update database by installer

  1. Backup old database.
  2. Install the latest LTS version.
  3. Apply original database settings.
  4. Press continue to upgrade database by installer.

Update database by maintenance tool

  1. Backup old wiki.
  2. Install the latest LTS version.
  3. Generate a new LocalSettings.php.
  4. Move SQLite file to the path of database.
  5. Run php maintenance/update.php.

Trouble shooting

If a new primary key or unique key was defined in new version.

The SQL command INSERT INTO ... SELECT ... might be failed.

At that time, the table cannot be migrate by updating tool.

  1. Export data of this table as SQL format.
  2. Run php maintenance/update.php.
  3. Import data manually.

Using Docker