<?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>zach.blog &#187; backup</title>
	<atom:link href="http://blog.zachtib.com/tag/backup/feed/" rel="self" type="application/rss+xml" />
	<link>http://blog.zachtib.com</link>
	<description>General geekery and whatnot</description>
	<lastBuildDate>Mon, 28 Nov 2011 19:20:36 +0000</lastBuildDate>
	<language>en</language>
	<sy:updatePeriod>hourly</sy:updatePeriod>
	<sy:updateFrequency>1</sy:updateFrequency>
	<generator>http://wordpress.org/?v=3.3.1</generator>
		<item>
		<title>Automatic offsite WordPress backups</title>
		<link>http://blog.zachtib.com/2008/09/automatic-offsite-wordpress-backups/</link>
		<comments>http://blog.zachtib.com/2008/09/automatic-offsite-wordpress-backups/#comments</comments>
		<pubDate>Wed, 24 Sep 2008 15:38:27 +0000</pubDate>
		<dc:creator>Zach</dc:creator>
				<category><![CDATA[Blog]]></category>
		<category><![CDATA[backup]]></category>
		<category><![CDATA[howto]]></category>

		<guid isPermaLink="false">http://collegegeek.org/?p=363</guid>
		<description><![CDATA[Yesterday, I decided to set up a an automated backup solution for my site here.  Basically, it does an sqldump then sends the dump to another server over SCP. First, I had to enable SSH login without a password in &#8230; <a href="http://blog.zachtib.com/2008/09/automatic-offsite-wordpress-backups/">Continue reading <span class="meta-nav">&#8594;</span></a>]]></description>
			<content:encoded><![CDATA[<p>Yesterday, I decided to set up a an automated backup solution for my site here.  Basically, it does an sqldump then sends the dump to another server over SCP.</p>
<p>First, I had to enable SSH login without a password in order for SCP to work in a cronjob.  I followed <a href="http://www.spaceprogram.com/knowledge/cron_scp.html" target="_blank">this howto</a> and it worked perfectly.</p>
<p>Then, I created a backup script to be called by cron:</p>
<blockquote><p>#!/bin/sh</p>
<p>cd /home/backups/collegegeek</p>
<p>FNAME=collegegeek-`date +%F`.sql</p>
<p>mysqldump &#8211;add-drop-table -uroot -pPASSWORDHERE collegegeek &gt; $FNAME<br />
bzip2 $FNAME<br />
rm $FNAME<br />
scp $FNAME.bz2 zach@192.168.1.82:backups/<br />
echo &#8220;Nightly Backup Successful: $(date)&#8221; &gt;&gt; /home/backups/blogbackup.log</p></blockquote>
<p>This will also leave a copy on the local server on the /home partition.  Note that /home is on a different physical drive than /var, so if the drive with the SQL database goes down, I should have a local copy as well.</p>
]]></content:encoded>
			<wfw:commentRss>http://blog.zachtib.com/2008/09/automatic-offsite-wordpress-backups/feed/</wfw:commentRss>
		<slash:comments>0</slash:comments>
		</item>
	</channel>
</rss>

