travis johnson

Archive for February, 2007

February 25, 2007

Twitter

I’ve been hearing a lot about Twitter lately and finally decided to give it a try. I’m mostly interested in figuring out what makes it so popular. I am also interested in APIs, so I wrote a TextMate Bundle to post to my Twitter page.

If anyone else has a Twitter account, please be my friend :)



 

No Comments » Categories: Internet

February 25, 2007

Ducks Win!

Go Ducks

I went to the Ducks game tonight with Cam. It was the first time I had ever been to a game McArthur Court and it was great. We had tickets that were under the overhang of the 2nd deck which made listening and watching the game a little interesting, but we were pretty close and the Ducks won, so I can’t complain.

Cam and me



 

No Comments » Categories: Sports

February 24, 2007

Using mod_rewrite and FeedBurner

I decided I wanted to start using FeedBurner on my blog to see how many readers I actually have. One of the things I didn’t want to have to do, though, was to make both of my readers switch the URL of my feed, so I set up this simple mod_rewrite directive in my main .htaccess folder:

RewriteRule ^feed[/]?$ http://feeds.feedburner.com/Eightfivethree [L]

Now, any request for /feed will redirect to my feedburner feed.

Another benefit of setting up this rewrite, is that I can give out the URL to my domain, but get FeedBurner to gather the stats for me.

UPDATE: FeedBurner is taking hours to update my feed, not the 30 minutes they claim. I even tried pinging their service to update my feed without any luck. So, as easily as I put the RewriteRule in, I took it out. Now everyone is pointing back the RSS feed on my server and gets my posts as soon as I write them. No waiting, no hassle.



 

No Comments » Categories: Internet, Wordpress

February 23, 2007

Song of the Moment

Artist: The boss
Album: Greetings From Asbury Park
Song: Blinded By The Light

[mp3]http://www.eightfivethree.com/wp-content/blindedbythelight.mp3[/mp3]



 

2 Comments » Categories: Song of the Moment

February 23, 2007

Swap on

Rachel was interviewed for a podcast at Craftypod recently and it was released today. Go check it out and give it a listen. Diane really produces a quality podcast.



 

No Comments » Categories: General

February 22, 2007

Song of the Moment

Artist: Jeff Tweedy Song: Please Tell My Brother

[mp3]http://www.eightfivethree.com/wp-content/Please-Tell-My-Brother.mp3[/mp3]

This song is from the Sunken Treasure Live mp3 downloads, meaning that it was reordered up here in the Pacific Northwest (maybe even Eugene, but I am too lazy to look it up) a little over a year ago.



 

1 Comment » Categories: Song of the Moment

February 19, 2007

Another song of the moment

One for the Rose by Ryan Adams

[mp3]http://www.eightfivethree.com/wp-content/OneForTheRose.mp3[/mp3]

After thinking a little more about his 48 Hours demo, I decided I had to share another one of my favorites. I know it is a bit unprecedented to have two SotM’s on the same day, but just give this song a listen and I’m sure you will agree that it is worth it.



 

No Comments » Categories: Song of the Moment

February 19, 2007

Installing Wordpress and keeping it up to date

My buddy (Showtime) Shane promised he was going to install Wordpress and start a new blog this weekend. It’s now Monday morning with one day left in this President’s Day weekend and no blog yet. To help him out and anyone else that might be interested I am going to walk through the easiest way to install and then keep Wordpress up to date.

Before we begin installing Wordpress, you should setup your MySQL database. Your host should provide some way to create a database and then give you the database name, username, password and database host address. Keep this information handy, you’ll need it in a little bit.

Wordpress offers SVN access to it’s blog software and while the page claims to be for developers anyone can use the SVN server to get the code and keep their blog up to date. For this mini-tutorial I am going to describe, with little detail, how to install Wordpress using SVN. You will need to have access to the shell on your host, but most shared hosting servers nowadays provide SSH access. From your Windows computer you can install and use PuTTY to connect and from your Mac, just use the built-in Terminal app.

Once connected to your server, navigate to your web root directory for the domain you want to install the blog on. You will probably need to use a combination of ls and cd path/to/webroot to get to your webroot. You’ll probably see a file called index.html or something. You probably should delete it: rm index.html or move it: mv index.html index-save.html If you have made it this far, the hard times are now behind you.

The first thing to do when getting Wordpress from SVN is to figure out which version you want. I would always suggest the latest. To figure out which version are available from SVN:

svn list http://svn.automattic.com/wordpress/tags/

As of this writing, the 2.1 tag is the most recent which also happens the latest stable version. Getting this version from SVN would be exactly like downloading the .zip or .tar.gz and then uploading it to your server.

From inside your webroot, type the following command to get Wordpress 2.1:

svn co http://svn.automattic.com/wordpress/tags/2.1/

You then need to copy wp-config-sample.php to wp-config.php:

cp wp-config-sample.php wp-config.php

You now need to edit wp-config.php using vi, nano, pico or an FTP client to download the file to your local computer. Using the database connection info that you got at the beginning, fill out lines 3-6. On line 9 you can specify a prefix for your Wordpress tables. You don’t have to change this, ‘wp_’ is fine, but I generally like to change it to something that describes what the blog is going to be about, like ‘travis_’. The reason for this is because most shared hosts only allow you a limited number of databases and I usually put all my Wordpress blogs into the same database and just change the table prefix.

With wp-config.php all set up, save it back to the server and, in your web browser, go to the blog. Wordpress will say it needs to be setup, so click the links to proceed. It will give you a username and password to login to your new blog. And you’re all set.

The real reason for all the trouble of using the command line to install Wordpress isn’t because installation is much easier, it is because upgrading is incredibly easy. All you have to do is use svn list http://svn.automattic.com/wordpress/tags/ to get the newest tag and then switch to the new tag using (assuming 2.2 is the new tag):

svn switch http://svn.automattic.com/wordpress/tags/2.2

Then just go to http://your.domain/wp-admin/upgrade.php and click the upgrade link. That’s it, you’re updated to the newest version. If you don’t use SVN, you have to download the latest package, upload the certain files while not uploading others. It isn’t too hard, but using SVN is just too easy.

I realize this looks like a lot, but it really isn’t. The executive summary would looks something like this:

  1. svn co http://svn.automattic.com/wordpress/tags/2.1/
  2. Edit wp-config.php with your correct database connection details.


 

2 Comments » Categories: Wordpress

February 19, 2007

Song of the moment

Karina by Ryan Adams

[mp3]http://www.eightfivethree.com/wp-content/Karina.mp3[/mp3]

This song is off Ryan’s unreleased 48 Hours demo. The whole album is awesome, I would highly suggest finding it somehow (which can be tricky since it was never released, but let bittorrent is your friend).



 

No Comments » Categories: Song of the Moment

February 19, 2007

Swap-bot switched servers over the weekend

I spent most of Saturday moving Swap-bot to its new server. In the past, moving servers wasn’t too big a deal since I never really got any traffic. A day or two downtime wasn’t anything I worried about. But, the reason I had to even move in the first place was because Swap-bot has started to decent amount of traffic. On the old host, when Swap-bot would go down for a couple minutes I would hear about it from the users. With this move, a day or two downtime was not a real option. I luckily came up with something that resulted in about 2 minutes of downtime and it would have been shorter, but I took about a minute to track down a typo I made.

The reason coordination is even an issue is because changing a domain’s DNS records takes time to propagate throughout the internet. It isn’t instant and it doesn’t happen at the same time for all users. So at the exact same time one user could be browsing the new server and another could be browsing the old server because they are using different nameservers that have different information for my domain.

The first thing I had to do was setup the new server and test it. One mistake I made when setting up Swap-bot in the first place was setting up the SVN repository on the swap-bot.com domain. Once my DNS was changed, I would have no way of getting to the repository on the old server. So, the first thing I had to do was create a new repository on a different domain. The next step was to check out the swap-bot code and copy over all the user images from the old server. To copy everything over I chose to use rsync. rsync allowed me to copy everything over and then continually check for new images added throughout the day. Anything new that was added could easily be transfered over to the new server. Over the last year, we have accumulated nearly 1 GB of images, so copying the images over multiple times wasn’t something I really wanted to do. After transferring over a copy of the database to the new server, I added a record for the new server in my /etc/hosts file, telling my computer which IP address to use for swap-bot.com, instead of asking some other nameserver for it. This way, I could go in my browser to swap-bot.com and look at the new server. I found a few minor things that needed to be changed based on the way the new server is setup, but nothing major. It looked like everything was ready to go.

Then came the moment of truth. I was ready to make the switch. To do this, I setup my new mysql server to accept a remote connection from the old host. I then shut swap-bot down and transferred the database from the old server to the new one. Updated the database information on the old host and started swap-bot back up. At this point, swap-bot was now running on the old server, but pointing to the database on the new host. This way, I wouldn’t have to worry about any data syncing issues as DNS records changed at random throughout the next 24-48 hours. I gave a quick test of the old site and everything looked good, so I updated my DNS records to point to the new server.

It was actually a pretty uneventful move. I had a few people using AOL have a little trouble because, I think, they would get switched from one server to the other at random, but that was about it.



 

1 Comment » Categories: Internet, PHP, Programming

Next »

  • hack day

    hackday2008
  •  

  • mybloglog

  • facebook

  • linkedin

    View Travis Johnson's profile on LinkedIn
  • flickr

    www.flickr.com
    This is a Flickr badge showing public photos from travisjohnson. Make your own badge here.
  • RSS del.icio.us

  • Kansas City v0.01 | Wordpress