mtupgrade - Upgrading Movable Type
This document describes the process of upgrading to a newer version of Movable Type.
If you have already installed a previous version of Movable Type (1.0-2.21) you do not need to perform a complete installation. If you have not yet installed Movable Type, see the installation instructions.
With any upgrade, it is a good idea to export the entries and comments from each of your blogs before doing the upgrade. In the case that something goes wrong while upgrading, you will then have your entries and comments in importable form.
Download the upgrade distribution file (rather than the full distribution). Unpack the .tar.gz archive that you downloaded.
Make sure that you upload all of the files in ASCII mode, except for the images, which should be uploaded in binary.
When you are uploading the files in the extlib directory, be careful not to overwrite any libraries that you installed there when you first installed Movable Type.
NOTE: if you have made changes to any of the files that you are replacing, you will need to mark the files that have changed, and make the same changes to the new versions. This only applies if the changes you made have not been incorporated into the new Movable Type release in some form, of course. If you are unsure whether you need to redo a change you have made to one of the Movable Type files, ask your question on the Support Forum (http://www.movabletype.org/support/).
NOTE: if your MT application is stored in your cgi-bin, and thus if your images, documentation, and stylesheet are stored outside of the cgi-bin, be sure to upload images, docs, and styles.css to the correct location.
This means that the owner should have read, write, and execute permissions, and that group and other should have read and execute permissions (but not write permissions).
Open your web browser and point it at the URL for mt-upgrade25.cgi on your site. For example, if your site is http://www.your-site.com/, and you uploaded the Movable Type files into the /mt directory, you'd type http://www.your-site.com/mt/mt-upgrade25.cgi.
If successful, mt-upgrade25.cgi will report its success. If unsuccessful, it will report the error that occurred.
Open your web browser and point it at the URL for mt-upgrade21.cgi on your site. For example, if your site is http://www.your-site.com/, and you uploaded the Movable Type files into the /mt directory, you'd type http://www.your-site.com/mt/mt-upgrade21.cgi.
If successful, mt-upgrade21.cgi will report its success. If unsuccessful, it will report the error that occurred.
Open your web browser and point it at the URL for mt-upgrade.cgi on your site. For example, if your site is http://www.your-site.com/, and you uploaded the Movable Type files into the /mt directory, you'd type http://www.your-site.com/mt/mt-upgrade.cgi.
If successful, mt-upgrade.cgi will report its success. If unsuccessful, it will report the error that occurred.
For security reasons, you should remove the following files from your FTP server after your upgrade is complete:
Movable Type is now upgraded, and you can start using the new version.
As of version 1.3, you can now control line and paragraph breaks separately
for comments and entries; in other words, you can set
Convert breaks for
comments, but not for entries, if you would like. NOTE that if you wish to
convert line and paragraph breaks in comments in version 1.3, you need to edit
the configuration for each of your blogs, and check the
Convert line and
paragraph breaks in comments box.
As of version 1.4, Movable Type requires at least version
0.8 of the
File::Spec Perl module. If you do not have at least version
0.8, you will
get this error after upgrading:
Can't locate object method "splitpath" via package "File::Spec" at lib/MT.pm line 209.
If you are not certain whether your server has a sufficiently new version of File::Spec, you should run mt-check.cgi again (see CHECKING FOR REQUIRED AND OPTIONAL MODULES, below); if your server needs a newer version of File::Spec, follow the instructions here.
As of version 2.2, Movable Type supports using MySQL for data storage. Note that this is only an option--the Berkeley DB data storage is still supported. If you are not interested in using MySQL, or if you do not have the ability to use MySQL on your server, skip this section.
If you have already converted your version of Movable Type to use the MySQL support, skip this section.
To determine whether your server supports MySQL and the Perl libraries needed to connect to it, run mt-check.cgi and look at the status for the module DBD::mysql. If it is installed, your server will support the MySQL version of Movable Type. If it is not installed, you will need to contact your host if you wish to use MySQL.
If you are interested in converting, a conversion script to copy your data from the Berkeley DB files into MySQL is included in the upgrade distribution (mt-db2mysql.cgi). To convert your existing MT installation to using MySQL, follow these steps:
ObjectDriver DBI::mysql Database database_name DBUser database_user
where database_name is the name of the MySQL database where you wish to store your data, and database_user is the username used to connect to that database. If your MySQL server is on a different host, you can use DBHost to specify the hostname:
Note: the database that you specify must already exist--Movable Type cannot create it automatically!
Open mt-db-pass.cgi in a text editor. On this line:
Replace database_password with the password used to connect to your MySQL database.
mt-db2mysql.cgi is a Perl script that will create the necessary schema in your MySQL database, then populate the database with the data from your Berkeley DB files.
Done copying data from Berkeley DB to MySQL! All went well.
If you received this message, you're done. When you log in to Movable Type and use the system, you will now be using the MySQL version of the system.
If an error occurred, the message
An error occurred while loading data:
will be displayed, along with the actual error message. If an error occurred, edit your mt.cfg file and remove the following line:
Now you will be back to using the Berkeley DB version of Movable Type. Post the error message that you received on the Support Forums.