Schema upgrade downtime: Monday, 18 May, 2015 @ 17:00 UTC

Our next schema change version will be released on Monday, 18 May, 2015 around 10am PDT/1pm EDT/17:00 UTC/18:00 BST/19:00 CEST. We expect that MusicBrainz will be unavailable for 15 – 30 minutes during this time. We will put up the downtime notification on the site and tweet from @musicbrainz right before the release.

Since we’re total slackers, we still haven’t set up our backup database server since it suffered a hardware failure. This means that we won’t be able to put the site into read-only mode and will require us to do a full downtime. Hopefully for our next schema change we’ll have tackled our backlog of sysadmin duties and will have a backup DB server to make the release easier.

Sorry for any trouble this may cause you.

P.S. Look for another blog post on Sunday for details on where to get your access tokens for the Live Data Feed.

Service downtime to fix some database issues

This Friday we’re going to need to take a 15-20 minute downtime to fix a few leftover issues from our recent schema change. We tried to do this without downtime, but the service got progressively slower, so we’re electing to take some downtime.

We’ll be down shortly after Noon PST, 3PM EST, 20:00 UK, 21:00 CET for about 15-20 minutes.

Sorry for the hassles this causes.

Server upgrade and schema change, 2014-05-14

Hello again! This fortnight, as we’ve mentioned among the past few posts, is our twice-annual schema change release! This means that we’ve got some big changes, as well as special upgrade instructions.

In the former category, we’ve added support for two new entities: Series and Instruments, each of which is exactly what it sounds like. We’ve also done some various cleanup (tables missing from replication, making some attribute-style tables (e.g., label types) trees, and more properly orderable, removing unuseful sortnames). In non-schema-change fixes, we’ve fixed some merging for Artist Credits, show Area names after Places routinely, and perhaps most excitingly, added smaller versions of the relationship editor for other entities. It’s now possible to add relationships to any entity from most entity edit pages, expanding on our previous addition of URL editing!

As far as upgrading:

  1. Ensure you’ve replicated up to the most recent replication packet available with the old schema. (if you’re not sure, run ./admin/replication/LoadReplicationChanges and see what it tells you).
  2. Take down the web server running MusicBrainz, if you’re running a web server.
  3. Turn off cron jobs if you are automatically updating the database via cron jobs.
  4. Make sure your REPLICATION_TYPE setting is RT_SLAVE
  5. Switch to the new code with git fetch origin followed by git checkout v-2014-05-14-schema-change
  6. Run ./upgrade.sh (or carton exec -Ilib -- ./upgrade.sh if you’re using carton, with older installs).
  7. Set DB_SCHEMA_SEQUENCE to 20 in lib/DBDefs.pm
  8. Turn cron jobs back on, if needed.
  9. Restart the MusicBrainz web server, if applicable. It’s also recommended you restart memcached.

The git tag for this release, as mentioned above in the instructions, is v-2014-05-14-schema-change.

Full release notes, as usual:

Bug

  • [MBS-5978] – Replication feed is missing release_tag
  • [MBS-6709] – “None” is no longer the last Packaging type after adding Book and Cassette Case
  • [MBS-7482] – Artist merge with AC renaming does not merge identical ACs

Improvement

  • [MBS-2410] – Label types not a tree anymore
  • [MBS-2714] – Add support for Series.
  • [MBS-5897] – Make it possible to see edit JSON in the case of an ISE or poor data display
  • [MBS-6144] – Remove the apparently-unused script_language table
  • [MBS-6602] – Remove sortnames from areas
  • [MBS-6603] – Remove sortnames from labels
  • [MBS-6651] – Make it possible to disable dates for relationship types
  • [MBS-6886] – Display area after place names
  • [MBS-6887] – Model coordinates without nullable latitude and longitude
  • [MBS-7205] – Link types should track assumed cardinality
  • [MBS-7411] – Don’t require disambiguation comments for places from different areas
  • [MBS-7470] – Merging/combining RG types (primary/secondary) is unintuitive

New Feature

  • [MBS-3674] – Make instruments entities
  • [MBS-6234] – Add a relationship editor to artists, labels, recordings, release-groups, places, areas and works

Task

  • [MBS-7441] – Check non-replicated changes to DB that have happened since last schema change

Schema change release, 2011-07-11

Today we released our first schema change update since NGS. This change is quite a radical one, as it merges both of our databases (“READWRITE” and “RAWDATA”) into a single database. For most users of the database, this probably won’t affect you, but you’re encouraged to run the upgrade process anyway. Here’s what you need to do:

  1. Take down the web server running MusicBrainz, if you’re running a web server.
  2. Turn off cron jobs if you are automatically updating the database via cron jobs.
  3. Set DB_SCHEMA_SEQUENCE to 13 in lib/DBDefs.pm
  4. Make sure your REPLICATION_TYPE setting is RT_SLAVE
  5. Switch to the new code with git fetch origin followed by git checkout v-20110711-schema-change
  6. Run ./upgrade.sh from the top of the source directory.
  7. Install the perl modules Algorithm::Merge and Algorithm::Diff
  8. Turn cron jobs back on, if needed.
  9. Restart the MusicBrainz web server, if needed.

This process may take a while, as it has to dump one database into another, and download a few extra changes to ensure slaves aren’t missing any data. The RAWDATA database should no longer be in use and you should be able to drop it, but waiting to see that everything is working well might be a good idea.

This schema change does not introduce any new data. For everyone else, here’s a list of what got fixed since the last release!

Bug

  • [MBS-1977] – ModBot is unable to close some edits
  • [MBS-1979] – Unable to edit a “later translated versions” relationship with change direction
  • [MBS-2026] – Subscribed artists open edits won’t load for editors with large amounts of subscriptions
  • [MBS-2442] – MB postgres unaccent extension overwrites unaccent.so library shipped with postgres-contrib
  • [MBS-2689] – Timeline isn’t working in Opera 10
  • [MBS-2698] – Some tables are not replicated through Live data feed
  • [MBS-2812] – Adding track times has caused a failed dependency for an edit which changed the track titles.
  • [MBS-2826] – Web service returns malformed XML (not escaped properly)
  • [MBS-2831] – “Edit medium” edit display: Artist credits changes are incorrect
  • [MBS-2974] – I don’t receive e-mail when someone votes no to my edit any more
  • [MBS-2981] – Changing the case of recording comments should be auto-edits
  • [MBS-2986] – tracklist_index was not populated during NGS
  • [MBS-2995] – Caught exception in MusicBrainz::Server::Controller::WS::2::ReleaseGroup->release_group_browse “Can’t call method “format”

Improvement

  • [MBS-1500] – Remove tracklist_index.tracks
  • [MBS-1707] – Advanced tracklist in RE: “Title” to “Disc title”
  • [MBS-2242] – Disable editing of Medium title when there’s only one medium
  • [MBS-2434] – Combine READWRITE and RAWDATA
  • [MBS-2462] – Other edit types that don’t highlight what has changed between old and new values
  • [MBS-2583] – “Edit Medium” should show you which medium is being edited with respect to the overall release
  • [MBS-2767] – Release-group XML result should include first release date