Installing WordPress on a Mac over SSH, Part 2.

If you followed Installing WordPress on a Mac over SSH but for some reason you need to have 2 or more blogs hosted, this post is for you.

If something is not working as you’d expect take a look at Installing Multiple Blogs at the WordPress Codex for additional reference.

Using instructions from the first part go through steps 1 and 2 to get a new installation of wordpress. It may sound counterintuitive but that’s the way you do it, a new installation for every new blog.

Now instead of creating a new config file from the sample and editing it, you can copy an existing one. There’s a trick though, you have to edit the table prefix, so your new installation knows what tables in the database it needs to create and use.

cp ~/Sites/existing_blog/wp-config.php ~/Sites/new_blog/
vi ~/Sites/new_blog/wp-config.php

Once in the editor (use your editor of choice if you’re not familiar with vi), find $table_prefix and replace wp_ with something that your new blog will use. I replaced it with bd_ for a friend’s bopdigger | Thoughts on Improvisation and Music blog.

When you’re done with configuration go ahead with the step 4 to edit hosts file and virtual hosts for Apache. You won’t need step 5 as you already have the user and database set up. Last step is changing the DNS records and you’re done.

Leave a Reply

Your email address will not be published. Required fields are marked *

*

You may use these HTML tags and attributes: <a href="" title=""> <abbr title=""> <acronym title=""> <b> <blockquote cite=""> <cite> <code> <del datetime=""> <em> <i> <q cite=""> <strike> <strong>