Installing Movable Type on Tiger
Be The Content Manager
29 April 2005 Justin Williams Skip to comments
50 Comments
(
Closed)
One of the biggest phenomenons to hit the Internet in the past few years has been the personal weblog: blog for short. A blog is basically a Web site that allows its owner to post his thoughts, ideas and daily happenings. Some use it as a personal diary, some as a soapbox for their beliefs.Want to install Movable Type on Mac OS X Tiger? Justin Williams shows you how to get up and running with Movable Type using SQLite, the lightweight database engine included with every copy of Tiger.
Note: This article is written for installing Movable Type on “Tiger” (Mac OS X 10.4.x). The Panther and older OS X versions of this article, have been relocated to their own seperate, permanent pages.
Many people host a weblog on a third-party web server hosted by someone else, but with MacOS X, we have the tools we need to set up a fully functional weblog on our system. This blog could be served to the entire world via the Internet, or just used as a personal diary on your own system. It doesn't matter. Weblogs are what you make of them. There are several systems we could use to set up a weblog on our Mac, but for this article I have chosen Movable Type from Six Apart. I chose this solely because I have the most experience with it, as I have used it for almost four years on my personal Web site. Movable Type is designed using a Perl backend. Perl is an interpreted programming language that is capable of doing almost anything you wish. Tiger ships with Perl 5.8.6, which is more than enough for this process. The backend of our weblog will use SQLite. SQLite is the database system that is bundled with Mac OS X Tiger and powers the Core Data framework. Several major Mac applications use SQLite as well. A few examples are Freshly Squeezed Software's PulpFiction and Michael Tsai's SpamSieve. This article will assume that you are running a fresh install of MacOS X 10.4 or later and have the MacOS X Developer Tools installed. You should also be comfortable working in the command line and editing system configuration files. If this scares you, you may want to sign up for a service such as Six Apart's TypePad. Let's get started... ### Downloads First let's download all of the files you are going to need to complete this exercise. We are only going to need DBI, DBD::SQLite and Movable Type 3.16. DBD::SQLite is a Perl module that will interface between SQLite and Movable Type. DBI stands for Database Interface and was written by Tim Bunce. The DBI module then speaks to the DBD module. The DBD module we will be using is DBD::SQLite. The biggest advantage of DBI is that you can talk to the database without having to talk on the network to the actual database server or dealing with the server's libraries. Movable Type is simply a collection of Perl scripts that run the entire weblog system. * Movable Type * DBI * DBD::SQLite ### Apache In terminal, we need to edit our Apache config file. We are basically going to allow for cgi scripts to be executed on the Mac. By default CGI Scripts are located in /Library/WebServer/CGI-Executables/. We need to uncomment the line in the httpd.conf file that reads # AddHandler cgi-script .cgi I am going to explain how to do it using the vi text editor, but you are more than welcome to use your favorite editor of choice. :)
sudo vi /etc/httpd/httpd.conf
Go down to the line we want to edit and remove the # in front of _AddHandler_ by pressing the x key. Next type in _:wq_ to write and quit vi. Next, type the following into the Terminal window:
sudo apachectl graceful
The last command simply restarts the apache server without having to restart your system. Oh, the power of Unix.
### Connecting to SQLite
Before we can establish a connection between Movable Type and SQLite, we need to install the Perl modules we downloaded earlier. Double-click on each file to extract the folders that live inside. We need to compile these modules so that our database will show up when we test Movable Type. It's a relatively simple process. Type the following commands in the Terminal:
cd ~/Desktop/DBI-1.48
perl Makefile.PL
make
sudo make install
Now we need to install the SQLite module.
cd ~/Desktop/DBD-SQLite-1.08
perl Makefile.PL
make
sudo make install
Now that we have our perl modules set up, we can celebrate. We are finally ready to set up Movable Type!
### Movable Type
cd ~/Desktop/MT-3.16-full-en_US/
vi mt.cfg
Place a # before DataSource ./db
Set your CGIPath to equal _http://localhost/cgi-bin/_
Add the following lines to your file.
ObjectDriver DBI::sqlite
Database /Library/WebServer/CGI-Executables/db/mtdbmovabletype.sql
Set StaticWebPath to _/mt-static/_
Remove the # before _NoTempFiles 1_
:wq
Ok, that is a lot of steps, so let's go through what each one of them is. mt.cfg is the configuration file that gives basic information for the perl backend about your weblog. We set the CGIPath to equal where we are putting the cgi files. On your local system, it is /Library/WebServer/CGI-Executables/. StaticWebPath is where Movable Type's images, docs, and other similar files will be stored. We set that to http://localhost/mt-static/ so that the directories are housed in /Library/WebServer/Documents/mt-static/.
It should be noted that if you are going to set up your blog to be available for people on the Internet, you should replace all instances of localhost with your external IP address or domain name.
The next set of commands is basically telling Movable Type to use the SQLite database. Now you see why we had to set up the DBI and DBD stuff earlier.
We turned off NoTempFiles because Tiger was having issues when trying to build the index files. If anyone can find a solution to the problem, please post it in the comments.
Let's jump to the Finder. Yes, I am serious. After all of the love we have been giving the command line we are going back to the good old graphical filesystem. We need to install the Movable Type application onto our Webserver. First, lets copy the static files to the /Library/WebServer/Documents/mt-static/ folder. Make sure to copy the following files to that directory.
- styles.css
- mt.js
- images
- docs
- index.html
Now, let's move back a level and enter the CGI-Executables folder. Copy the following files into it.
- examples
- extlib
- lib
- mt-add-notify.cgi
- mt-atom.cgi
- mt-check.cgi
- mt-comments.cgi
- mt-db-pass.cgi
- mt-load.cgi
- mt-search.cgi
- mt-send-entry.cgi
- mt-set-reg.cgi
- mt-tb.cgi
- mt-view.cgi
- mt-testbg.cgi
- mt-xmlrpc.cgi
- mt.cfg
- mt.cgi
- php
- plugins
- schemas
- search_templates
- tmpl
- tools
Now that we have the weblog configured, let's go through some basic configuration. The link above is where you will do all of your blogging. It houses the configuration, templates and a basic editor.
You will be greeted with a login prompt. The mt-load.cgi script created a default user name Melody and a password of Nelson. The first thing you are going to want to do is change that username and password. To accomplish this, just head to the Edit Your Profile link. Change the username and password to something you can easily remember.
Next, let's edit the default weblog to fit your specifications. The default is creatively named Weblog, but you may want to change that to something to describe you. I have my personal one as just my name, but others have been far more creative. :)Next, go to the Weblog Config button and let's double check some values.
- Local Site Path: /Library/WebServer/Documents
- Site URL: http://localhost/
- Local Archive Path: /Library/WebServer/Documents/archives
- Archive URL: http://localhost/archives/
Justin Williams is founder and chief author for MacZealots. He switched to the Mac almost five years ago hasn't looked back since. When not blogging or coding, you can find him watching copious amounts of TV. Justin can be reached at



Reader Comments (50)
DISCLAIMER: The views expressed below are those of their authors and not necessarily endorsed or supported by MacZealots.com. In all cases, the comments provided here are offered as a courtesy and will be moderated. Any content deemed off-topic or offensive will be removed without notice. Posting a comment here boils down to two things: 1.) Think before you type 2.) Respect the thoughts of others. See our commenting guidelines and/or privacy policy for more information.
#1) On May 2, 2005 4:54 PM
Hey guys, great work on the new site!
Regarding Movable Type on the Mac, I’m a bit unsure of how I could use this tutorial on a non-server Mac. Do you have any specific examples of uses for a local installation of Movable Type, especially uses that wouldn’t be just as well served by much simpler applications?
I have used MT on my website in the past and liked it, but I wondered if you guys had some insight on good ways to use it on my personal machine.
#2) On May 2, 2005 6:28 PM
Think development.
If you are working on a client site that is built on Movable Type technologies, it’s going to be a lot easier to have a local installation of MT that doesn’t require a net connection and is more responsive.
#3) On May 4, 2005 11:52 PM
It’s also handy if you’re more used to keeping a blog than any other form of note taking. I have a blog setup on the Mac to record work done for clients which I woulnd’t really want to have online. I could use some other system but since I blog all the time anyway…
Thanks for the guide, btw.
#4) On May 8, 2005 11:07 AM
Using a blog locally (especially MovableType) makes for a great way to take notes when you’re at College and then just copy the pages up to your hosted domain for your classmates.
It’s also a good way to run Movable Type locally to test out your new blog’s, etc. before making it available to the real world. I’ve not used TypeMover, but have heard it’s an excellent plug-in for moving your entire configuration from one server to another (ie, your local Mac development version to your fully-hosted Production version).
Anyone know how easy it is to change this setup to MySQL, or if any of the MySQL flavors have been tested under Tiger?
This is a phenomenal guide!
- Jim
#5) On May 8, 2005 6:14 PM
I’ve followed your tutorial word for word and have almost got my blog working. When I go to http://localhost/ I have a blank weblog with the title that I set for it. The only problem is I can’t seem to add new posts to the blog. When I go to Movable Type > Entries it shows my post’s but they do not appear in my blog. I rebuild the site when I add a new entry and still no joy.
I’ve been through this tutorial twice now and I am sure I haven’t missed anything.
I would be really gratefull for any help.
Thanks Jason
#6) On May 8, 2005 6:25 PM
Sorry ignore my first post.
I had the post status set to draft instead of publish.
DOH!!
This is an excellent tutorial site. Bookmarked. Keep up the great work!
#7) On May 9, 2005 1:23 PM
I’m having some trouble setting up MT.
Ikeep getting teh following error:
Writing to ‘/Library/WebServer/Documents/index.html’ failed: Opening local file ‘/Library/WebServer/Documents/index.html’ failed: Permission denied
I’ve followed all teh permissions as per the tutorial, but I’m still getting this permissions error
ack
any advice?
Thanks much
#8) On May 9, 2005 1:40 PM
Nevermind.
I had a stry index.html file from previous attempts at creating a website.
all is good
#9) On May 10, 2005 11:56 AM
justin,
Do you have plans to append any instructions on how to configure a local copy of MT to a MySQL database instead of SQLite? You make an excellent point that it’s handy to have a local installation of a client site on our Macs, but every MT publishing system I’ve setup uses MySQL.
Thanks for the great tutorial.
#10) On May 10, 2005 12:33 PM
No. I am not going to append it. The old Panther article can be adapted to Tiger if need be.
#11) On May 13, 2005 7:13 PM
I have installed Movable Type on Mac OS X Tiger following this tutorial and I have enabled suEXEC on Apache as suggested. I used Daniel Bates page as a guide. Thanks Justin your help is appreciated.
Since I now have suEXEC enabled can the executable cgi scripts be installed in the same folder as the mt-static folder?
Also if I wanted to install Movable Type on my ~user Sites folder can use the same /Library/WebServer/CGI-Executables/ folder for the cgi scripts?
The Daniel Bates Page link is here: http://research.intudata.com/articles/IR-071004/suexec.php.
#12) On May 18, 2005 5:31 PM
cd ~/Desktop/DBI-1.48
perl Makefile.PL
make
sudo make install
All goes well until I hit make which gives me an error “command not available”, very frustrating. Are you sure this works?
Isn’t it possible to install this without all this terminal (no pun intended) geekery?
#13) On May 19, 2005 11:17 PM
I’m trying to get SQLite up and running but when i enter the make command i get this: make: *** No rule to make target `/System/Library/Perl/5.8.6/darwin-thread-multi-2level/CORE/config.h’, needed by `Makefile’. Stop.
any suggestions?
#14) On May 28, 2005 8:20 PM
Justin:
I’m getting the following error when running the mt-load.cgi script:
Loading initial data into system…
An error occurred while loading data:
/Library/WebServer/CGI-Executables/mt.cfg:60: variable ‘CTYPE’ not defined
The mt-check script reports success.
Any ideas? Waddid I miss?
Stephen
#15) On May 29, 2005 10:15 AM
Oops. Should have examined my website’s mt.cfg file first.
Never cut and past stuff at 3 in the morning. You never know what you’ll add to a file.
I had managed to paste an entire web template into the cfg file.
Stephen
#16) On May 29, 2005 10:20 AM
BTW, thanks for your great instructions. I modified them only to use MySQL and phpMyAdmin.
Your tutorial is a model of clarity.
Stephen
#17) On June 3, 2005 9:07 PM
An exceptionally clear walkthrough, thank you very much. I’ve recently had to install MT on my Powerbook for some testing for a project (I’m a wordpress man myself though…heh) and before I found your article I was having immense amounts of trouble.
Cheers!
#18) On June 14, 2005 4:13 AM
The Movable Type link has an additional “space”, you should remove that to make the link work
#19) On June 30, 2005 10:04 PM
Hi,
I wanted to know if there is a “install Movable type for dummies” out there. I downloaded all of the necessary items listed, but I open up the terminal and I’m stuck. Am I supposed to put all the CGI files in the MT folder in the CGI folder of the webserver? After that, I open up the terminal and then what? If someone can help me out, that would be great. I’ve been trying to piece together about 3 different tutorials on installation. My main problem is using the terminal- I’ve never used it before. It seems simple, but I was dealt the “slow” gene at birth.
Running Mac 10.4
Powerbook
Thanks.
#20) On July 1, 2005 6:32 PM
Hey,
I’m trying to install MT on my powerbook just for mucking around purposes and everything went fine, however after I loaded up “http://localhost/cgi-bin/mt.cgi” in Firefox/Safari/Camino, my screen doesn’t look like yours with the images and css.
All I get is plain text as an interface (not really flattering). Where did I go wrong in the steps?
Thanks for your help.
Cheers.
#21) On July 4, 2005 11:40 PM
Can someone help me out with this?
When I do the http://localhost/cgi-bin/mt-check.cgi,
I get a message that my DBD::SQLite is not installed. My DBI is installed.
So I go back and see what I did wrong, and I think I知 missing something here. Am I using the wrong editor? If I use the vi editor, what are the commands I need to EXACTLY type?
And what about the warning line? I saw nothing in the tutorial about that.
Please, if someone can help, it would be great. I’ve been fiddling around with this for quite sometime. Thanks.
[Stephen-deSouzas-Computer:~] stephend% cd ~/Desktop/DBD-SqLite-1.08
[Stephen-deSouzas-Computer:~/Desktop/DBD-SqLite-1.08] stephend% perl Makefile.PL
Warning: prerequisite DBI 1.21 not found.
Writing Makefile for DBD::SQLite
[Stephen-deSouzas-Computer:~/Desktop/DBD-SqLite-1.08] stephend% make
tcsh: make: Command not found.
[Stephen-deSouzas-Computer:~/Desktop/DBD-SqLite-1.08] stephend% sudo make install
Password:
sudo: make: command not found
[Stephen-deSouzas-Computer:~/Desktop/DBD-SqLite-1.08] stephend%
#22) On July 6, 2005 2:36 PM
Great tutorial! I really enjoyed setting up movable type, but have now come to the conclusion that it’s really not for me, I’ve opted for a simple flat php blog instead. Can anyone tell me how to remove movable type from my system easily?
#23) On July 8, 2005 3:54 AM
I’m also having problems with this tutorial. Much like others have described, I get the “-bash: make: command not found” or “sudo: make: command not found” messages when I get to the “make” and “sudo make install” commands of the tutorial. Everything else seems to have run fine but obviously Movabletype will not run without these database modules installed.
Is there something I need to preface to get Makefile.PL to listen to my “make” and “sudo make install” commands? I’m not able to figure out what I’m missing that my install would fail when others’ have not.
#24) On July 10, 2005 7:47 PM
To those with the “make” command problems, I’ve discovered what the problem is. The Xtools from the original Tiger CD needs to be installed. If this was somewhere in this tutorial I must have missed it (as did the others who commented here), you may consider adding this to your list of the things needed to complete the tutorial.
#25) On July 14, 2005 9:14 PM
this tutorial is just great! I’ve just switch to mac for about 16 days..I have a very little knowledge in UNIX terminal and this tutorial really help me install MT locally, making my development much faster..keep up the good work :)
#26) On July 28, 2005 6:43 PM
This tutorial has been by far the best mt installation help for Tiger I’ve seen. Everything has gone like clockwork, except for one problem. On clicking the http://localhost/ link, all I get is the Apache page. Any idea why this might be happening? Everything else is fine, and I’ve been able to post articles and save them on the http://localhost/cgi-bin/mt.cgi page, though….
#27) On July 28, 2005 7:14 PM
Ignore my first post - false alarm. Once again, marvelous job done!
#28) On August 7, 2005 11:17 AM
With regards to what somebody mentioned earlier about when loading up 塗ttp://localhost/cgi-bin/mt.cgi� in Firefox/Safari/Camino, my screen doesn稚 look like yours with the images and css.
All I get is plain text as an interface. I read through the MovableType install guide and i think its just a case of uncommenting a few lines in the mt.cfg file and u should get al the styling as showin in this tutorial.
http://www.sixapart.com/movabletype/docs/mtinstall#installation%20directories
hope this helps.
Ben, UK
#29) On August 7, 2005 1:48 PM
Thanks, this Article helped ALOT. Seriously, it was way different than Wordpress. It all worked out but I got the same thing with the Images and CSS not showing but uncommented the staticweb path and all works well!
Nice Article.
#30) On August 9, 2005 4:45 PM
Hi, ive successfully installed MT on my Powerbook, Been bloggin since 7th Aug. Its installed locally but I want to upload it to my url. How is this possible, do I need to go through the above process again and rebuild my site from scratch. Or can I just upload my site as it is??
Help.
#31) On August 9, 2005 11:17 PM
I have gone awry somewhere. Here is the error message I get when I try to rebuild my site:
Writing to ‘http:/www.mydomainname.com/Library/WebServer/Documents/index.html’ failed: Opening local file ‘http:/www. mydomainname.com/Library/WebServer/Documents/index.html’ failed: No such file or directory
But it IS there. Or at least there is a file called “index.html” that is there. It is the one that says: “You cannot change the contents of this directory….”
My directory structure looks like this: (abridged)
/Library
/Webserver
/CGI-Executables
/db
/extlib
/lib
— all the mt* stuff
/Documents
/archives
/mt-static
- index.html, mt.js, styles.css, and an images folder
/index.html (yes, I have one in Documents and one in mt-static :(
I have done my best a couple of times. Could someone point out the folly of my ways!
Thanks,
Michael
#32) On August 22, 2005 12:06 PM
followed the directions closely but came up with this error when i ran http://localhost/cgi-bin/mt-load.cgi:
Movable Type System Setup
Loading initial data into system…
An error occurred while loading data:
Unsupported driver MT::ObjectDriver::DBI::sqlite: Can’t locate DBI.pm in @INC (@INC contains: /Library/WebServer/CGI-Executables/extlib /Library/WebServer/CGI-Executables/lib /System/Library/Perl/5.8.6/darwin-thread-multi-2level /System/Library/Perl/5.8.6 /Library/Perl/5.8.6/darwin-thread-multi-2level /Library/Perl/5.8.6 /Library/Perl /Network/Library/Perl/5.8.6/darwin-thread-multi-2level /Network/Library/Perl/5.8.6 /Network/Library/Perl /System/Library/Perl/Extras/5.8.6/darwin-thread-multi-2level /System/Library/Perl/Extras/5.8.6 /Library/Perl/5.8.1 .) at /Library/WebServer/CGI-Executables/lib/MT/ObjectDriver/DBI/sqlite.pm line 11. BEGIN failed—compilation aborted at /Library/WebServer/CGI-Executables/lib/MT/ObjectDriver/DBI/sqlite.pm line 11. Compilation failed in require at (eval 4) line 1. BEGIN failed—compilation aborted at (eval 4) line 1.
how can i fix this? tried to find info about it online but i’m not familiar with unix commands or databases. thank you!
#33) On August 28, 2005 6:13 PM
Has anybody tried this with MT 3.2 yet?
any reason it wouldn’t work?
#34) On August 31, 2005 12:24 PM
Hi @ all,
I tryed it with MT 3.2.x and it fails by check and load, because, there are no such files. I’ve also problemes to login with the standard user.
Can anybody help me? Thanks Kay-Uwe
#35) On September 4, 2005 10:13 AM
Hello!
Yeah I agree with previous poster. But anyway it giving me some ideas to think. Looks like I have some idea of how to use it. Will post more later.
Thanks.
#36) On September 6, 2005 1:58 AM
It would be nice to know how to install MT on XAMPP. thats what most of use use. We don’t use the default Apache in Tiger.
#37) On September 6, 2005 2:35 AM
I’m getting a Make error
make: *** No rule to make target `/System/Library/Perl/5.8.6/darwin-thread-multi-2level/CORE/config.h’, needed by `Makefile’. Stop.
#38) On September 9, 2005 11:39 AM
I’m getting the same error as MySchizoBuddy and Carl. I have the latest xcode and the BSD SDK updated.
Thanks
#39) On September 24, 2005 9:00 AM
to this point: cd ~/Desktop/MT-3.16-full-en_US/
vi mt.cfg it says to me:
syntax error near unexpected token `newline’
you can help me?
p.s.: I install MT-3.2-en_US, sorry for my english
#40) On September 25, 2005 1:01 PM
All is well after installation and I can post news and rebuild, however, when i go to http://localhost/ the apache page comes up. Can someone mend this problem?
#41) On September 26, 2005 1:37 AM
Hello,
I get an error after I try to publish my first post
Error making path ‘/Library/WebServer/CGI-Executables/2005/09’: mkdir /Library/WebServer/CGI-Executables/2005: Permission denied at lib/MT/FileMgr/Local.pm line 105
And I also see only the Apache page. Overall a great tutorial, however a simpler approach would be better for me.
#42) On September 26, 2005 12:09 PM
Why, why, why do i not understand…. It. Was. Supposed. To. Be. So. Easy!!!
But its not!
#43) On October 5, 2005 5:00 PM
Am I going crazy or is there no mt.cfg when you untar MT-3.2-en_US ???? There is a mt.cgi…but no MT.cfg.
HELP!
#44) On October 5, 2005 5:08 PM
Found my answer here:
http://www.movabletype.org/support/index.php?act=ST&f=7&t=54837&s=77647069495c2465cf01e3476ddda096
#45) On October 10, 2005 7:29 PM
I couldn’t get DBI/SQLite to work either, so just defaulted to DB and 3.2 works great. I had MySQL working localhost on another machine, but I’m just using this for demo, so less work is better.
#46) On October 24, 2005 10:02 PM
Can you guide us on how to use terminal/apache? How do I edit the apache config file? I’m a new user to mac and wish the was more steps in your tutoral. I currently use MovableType in my website, but I set it up in 2003 and was using a PC. I now want to add a blog to my .Mac account. I will try to figure it all out but I’m always looking for someone that has already gone though all the hassle and is nice enough to share how to set it all up. Thanks!
#47) On November 3, 2005 11:45 PM
It worked for me! And took me only one help ticket to the MT support desk …
The only snag I encountered was related to mt.cfg file. If you have read some of the linked articles about the MT 3.2 upgrade you may already know this BUT do NOT look for mt.cfg in your MT 3.2 install because it isn’t there! (Nor is mt-load.cgi.) Instead look for mt-config.cgi-original. Save a copy as mt-config.cgi and then edit that file with the changes that are made above to mt.cfg.
#48) On December 7, 2005 6:04 PM
I’ve been trying to set up MT 3.2 myself in its own directory. (/Library/WebServer/Documents/weblog/).
Everything seems to work perfectly, except when I direct Safari to http://mydomain.net/weblog/ I get a “requested url not on this server” page. If I open the index.html page generated by MT that resides in this weblog folder, I see the lovely MT page.
All other folders in /L/WS/Documents/ are accessible. Any hints? Merci.
#49) On March 18, 2006 3:10 PM
some one going crazy or is there no mt.cfg when you untar MT-3.2-en_US ???? There is a mt.cgi�but no MT.cfg.
#50) On March 30, 2006 1:20 AM
To install DBI and DBD::SQLite just do cpan DBI DBD::SQLitecpan DBI DBD::SQLite</code