AgileApps Support Wiki Pre Release

Difference between revisions of "User:Aeric/Upgrading the Wiki"

From AgileApps Support Wiki
imported>Aeric
imported>Aeric
Line 57: Line 57:
#Complete the following information:
#Complete the following information:
#*Contact name
#*Contact name
#*Wiki name. E.g: LongJump Support Wiki
#*Wiki name. E.g: Our Company Support Wiki
#*HTML folder name ($wgScriptPath)
#*HTML folder name ($wgScriptPath)
#*mySQL database name and Siteground password ($wgDBname)
#*mySQL database name and Siteground password ($wgDBname)

Revision as of 00:42, 29 June 2011

Notepad.png

Note: This process is for upgrading a wiki in place. The process hasn't been fully tested, as it turns out that to Create a New Branch it is necessary to install the wiki, so the paths are configured right internally. We tend to upgrade only when creating a new branch, so this process generally isn't needed. It has been retained in case it turns out to be useful at some future date.)

Do the Update

This upgrade process is based on the one recommended at the MediaWiki site.

  1. First, find out if an upgrade is needed. Check Special:Version to see what we have.
  2. Create a new directory to put the update into.
  3. If needed: Create a new database.
    (If you are doing the upgrade as part of creating a new branch, you have already created a new database, so you can skip this step.)
  4. Unzip the latest production version of MediaWiki.
    (Get the latest production version with a green checkmark next to it.)
  5. From the old directory:
    • Copy LocalSettings.php
    • Copy the extensions/ folder
    • Copy the skins/ folder
  6. In the release notes for the new version, see if any changes need to be made to LocalSettings.php.
    Note: It's possible that the upgrade script below does this. Maybe that's why it wasn't part of the procedure mentioned on the MediaWiki upgrade page. (Dunno)
  7. Enable read-only mode in LocalSettings.php of the old directory:
    • $wgReadOnly = 'Upgrading to MediaWiki {version}';
  8. Run the upgrade script in the new directory.
  9. Copy the images/ folder to the new directory.
  10. Swap the old directory and the new directory.

Learn more:

Test the update

Once the upgrade has been completed:

  1. Browse to the wiki and check that the following operations work as expected:
    • Viewing pages
    • Editing pages
    • Uploading a file
  2. In Special:Version, check that the version shown is correct and that the extensions are present.


Old Process Info

RENAMES:

  1. Rename these folders:
    • /extensions --> /extensions1
    • /skins --> /skins1
    • /images --> /images1
  2. Rename these folders:
    • /extensions1 --> /extensions
    • /skins1--> /skins
    • /images1 --> /images

PROCESS: Set Up the Wiki:

  1. From a browser, navigate to: http://lj.platformatyourservice.com/{new_wiki}/index.php
    Note: Going through the standard setup process ensures that any new default settings expected by the wiki are created.
  2. Complete the following information:
    • Contact name
    • Wiki name. E.g: Our Company Support Wiki
    • HTML folder name ($wgScriptPath)
    • mySQL database name and Siteground password ($wgDBname)
    • Wiki username and password ($wgDBuser/$wgDBpassword)

PROCESS:

  1. Rename the following files in the new wiki, to keep them from being overwritten by the new MediaWiki installation.
    • /LocalSettings.php --> /LocalSettings1.php
    • /extensions/ --> /extensions1
    • /skins --> /skins1
    • /images --> /images1
  2. Download MediaWiki installation files into the new local folder
    • Get latest files from
      • http://mediawiki.org
      • Download > Get MediaWiki (.tar.gz)
      • Pick latest production version that has a green checkmark (indicates it is stable)
    • Use 7-Zip to uncompress the files
      • Untar in a separate location
      • Verify the directory structure (It probably untars to mediawiki-{version}/)
      • Copy the contents to the local instance of the new wiki (ex: \wiki\lj72)
      • Delete the tar file
    • Use ftp/FileZilla to copy the MediaWiki files to a new folder on the hosting server. Ex: www/lj72
  3. From a browser, navigate to http://lj.platformatyourservice.com/{new_wiki}/index.php
  4. Click the [Setup MediaWiki] link
    • Name: LongJump Support Wiki v{n.M} (Ex: LongJump Support Wiki v7.2)
    • Contact email: eric@longjump.com
    • License info: No license metada
    • Password: <same>
    • Caching: On
    • User-to-user email: Off
    • Email notification for changes: On
    • Email authentication: On
    • Database:
      • Type: MySQL
      • Name: wiki___{new_version} Ex: wiki80
      • DB User: <same>
      • DB User PW: <same>
      • Old PW: <same>
      • Supervisor account: None
      • Database table prefix: {blank}
      • Storage engine: InnoDB
      • Database Char Set: mysql4 (install can't auto-convert to mysql5)
  5. Click [Install MediaWiki].
    The install finishes and gives you a page that echoes your settings.
  6. Go to /config.
    This folder has a LocalSettings.php file created by the install. (If you don't see it, refresh the view. If you still don't see it, it's already in the parent dir. Skip the next step.)
  7. Copy \config\LocalSettings.php to parent dir (lj72).

Final fixes:

  1. Modify LocalSettings.php:
    • OLD SITEGROUND STEP: __TBD: Use the newly generated value for $wgSecretKey??__
    • $wgEnableUploads = true;
    • $wgScriptPath = "/lj___{new_version}";
    • $wgDBname = "wiki___{new_version}";
    • Comment out Google analytics, so they're disabled.