<?xml version="1.0" encoding="UTF-8"?>
<rss version="2.0"
	xmlns:content="http://purl.org/rss/1.0/modules/content/"
	xmlns:wfw="http://wellformedweb.org/CommentAPI/"
	xmlns:dc="http://purl.org/dc/elements/1.1/"
	xmlns:atom="http://www.w3.org/2005/Atom"
	xmlns:sy="http://purl.org/rss/1.0/modules/syndication/"
	xmlns:slash="http://purl.org/rss/1.0/modules/slash/"
	>

<channel>
	<title>A Noted Path by Theodore Nguyen-Cao &#187; wordpress</title>
	<atom:link href="http://www.theodorenguyen-cao.com/tag/wordpress/feed/" rel="self" type="application/rss+xml" />
	<link>http://www.theodorenguyen-cao.com</link>
	<description>Personal blog of Theodore Nguyen-Cao</description>
	<lastBuildDate>Wed, 21 Jul 2010 15:40:42 +0000</lastBuildDate>
	<language>en</language>
	<sy:updatePeriod>hourly</sy:updatePeriod>
	<sy:updateFrequency>1</sy:updateFrequency>
	<generator>http://wordpress.org/?v=abc</generator>
		<item>
		<title>Moving wordpress to another host</title>
		<link>http://www.theodorenguyen-cao.com/2009/01/21/moving-wordpress-to-another-host/</link>
		<comments>http://www.theodorenguyen-cao.com/2009/01/21/moving-wordpress-to-another-host/#comments</comments>
		<pubDate>Thu, 22 Jan 2009 04:57:35 +0000</pubDate>
		<dc:creator>Theo</dc:creator>
				<category><![CDATA[geekery]]></category>
		<category><![CDATA[apache]]></category>
		<category><![CDATA[wordpress]]></category>

		<guid isPermaLink="false">http://www.theodorenguyen-cao.com/?p=196</guid>
		<description><![CDATA[If you&#8217;ve been following my blog for awhile, you might have noticed I moved this blog from blog.notedpath.com to theodorenguyen-cao.com as it was more fitting domain. I originally just registered the domain, added the DNS record, and updated my apache config to have theodorenguyen-cao.com to be an server alias to blog.notedpath.com. This allowed requests to [...]]]></description>
			<content:encoded><![CDATA[<p>If you&#8217;ve been following my blog for awhile, you might have noticed I moved this blog from <a href="http://blog.notedpath.com">blog.notedpath.com</a> to <a href="http://www.theodorenguyen-cao.com">theodorenguyen-cao.com</a> as it was more fitting domain.  I originally just registered the domain, added the DNS record, and updated my apache config to have <a href="http://www.theodorenguyen-cao.com">theodorenguyen-cao.com</a> to be an server alias to blog.notedpath.com.</p>
<p>This allowed requests to blog.notedpath.com/* and theodorenguyen-cao/* respond with the same content.  I thought I was done.  I discovered this wasn&#8217;t the case when I saw blog.notedpath.com as a direct traffic source in my google analytics for <a href="http://www.theodorenguyen-cao.com">theodorenguyen-cao.com</a>.  To fix the screwed up analytics, I needed to make it so that all requests that go to blog.notedpath.com are permanently redirected (301) to <a href="http://www.theodorenguyen-cao.com">theodorenguyen-cao.com</a>.</p>
<p>To do this I had to apply an Apache mod_alias <a href="http://httpd.apache.org/docs/1.3/mod/mod_alias.html#redirect" target="_blank">redirect directive</a> as such:</p>
<pre name="code" class="xml" >
&lt;VirtualHost *:80&gt;
        VirtualDocumentRoot /var/www/blog
        ServerName blog.notedpath.com
        Redirect permanent / http://www.theodorenguyen-cao.com/
        ErrorLog /var/log/apache2/wp-error.log
        TransferLog /var/log/apache2/wp-access.log
&lt;/VirtualHost&gt;
</pre>
<p>The virtual host for <a href="http://www.theodorenguyen-cao.com">theodorenguyen-cao.com</a> looks like:</p>
<pre name="code" class="xml" >
&lt;VirtualHost *:80&gt;
    VirtualDocumentRoot /var/www/blog
    ServerName www.theodorenguyen-cao.com
    ServerAlias theodorenguyen-cao.com
    CustomLog /var/log/apache2/theodorenguyen-cao.com_access.log Combined
    ErrorLog /var/log/apache2/theodorenguyen-cao_error.log
&lt;/VirtualHost&gt;
</pre>
<p>At first I thought this would only fix the simple case of blog.notedpath.com redirecting to <a href="http://www.theodorenguyen-cao.com">theodorenguyen-cao.com</a>, but blog.notepath.com/foobar not being translated to theodorenguyen-cao.com/foobar.  However, this does exactly what I want. All blog.notedpath.com URLs will be replaced with <a href="http://www.theodorenguyen-cao.com">theodorenguyen-cao.com</a> URLs.  Old bookmarks will simply redirect to a theodorenguyen-cao.com URL and not 404.</p>
<p>Success!</p>
<p>I&#8217;m still waiting to see if Google will update the search result links that point to blog.notedpath.com to be <a href="http://www.theodorenguyen-cao.com">theodorenguyen-cao.com</a> URLs.</p>
]]></content:encoded>
			<wfw:commentRss>http://www.theodorenguyen-cao.com/2009/01/21/moving-wordpress-to-another-host/feed/</wfw:commentRss>
		<slash:comments>0</slash:comments>
		</item>
	</channel>
</rss>
