<?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>Matt&#039;s Technology Blog</title>
	<atom:link href="http://technology.mattrude.com/feed/" rel="self" type="application/rss+xml" />
	<link>http://technology.mattrude.com</link>
	<description>A place to play with code, software, &#38; the web</description>
	<lastBuildDate>Sun, 27 May 2012 18:05:54 +0000</lastBuildDate>
	<language>en-US</language>
	<sy:updatePeriod>hourly</sy:updatePeriod>
	<sy:updateFrequency>1</sy:updateFrequency>
	<generator>http://wordpress.org/?v=3.4-RC1-20965</generator>
		<item>
		<title>Git: Add all remote branches</title>
		<link>http://technology.mattrude.com/2012/05/git-add-all-branches/</link>
		<comments>http://technology.mattrude.com/2012/05/git-add-all-branches/#comments</comments>
		<pubDate>Mon, 21 May 2012 05:56:51 +0000</pubDate>
		<dc:creator>Matt Rude</dc:creator>
				<category><![CDATA[General]]></category>
		<category><![CDATA[Fedora]]></category>
		<category><![CDATA[Git]]></category>

		<guid isPermaLink="false">http://technology.mattrude.com/?p=5472</guid>
		<description><![CDATA[Adding each remote branch to a local git repository sometimes can be a pain. IF there are many, you have to repeat your self over and over. Here is a quick, copy and past drop into you console, way to &#8230; <a href="http://technology.mattrude.com/2012/05/git-add-all-branches/">Continue reading <span class="meta-nav">&#8594;</span></a><a href="http://technology.mattrude.com/2012/05/git-add-all-branches/">Git: Add all remote branches</a> is a post from; <a href="http://technology.mattrude.com/">Matt&#039;s Technology Blog</a> which is not allowed to be copied on other sites.]]></description>
			<content:encoded><![CDATA[<p>Adding each remote branch to a local git repository sometimes can be a pain.  IF there are many, you have to repeat your self over and over.  Here is a quick, copy and past drop into you console, way to add all the remote branches to your local repository.</p>
<pre>for b in `git remote show origin |grep tracked |awk '{print $1}'`
do
    LOCALBRANCH=`git branch |sed 's/* //g' |sed 's/  //g' |grep $b`
    if [ "$LOCALBRANCH" != "$b" ]; then
        git branch -t $b origin/$b
    fi
done</pre>
<p>Once your done, you should still be in your original branch were you started.  You will still need to update each branch by it self. You may also use something like <a href="https://github.com/aanand/git-up" title="Stop using "git pull". Be polite." target="_blank">git-up</a> to update all the branches at once.</p>
<a href="http://technology.mattrude.com/2012/05/git-add-all-branches/">Git: Add all remote branches</a> is a post from; <a href="http://technology.mattrude.com/">Matt&#039;s Technology Blog</a> which is not allowed to be copied on other sites.]]></content:encoded>
			<wfw:commentRss>http://technology.mattrude.com/2012/05/git-add-all-branches/feed/</wfw:commentRss>
		<slash:comments>0</slash:comments>
		</item>
		<item>
		<title>WordPress:  Add footer text to feed posts</title>
		<link>http://technology.mattrude.com/2012/05/wordpress-add-footer-text-to-feed-posts/</link>
		<comments>http://technology.mattrude.com/2012/05/wordpress-add-footer-text-to-feed-posts/#comments</comments>
		<pubDate>Fri, 18 May 2012 15:15:47 +0000</pubDate>
		<dc:creator>Matt Rude</dc:creator>
				<category><![CDATA[How-To's]]></category>
		<category><![CDATA[RSS]]></category>
		<category><![CDATA[WordPress]]></category>

		<guid isPermaLink="false">http://technology.mattrude.com/?p=5460</guid>
		<description><![CDATA[Here&#8217;s a small code snippet for adding text to the bottom of each post in your rss feed. This will not affect the post content shown on your site. The below should be added to your themes function.php file. /******************************************************************************** &#8230; <a href="http://technology.mattrude.com/2012/05/wordpress-add-footer-text-to-feed-posts/">Continue reading <span class="meta-nav">&#8594;</span></a><a href="http://technology.mattrude.com/2012/05/wordpress-add-footer-text-to-feed-posts/">WordPress:  Add footer text to feed posts</a> is a post from; <a href="http://technology.mattrude.com/">Matt&#039;s Technology Blog</a> which is not allowed to be copied on other sites.]]></description>
			<content:encoded><![CDATA[<p>Here&#8217;s a small code snippet for adding text to the bottom of each post in your <a href="http://en.wikipedia.org/wiki/RSS">rss</a> feed.  This will not affect the post content shown on your site.</p>
<p>The below should be added to your themes <code>function.php</code> file.</p>
<pre>
/********************************************************************************
* Add Footer to RSS feed
*/

function mdr_postrss($content) {
    if(is_feed()){
        $site_name = get_bloginfo_rss('name');
        $post_title = get_the_title_rss();
        $home_url = home_url('/');
        $post_url = post_permalink();
        $content = $content.'&lt;a href="'.$post_url.'"&gt;'.$post_title.'&lt;/a&gt; is a post from: 
&lt;a href="'.$home_url.'"&gt;'.$site_name.'&lt;/a&gt; which is not allowed to be copied on other sites.';
    }
    return $content;
}
add_filter('the_excerpt_rss', 'mdr_postrss');
add_filter('the_content', 'mdr_postrss');
</pre>
<p>Or may be found on <a href="https://gist.github.com/2758927" target="_blank">github</a>.</p>
<a href="http://technology.mattrude.com/2012/05/wordpress-add-footer-text-to-feed-posts/">WordPress:  Add footer text to feed posts</a> is a post from; <a href="http://technology.mattrude.com/">Matt&#039;s Technology Blog</a> which is not allowed to be copied on other sites.]]></content:encoded>
			<wfw:commentRss>http://technology.mattrude.com/2012/05/wordpress-add-footer-text-to-feed-posts/feed/</wfw:commentRss>
		<slash:comments>0</slash:comments>
		</item>
		<item>
		<title>Git: Configuring native git commit emails</title>
		<link>http://technology.mattrude.com/2012/05/configuring-native-git-commit-emails/</link>
		<comments>http://technology.mattrude.com/2012/05/configuring-native-git-commit-emails/#comments</comments>
		<pubDate>Sun, 13 May 2012 19:20:21 +0000</pubDate>
		<dc:creator>Matt Rude</dc:creator>
				<category><![CDATA[How-To's]]></category>
		<category><![CDATA[email]]></category>
		<category><![CDATA[Git]]></category>
		<category><![CDATA[scripts]]></category>

		<guid isPermaLink="false">http://technology.mattrude.com/?p=5451</guid>
		<description><![CDATA[To start out, move the post-receive.sample script from your git hooks directory to just plain post-receive like so: mv post-receive.sample post-receive Then in your git config file add the below, below any existing configuration items. Note, you will need to &#8230; <a href="http://technology.mattrude.com/2012/05/configuring-native-git-commit-emails/">Continue reading <span class="meta-nav">&#8594;</span></a><a href="http://technology.mattrude.com/2012/05/configuring-native-git-commit-emails/">Git: Configuring native git commit emails</a> is a post from; <a href="http://technology.mattrude.com/">Matt&#039;s Technology Blog</a> which is not allowed to be copied on other sites.]]></description>
			<content:encoded><![CDATA[<p>To start out, move the <em>post-receive.sample</em> script from your git <em>hooks</em> directory to just plain <em>post-receive</em> like so:</p>
<pre>mv post-receive.sample post-receive</pre>
<p>Then in your git <em>config</em> file add the below, below any existing configuration items.  <em>Note, you will need to change the URL and repository name (currently named &#8220;git-repository&#8221;) before this will work.</em></p>
<pre>[hooks]
        mailinglist = email@example.com
        emailprefix = "git-repository: "
        showrev = "t=%s; printf 'https://example.com/secure/?p=git-repoistory;a=commitdiff;h=%%s' $t; echo;echo; git show -C $t; echo;"</pre>
<p>And there you go, when you now push to the repository, you will receive an email send to &#8220;mailinglist&#8221; with the changes made in a nice diff and a link back to your main git repository site.</p>
<a href="http://technology.mattrude.com/2012/05/configuring-native-git-commit-emails/">Git: Configuring native git commit emails</a> is a post from; <a href="http://technology.mattrude.com/">Matt&#039;s Technology Blog</a> which is not allowed to be copied on other sites.]]></content:encoded>
			<wfw:commentRss>http://technology.mattrude.com/2012/05/configuring-native-git-commit-emails/feed/</wfw:commentRss>
		<slash:comments>0</slash:comments>
		</item>
		<item>
		<title>WordPress Correct File Permissions</title>
		<link>http://technology.mattrude.com/2012/04/wordpress-correct-file-permissions/</link>
		<comments>http://technology.mattrude.com/2012/04/wordpress-correct-file-permissions/#comments</comments>
		<pubDate>Mon, 16 Apr 2012 22:37:35 +0000</pubDate>
		<dc:creator>Matt Rude</dc:creator>
				<category><![CDATA[How-To's]]></category>
		<category><![CDATA[Apache]]></category>
		<category><![CDATA[Apache HTTP Server]]></category>
		<category><![CDATA[chmod]]></category>
		<category><![CDATA[Filesystem permissions]]></category>
		<category><![CDATA[Nginx]]></category>
		<category><![CDATA[Permissions]]></category>
		<category><![CDATA[WordPress]]></category>

		<guid isPermaLink="false">http://technology.mattrude.com/?p=5421</guid>
		<description><![CDATA[To lock down the permissions on your WordPress install, from inside the WordPress site directory, run the below commands. chown -R root:root . chown -R nginx:nginx wp-content wp-admin/update.php wp-admin/update-core.php \ wp-admin/network/update.php wp-admin/network/update-core.php Note, the above command assumes you are running &#8230; <a href="http://technology.mattrude.com/2012/04/wordpress-correct-file-permissions/">Continue reading <span class="meta-nav">&#8594;</span></a><a href="http://technology.mattrude.com/2012/04/wordpress-correct-file-permissions/">WordPress Correct File Permissions</a> is a post from; <a href="http://technology.mattrude.com/">Matt&#039;s Technology Blog</a> which is not allowed to be copied on other sites.]]></description>
			<content:encoded><![CDATA[<p>To lock down the permissions on your WordPress install, from inside the WordPress site directory, run the below commands.</p>
<pre>chown -R root:root .
chown -R nginx:nginx wp-content wp-admin/update.php wp-admin/update-core.php \
wp-admin/network/update.php wp-admin/network/update-core.php</pre>
<p><small><em>Note, the above command assumes you are running under Nginx, if you are under Apache, please run the 2nd command replacing nginx with apache</em></small></p>
<p>The above command will change all the files in your WordPress root to the ROOT user, then change only the needed files back to user your web server is running as. This will allow you to update themes &amp; plugins, and will also let you upload images, but you will not be able to update WordPress without changing the owner/group back to nginx on your WordPress root.</p>
<a href="http://technology.mattrude.com/2012/04/wordpress-correct-file-permissions/">WordPress Correct File Permissions</a> is a post from; <a href="http://technology.mattrude.com/">Matt&#039;s Technology Blog</a> which is not allowed to be copied on other sites.]]></content:encoded>
			<wfw:commentRss>http://technology.mattrude.com/2012/04/wordpress-correct-file-permissions/feed/</wfw:commentRss>
		<slash:comments>0</slash:comments>
		</item>
		<item>
		<title>GoDaddy SSL Certificate with Nginx</title>
		<link>http://technology.mattrude.com/2012/04/godaddy-ssl-certificate-with-nginx/</link>
		<comments>http://technology.mattrude.com/2012/04/godaddy-ssl-certificate-with-nginx/#comments</comments>
		<pubDate>Sun, 15 Apr 2012 01:00:41 +0000</pubDate>
		<dc:creator>Matt Rude</dc:creator>
				<category><![CDATA[How-To's]]></category>
		<category><![CDATA[Certificate authority]]></category>
		<category><![CDATA[GoDaddy]]></category>
		<category><![CDATA[Nginx]]></category>
		<category><![CDATA[Public key certificate]]></category>
		<category><![CDATA[Public-key cryptography]]></category>

		<guid isPermaLink="false">http://technology.mattrude.com/?p=5396</guid>
		<description><![CDATA[Installing a SSL certificate from Go Daddy is a bit different then other providers.  With Go Daddy you must install a intermediate or chain certificate addition to your CA certificate. Nginx does not have a option, how Apache dose, for &#8230; <a href="http://technology.mattrude.com/2012/04/godaddy-ssl-certificate-with-nginx/">Continue reading <span class="meta-nav">&#8594;</span></a><a href="http://technology.mattrude.com/2012/04/godaddy-ssl-certificate-with-nginx/">GoDaddy SSL Certificate with Nginx</a> is a post from; <a href="http://technology.mattrude.com/">Matt&#039;s Technology Blog</a> which is not allowed to be copied on other sites.]]></description>
			<content:encoded><![CDATA[<p>Installing a SSL certificate from Go Daddy is a bit different then other providers.  With Go Daddy you must install a intermediate or chain certificate addition to your CA certificate. Nginx does not have a option, how Apache dose, for chain certificates. So to accomplish this, we look to the Nginx documentation:</p>
<blockquote><p>If intermediate certificates should be specified in addition to a primary certificate, they should be specified in the same file in the following order: the primary certificate comes first, then the intermediate certificates. <a class="simple-footnote" title="Nginx Module ngx_http_ssl_module" id="return-note-5396-1" href="#note-5396-1"><sup>1</sup></a></p></blockquote>
<p>What that means is this.  Download your CA from with your private certificate from Go Daddy.  Next download the <code>gd_bundle.crt</code> from <a href="https://certs.godaddy.com/anonymous/repository.seam" target="_blank">https://certs.godaddy.com/anonymous/repository.seam</a>.</p>
<p>After you have download the <code>gd_bundle.crt</code> file, copy it to the same directory on your Nginx server and run something similar to:</p>
<pre>cat godaddy-ca.crt > godaddy-chain.crt &#038;&#038; cat gd_bundle.crt >> godaddy-chain.crt</pre>
<p>Now just add this new certificate to your nginx.conf per normal</p>
<pre>ssl_certificate godaddy-chain.crt</pre>
<a href="http://technology.mattrude.com/2012/04/godaddy-ssl-certificate-with-nginx/">GoDaddy SSL Certificate with Nginx</a> is a post from; <a href="http://technology.mattrude.com/">Matt&#039;s Technology Blog</a> which is not allowed to be copied on other sites.<div class="simple-footnotes"><p class="notes">Notes:</p><ol><li id="note-5396-1"><a href="http://nginx.org/en/docs/http/ngx_http_ssl_module.html#directives" target="_blank">Nginx Module ngx_http_ssl_module</a> <a href="#return-note-5396-1">&#8617;</a></li></ol></div>]]></content:encoded>
			<wfw:commentRss>http://technology.mattrude.com/2012/04/godaddy-ssl-certificate-with-nginx/feed/</wfw:commentRss>
		<slash:comments>0</slash:comments>
		</item>
		<item>
		<title>Trac Installed on a Nginx Server</title>
		<link>http://technology.mattrude.com/2012/04/trac-installed-on-a-nginx-server/</link>
		<comments>http://technology.mattrude.com/2012/04/trac-installed-on-a-nginx-server/#comments</comments>
		<pubDate>Sat, 14 Apr 2012 23:03:56 +0000</pubDate>
		<dc:creator>Matt Rude</dc:creator>
				<category><![CDATA[How-To's]]></category>
		<category><![CDATA[Apache]]></category>
		<category><![CDATA[Apache HTTP Server]]></category>
		<category><![CDATA[Nginx]]></category>
		<category><![CDATA[Python]]></category>
		<category><![CDATA[Trac]]></category>

		<guid isPermaLink="false">http://technology.mattrude.com/?p=5382</guid>
		<description><![CDATA[Over the last few weeks I have been converting all my different sites from Apache to Nginx. The nice part of this plan is as I move on from system to system, each change over get&#8217;s easier then the last. &#8230; <a href="http://technology.mattrude.com/2012/04/trac-installed-on-a-nginx-server/">Continue reading <span class="meta-nav">&#8594;</span></a><a href="http://technology.mattrude.com/2012/04/trac-installed-on-a-nginx-server/">Trac Installed on a Nginx Server</a> is a post from; <a href="http://technology.mattrude.com/">Matt&#039;s Technology Blog</a> which is not allowed to be copied on other sites.]]></description>
			<content:encoded><![CDATA[<p>Over the last few weeks I have been converting all my different sites from <a title="Apache" href="http://en.wikipedia.org/wiki/Apache" rel="wikipedia">Apache</a> to <a title="Nginx" href="http://www.nginx.org/" rel="homepage">Nginx</a>. The nice part of this plan is as I move on from system to system, each change over get&#8217;s easier then the last.</p>
<p>This how-to will walk you threw how to instal Trac on a Nginx server.  The plan here is to proxy your trac site back to <a title="Trac Stand alone Server" href="http://trac.edgewall.org/wiki/TracStandalone">tracd</a> running server.  Only proxy the files that are not real and can not be served by nginx alone.</p>
<p>To start out, install python and some python tools to your server</p>
<pre>yum -y install python python-genshi python-setuptools \
subversion python-setuptools-devel</pre>
<p>Now you need to download and install trac from svn</p>
<pre>svn checkout http://svn.edgewall.org/repos/trac/trunk/ trac
cd trac</pre>
<p>After you have the current version, compile and install trac</p>
<pre>python ./setup.py install</pre>
<p>This how-to assumes you already have a working trac profile to host on this site.  If you do not already have a trac profile, please look at <code>trac-admin /path/to/websites/directory initenv</code>.</p>
<p>After you have trac installed, you need to start it.</p>
<pre>export TRAC_ENV_INDEX_TEMPLATE=/var/www/trac/projects_list_template.html
/usr/bin/python /usr/bin/tracd -d -p 3050 \
--auth=*,/var/www/trac.example.com/projects/.htpasswd,trac.example.com \
--protocol=http -e /var/www/trac.example.com/projects</pre>
<p>And here&#8217;s a simple example Nginx config for your new trac setup.</p>
<pre>
   # trac.example.com
   upstream trac.example.com {
       server 127.0.0.1:3050;
   }
   
   server {
       listen 80;
       server_name trac.example.com;
       root /var/www/trac.example.com;
       
       location /html/ { 
       	expires 180d;
       }
       
       location /favicon.ico { }
       location /robots.txt { }
       
       location / {
               proxy_pass        http://trac.example.com;
               proxy_set_header  X-Real-IP  $remote_addr;
       }
   }</pre>
<a href="http://technology.mattrude.com/2012/04/trac-installed-on-a-nginx-server/">Trac Installed on a Nginx Server</a> is a post from; <a href="http://technology.mattrude.com/">Matt&#039;s Technology Blog</a> which is not allowed to be copied on other sites.]]></content:encoded>
			<wfw:commentRss>http://technology.mattrude.com/2012/04/trac-installed-on-a-nginx-server/feed/</wfw:commentRss>
		<slash:comments>0</slash:comments>
		</item>
		<item>
		<title>Custom 404 errors pages in Nginx</title>
		<link>http://technology.mattrude.com/2012/03/custom-404-errors-pages-in-nginx/</link>
		<comments>http://technology.mattrude.com/2012/03/custom-404-errors-pages-in-nginx/#comments</comments>
		<pubDate>Thu, 29 Mar 2012 02:45:43 +0000</pubDate>
		<dc:creator>Matt Rude</dc:creator>
				<category><![CDATA[How-To's]]></category>
		<category><![CDATA[How-To]]></category>
		<category><![CDATA[Nginx]]></category>

		<guid isPermaLink="false">http://technology.mattrude.com/?p=5369</guid>
		<description><![CDATA[Here&#8217;s a quick how-to on creating a custom 404 error page on a Nginx server. To display a single page for a site, add the below to your server&#8217;s config. The below config assumes /404.html is in the root of &#8230; <a href="http://technology.mattrude.com/2012/03/custom-404-errors-pages-in-nginx/">Continue reading <span class="meta-nav">&#8594;</span></a><a href="http://technology.mattrude.com/2012/03/custom-404-errors-pages-in-nginx/">Custom 404 errors pages in Nginx</a> is a post from; <a href="http://technology.mattrude.com/">Matt&#039;s Technology Blog</a> which is not allowed to be copied on other sites.]]></description>
			<content:encoded><![CDATA[<p>Here&#8217;s a quick how-to on creating a custom 404 error page on a Nginx server.</p>
<p>To display a single page for a site, add the below to your server&#8217;s config.  The below config assumes <em>/404.html</em> is in the root of the current site.</p>
<pre>server {
    ...
    error_page 404 /404.html;
    ...
}</pre>
<p>The error page it self doesn&#8217;t have to be anything special, just a clear message for the user to know that this page dose not exist.</p>
<a href="http://technology.mattrude.com/2012/03/custom-404-errors-pages-in-nginx/">Custom 404 errors pages in Nginx</a> is a post from; <a href="http://technology.mattrude.com/">Matt&#039;s Technology Blog</a> which is not allowed to be copied on other sites.]]></content:encoded>
			<wfw:commentRss>http://technology.mattrude.com/2012/03/custom-404-errors-pages-in-nginx/feed/</wfw:commentRss>
		<slash:comments>0</slash:comments>
		</item>
		<item>
		<title>shopathome.com</title>
		<link>http://technology.mattrude.com/2012/03/shopathome-com/</link>
		<comments>http://technology.mattrude.com/2012/03/shopathome-com/#comments</comments>
		<pubDate>Tue, 27 Mar 2012 13:32:40 +0000</pubDate>
		<dc:creator>Matt Rude</dc:creator>
				<category><![CDATA[Asides]]></category>
		<category><![CDATA[virus]]></category>

		<guid isPermaLink="false">http://technology.mattrude.com/?p=5365</guid>
		<description><![CDATA[The shopathome.com tool bar is about a half a step from being a virus. Stay far away from it. It seems to auto install on users systems and dose not have a clean/easy way for it to be removed. That &#8230; <a href="http://technology.mattrude.com/2012/03/shopathome-com/">Continue reading <span class="meta-nav">&#8594;</span></a><a href="http://technology.mattrude.com/2012/03/shopathome-com/">shopathome.com</a> is a post from; <a href="http://technology.mattrude.com/">Matt&#039;s Technology Blog</a> which is not allowed to be copied on other sites.]]></description>
			<content:encoded><![CDATA[<p>The shopathome.com tool bar is about a half a step from being a virus. Stay far away from it.  It seems to auto install on users systems and dose not have a clean/easy way for it to be removed.  That site is not blocked on our corporate network.</p>
<a href="http://technology.mattrude.com/2012/03/shopathome-com/">shopathome.com</a> is a post from; <a href="http://technology.mattrude.com/">Matt&#039;s Technology Blog</a> which is not allowed to be copied on other sites.]]></content:encoded>
			<wfw:commentRss>http://technology.mattrude.com/2012/03/shopathome-com/feed/</wfw:commentRss>
		<slash:comments>0</slash:comments>
		</item>
		<item>
		<title>Gallery3 Installed on a Nginx Server</title>
		<link>http://technology.mattrude.com/2012/02/gallery3-installed-on-a-nginx-server/</link>
		<comments>http://technology.mattrude.com/2012/02/gallery3-installed-on-a-nginx-server/#comments</comments>
		<pubDate>Mon, 27 Feb 2012 02:09:38 +0000</pubDate>
		<dc:creator>Matt Rude</dc:creator>
				<category><![CDATA[How-To's]]></category>
		<category><![CDATA[.htaccess]]></category>
		<category><![CDATA[Apache]]></category>
		<category><![CDATA[Apache HTTP Server]]></category>
		<category><![CDATA[Fedora]]></category>
		<category><![CDATA[Gallery3]]></category>
		<category><![CDATA[Nginx]]></category>
		<category><![CDATA[php]]></category>
		<category><![CDATA[php-fpm]]></category>
		<category><![CDATA[Server]]></category>
		<category><![CDATA[Web server]]></category>

		<guid isPermaLink="false">http://technology.mattrude.com/?p=5280</guid>
		<description><![CDATA[A few months ago I converted my web cluster from Apache to Nginx. Initially I was only concerned with my WordPress sites as they get, by far the most traffic. Their conversion went well, with only very minor issues. Since &#8230; <a href="http://technology.mattrude.com/2012/02/gallery3-installed-on-a-nginx-server/">Continue reading <span class="meta-nav">&#8594;</span></a><a href="http://technology.mattrude.com/2012/02/gallery3-installed-on-a-nginx-server/">Gallery3 Installed on a Nginx Server</a> is a post from; <a href="http://technology.mattrude.com/">Matt&#039;s Technology Blog</a> which is not allowed to be copied on other sites.]]></description>
			<content:encoded><![CDATA[<p>A few months ago I converted my web cluster from <a class="zem_slink" title="Apache" href="http://en.wikipedia.org/wiki/Apache" rel="wikipedia">Apache</a> to <a class="zem_slink" title="Nginx" href="http://www.nginx.org/" rel="homepage">Nginx</a>. Initially I was only concerned with my <a href="http://technology.mattrude.com/2012/02/installing-wordpress-on-nginx/" title="Installing WordPress on Nginx" target="_blank">WordPress</a> sites as they get, by far the most traffic. Their conversion went well, with only very minor issues.</p>
<p>Since I was happy with the results, I moved to quickly to my <a href="http://technology.mattrude.com/2012/02/configuring-mediawiki-to-be-used-with-nginx/" title="MediaWiki Installed on a Nginx Server" target="_blank">MediaWiki</a> site. It’s conversion went very well and actually end up allowing the site to accept requests with and without index.php in them.</p>
<p>During this time, my other random sites, using odd or old software, was simply proxied back to the still running Apache install on my server. Using nginx&#8217;s proxy configuration, i was able to just change the port Apache listen on and left the old configurations as they were.  This allowed me to stay up, but didn&#8217;t give me any of the benefits of nginx.  Images from the my Gallery3 gallery were still being served from Apache, threw Nginx.</p>
<p>After getting everything working, I decided to start on Gallery3, since Gallery3 uses <em>.htaccess</em> files to secure images, I wasn&#8217;t sure how I would be able to go about this.  After some investigating I found that Gallery3 only uses the <em>.htaccess</em> files to block downloading of the actual images them self&#8217;s, the php pages are still secured threw normal permissions.</p>
<h2>Configuring Nginx</h2>
<p>Setting up Gallery3 under Nginx is pretty straightforward, when ignoring the .htaccess file talked about above.  As with all my Nginx setup&#8217;s, im using <a title="PHP-FPM (FastCGI Process Manager) is an alternative PHP FastCGI implementation." href="http://php-fpm.org/" target="_blank">php-fpm</a> via a UNIX sock.  Switching to a TCP connection (such as 127.0.0.0:8000), can be substituted with only minor tweaks.</p>
<p>To start out, create a new file in your nginx configuration directory, named <strong>gallery3.conf</strong>.  This file will be generic enough that you will be able to use it for any Gallery3 install on the server. Your site specific information will live in your main nginx.conf file.</p>
<p><strong>Create a new file named gallery3.conf, and copy the below into it:</strong></p>
<pre>location ~* \.(js|css|png|jpg|jpeg|gif|ico|ttf)$ {
    expires 180d;
#    if_modified_since off;
#    add_header Last-Modified "";
}

if (!-e $request_filename) {
    rewrite ^/(.+)$ /index.php?kohana_uri=$1 last;
}

location /var/ {
    try_files $uri /index.php?kohana_uri=$2;
}

location = /downloadalbum/zip/album/1 {
    return 404;
}

location  ~* \.php$ {
    include fastcgi_params;
    fastcgi_index  index.php;
    fastcgi_split_path_info ^(.+\.php)(.*)$;
    fastcgi_param  SCRIPT_FILENAME  $document_root$fastcgi_script_name;
    fastcgi_param  PATH_INFO        $fastcgi_path_info;
    fastcgi_pass php;

    index index.php;

    if (-f $request_filename) {
        rewrite ^/var/albums/(.*)$ /file_proxy/$1 last;
        expires max;
        break;
    }

    if (!-e $request_filename) {
        rewrite ^/(.+)$ /index.php?kohana_uri=$1 last;
    }
}
</pre>
<p>Now you need to setup your new site in Nginx&#8217;s main config file.  Below is the most basic setup, it assumes you have a running Nginx server and are only adding this site to it.  Note the name of the server and the root location of the files needs to be updated.</p>
<p><strong>Added to nginx.conf:</strong></p>
<pre>server {
    listen 80;
    server_name gallery.example.com;
    root /var/www/gallery.example.com;
    include gallery3.conf;
}</pre>
<p>This next part really sucks and I wish there was a way around it, in your Gallery3 installation, go into <em>applications/config/config.php</em> and modify the &#8220;<em>index_page</em>&#8221; setting as shown below.</p>
<p><strong>application/config/config.php:</strong></p>
<pre>$config["index_page"] = "";</pre>
<p>What sucks about this is you will need to do it after <strong>EVERY UPDATE</strong>.  If after you update Gallery3 and you loose your style sheet and java scripts, this is why.</p>
<p>The config file should not live in a location that get&#8217;s updated automatically with new versions of software.</p>
<a href="http://technology.mattrude.com/2012/02/gallery3-installed-on-a-nginx-server/">Gallery3 Installed on a Nginx Server</a> is a post from; <a href="http://technology.mattrude.com/">Matt&#039;s Technology Blog</a> which is not allowed to be copied on other sites.]]></content:encoded>
			<wfw:commentRss>http://technology.mattrude.com/2012/02/gallery3-installed-on-a-nginx-server/feed/</wfw:commentRss>
		<slash:comments>0</slash:comments>
		</item>
		<item>
		<title>MediaWiki Installed on a Nginx Server</title>
		<link>http://technology.mattrude.com/2012/02/configuring-mediawiki-to-be-used-with-nginx/</link>
		<comments>http://technology.mattrude.com/2012/02/configuring-mediawiki-to-be-used-with-nginx/#comments</comments>
		<pubDate>Wed, 15 Feb 2012 21:33:08 +0000</pubDate>
		<dc:creator>Matt Rude</dc:creator>
				<category><![CDATA[How-To's]]></category>
		<category><![CDATA[Apache]]></category>
		<category><![CDATA[Apache HTTP Server]]></category>
		<category><![CDATA[MediaWiki]]></category>
		<category><![CDATA[Nginx]]></category>
		<category><![CDATA[php]]></category>
		<category><![CDATA[php-fpm]]></category>

		<guid isPermaLink="false">http://technology.mattrude.com/?p=5265</guid>
		<description><![CDATA[Here is my quick guide to use MediaWiki on a Nginx server using php-fpm. There are many ways of doing this. I like pretty url&#8217;s, so this configuration will remove the index.php from the url. This is great, but it will &#8230; <a href="http://technology.mattrude.com/2012/02/configuring-mediawiki-to-be-used-with-nginx/">Continue reading <span class="meta-nav">&#8594;</span></a><a href="http://technology.mattrude.com/2012/02/configuring-mediawiki-to-be-used-with-nginx/">MediaWiki Installed on a Nginx Server</a> is a post from; <a href="http://technology.mattrude.com/">Matt&#039;s Technology Blog</a> which is not allowed to be copied on other sites.]]></description>
			<content:encoded><![CDATA[<p>Here is my quick guide to use <a title="MediaWiki is a free software open source wiki package written in PHP, originally for use on Wikipedia." href="http://www.mediawiki.org/wiki/MediaWiki" target="_blank">MediaWiki</a> on a <a title="Nginx HTTP Web Server" href="http://nginx.org/" target="_blank">Nginx</a> server using <a title="PHP-FPM (FastCGI Process Manager) is an alternative PHP FastCGI implementation." href="http://php-fpm.org/" target="_blank">php-fpm</a>.</p>
<p>There are many ways of doing this. I like pretty url&#8217;s, so this configuration will remove the <code>index.php</code> from the url. This is great, but it will <em>not</em> redirect links to index.php to the new none index.php links.  You also need to configure MediaWiki to <a href="http://www.mediawiki.org/wiki/Manual:Short_URL#URL_like_-_example.com.2FPage_title" target="_blank">use short urls</a>. Also, the below configuration <em>dose</em> assume your using Unix socket connections to php-fpm.</p>
<p>So here we go, inside your <code>http {</code> block, add the following.</p>
<p><strong>/etc/nginx/nginx.conf:</strong></p>
<pre>    server {
        listen 80;
        server_name wiki.example.com;
        root /var/www/wiki.example.com;
        include mediawiki.conf;
    }</pre>
<p><strong>/etc/nginx/mediawiki.conf:</strong></p>
<pre># MediaWiki Config
location ~ \.htaccess {
        deny all;
}

location ~* /sitemaps/ {
        autoindex  on;
}

# Remote index.php from URI
rewrite ^/index.php/(.*) /$1  permanent;

location / {
        if (!-e $request_filename) {
                rewrite ^/([^?]*)(?:\?(.*))? /index.php?title=$1&#038;$2 last;
        }
        if ($uri ~* "\.(ico|css|js|gif|jpe?g|png)(\?[0-9]+)?$") {
                expires max;
                break;
        }
}

location ~* \.php$ {
        if (!-e $request_filename) {
                return 404;
        }

        include /etc/nginx/fastcgi_params;

        fastcgi_pass  unix:/var/run/php-fpm.socket;
        fastcgi_index index.php;

        fastcgi_param  SCRIPT_FILENAME  $document_root$fastcgi_script_name;
}</pre>
<p>If you only have a single wiki on your server, there&#8217;s really no reason to create a new mediawiki.conf file, but instead just add it to the server block.</p>
<a href="http://technology.mattrude.com/2012/02/configuring-mediawiki-to-be-used-with-nginx/">MediaWiki Installed on a Nginx Server</a> is a post from; <a href="http://technology.mattrude.com/">Matt&#039;s Technology Blog</a> which is not allowed to be copied on other sites.]]></content:encoded>
			<wfw:commentRss>http://technology.mattrude.com/2012/02/configuring-mediawiki-to-be-used-with-nginx/feed/</wfw:commentRss>
		<slash:comments>1</slash:comments>
		</item>
		<item>
		<title>Installing WordPress on Nginx</title>
		<link>http://technology.mattrude.com/2012/02/installing-wordpress-on-nginx/</link>
		<comments>http://technology.mattrude.com/2012/02/installing-wordpress-on-nginx/#comments</comments>
		<pubDate>Sun, 05 Feb 2012 19:53:34 +0000</pubDate>
		<dc:creator>Matt Rude</dc:creator>
				<category><![CDATA[How-To's]]></category>
		<category><![CDATA[Apache]]></category>
		<category><![CDATA[Apache HTTP Server]]></category>
		<category><![CDATA[Fedora]]></category>
		<category><![CDATA[Nginx]]></category>
		<category><![CDATA[php]]></category>
		<category><![CDATA[php-fpm]]></category>
		<category><![CDATA[Server]]></category>
		<category><![CDATA[Web server]]></category>
		<category><![CDATA[WordPress]]></category>

		<guid isPermaLink="false">http://technology.mattrude.com/?p=5178</guid>
		<description><![CDATA[I, like most people, started out by using Apache and really didn&#8217;t see anything wrong with it.  It&#8217;s relatively easy to setup, it&#8217;s used by most sites so support is a snap and a default and it&#8217;s already installed on &#8230; <a href="http://technology.mattrude.com/2012/02/installing-wordpress-on-nginx/">Continue reading <span class="meta-nav">&#8594;</span></a><a href="http://technology.mattrude.com/2012/02/installing-wordpress-on-nginx/">Installing WordPress on Nginx</a> is a post from; <a href="http://technology.mattrude.com/">Matt&#039;s Technology Blog</a> which is not allowed to be copied on other sites.]]></description>
			<content:encoded><![CDATA[<p>I, like most people, started out by using <a class="zem_slink" title="Apache" href="http://en.wikipedia.org/wiki/Apache" rel="wikipedia">Apache</a> and really didn&#8217;t see anything wrong with it.  It&#8217;s relatively easy to setup, it&#8217;s used by most sites so support is a snap and a default and it&#8217;s already installed on most distributions. The thing is, it&#8217;s slow, the easy of use is paid for by speed.</p>
<p>So this is where <a class="zem_slink" title="Nginx" href="http://www.nginx.org/" rel="homepage">Nginx</a> comes in.  Nginx is not the easiest software to setup.  It requires you to tell it what different file types you will be using and how to handle them.  It requires you to tell it where scripts live and where static files live.  It also requires you to use an external php server, such as <a class="zem_slink" title="FastCGI" href="http://en.wikipedia.org/wiki/FastCGI" rel="wikipedia">FastCGI</a>.</p>
<h2>PHP-FPM Setup</h2>
<p>Nginx does not provide FastCGI for you (FastCGI is what your <a class="zem_slink" title="Web server" href="http://en.wikipedia.org/wiki/Web_server" rel="wikipedia">web server</a> uses to interact with <a class="zem_slink" title="WordPress" href="http://wordpress.org" rel="homepage">WordPress</a>’s <acronym title="PHP: Hypertext Preprocessor"><a class="zem_slink" title="PHP" href="http://en.wikipedia.org/wiki/PHP" rel="wikipedia">PHP</a></acronym> code), so you’ve got to have a way to spawn your own FastCGI processes.</p>
<p>My preferred method is using of running FastCGI is with <a title="PHP-FPM (FastCGI Process Manager) is an alternative PHP FastCGI implementation." href="http://php-fpm.org/" target="_blank">php-fpm</a>.  Since I&#8217;m using <a class="zem_slink" title="Fedora (operating system)" href="http://fedoraproject.org/" rel="homepage">Fedora</a>, and there is a <a class="zem_slink" title="Yellowdog Updater, Modified" href="http://yum.baseurl.org/" rel="homepage">yum</a> packet already built for php-fpm, it&#8217;s quick and easy to install.</p>
<p>Installing php-fpm is pretty straightforward:</p>
<pre>yum install php-fpm</pre>
<p>After installing php-fpm you have to start it. The rpm for php-fpm installs the service script for you, you only need to enable starting at boot, and start the process.</p>
<pre>chkconfig php-fpm on
service php-fpm start</pre>
<h2>Nginx</h2>
<p>The next part is to install Nginx on your server.  This is as straightforward as installing php-fpm on Fedora, when using yum.</p>
<pre>yum install nginx</pre>
<p>Once Nginx is installed, you need to set it up to server your site.</p>
<h2>Configuring Nginx for WordPress</h2>
<p>So we now have the needed software installed, next we need to set it all up.  Below is the config for a standard, simple WordPress site named <em>example.com</em>.<br />
<strong>nginx.conf:</strong></p>
<pre>
http {
    include       /etc/nginx/mime.types;
    default_type  application/octet-stream;

    log_format  main  '$remote_addr - $remote_user [$time_local] $http_host "$request" '
                      '$status $body_bytes_sent "$http_referer" '
                      '"$http_user_agent" "$http_x_forwarded_for"';

    access_log  /var/log/nginx/access.log  main;
    sendfile        on;
    #tcp_nopush     on;
    rewrite_log     on;
    keepalive_timeout  5;
    index              index.php index.html index.htm;

    # Upstream to abstract backend connection(s) for PHP.
    upstream php {
        server unix:/var/run/php-fpm.socket;
    }

    server {
        listen 80;
        server_name example.com;
        server_name www.example.com;
        root /var/www/example.com;

        if ($http_host != "example.com") {
                rewrite ^ http://example.com$request_uri permanent;
        }

        include wordpress.conf;
    }
}
</pre>
<p><strong>wordpress.conf:</strong></p>
<pre>
# WordPress single blog rules.
# Designed to be included in any server {} block.

# Deny all attempts to access hidden files such as .htaccess, .htpasswd, .DS_Store (Mac).
location ~ /\. {
        deny all;
        access_log off;
        log_not_found off;
}

# Deny access to any files with a .php extension in the uploads directory
location ~* ^/wp-content/uploads/.*.php$ {
        deny all;
        access_log off;
        log_not_found off;
}

# Deny access to any files with a .php extension in the uploads directory for multisite
location ~* /files/(.*).php$ {
        deny all;
        access_log off;
        log_not_found off;
}

# This order might seem weird - this is attempted to match last if rules below fail.
# http://wiki.nginx.org/HttpCoreModule
location / {
        try_files $uri $uri/ /index.php?$args;
}

# Add trailing slash to */wp-admin requests.
rewrite /wp-admin$ $scheme://$host$uri/ permanent;

# Directives to send expires headers and turn off 404 error logging.
location ~* \.(js|css|png|jpg|jpeg|gif|ico|ttf)$ {
        expires 180d;
        log_not_found off;
}

# Pass all .php files onto a php-fpm/php-fcgi server.
location ~ \.php$ {
        # Zero-day exploit defense.
        # http://forum.nginx.org/read.php?2,88845,page=3
        # Won't work properly (404 error) if the file is not stored on this server, which is entirely possible with php-fpm/php-fcgi.
        # Comment the 'try_files' line out if you set up php-fpm/php-fcgi on another machine.  And then cross your fingers that you won't get hacked.
        try_files $uri =404;

        fastcgi_split_path_info ^(.+\.php)(/.+)$;
        #NOTE: You should have "cgi.fix_pathinfo = 0;" in php.ini

        include fastcgi_params;
        fastcgi_index index.php;
        fastcgi_param SCRIPT_FILENAME $document_root$fastcgi_script_name;
#       fastcgi_intercept_errors on;
        fastcgi_pass php;
}
</pre>
<a href="http://technology.mattrude.com/2012/02/installing-wordpress-on-nginx/">Installing WordPress on Nginx</a> is a post from; <a href="http://technology.mattrude.com/">Matt&#039;s Technology Blog</a> which is not allowed to be copied on other sites.]]></content:encoded>
			<wfw:commentRss>http://technology.mattrude.com/2012/02/installing-wordpress-on-nginx/feed/</wfw:commentRss>
		<slash:comments>1</slash:comments>
		</item>
		<item>
		<title>Change the maximum number of mailboxes being displayed in Exchange 2010</title>
		<link>http://technology.mattrude.com/2012/02/change-the-maximum-number-of-mailboxes-being-displayed-in-exchange-2010/</link>
		<comments>http://technology.mattrude.com/2012/02/change-the-maximum-number-of-mailboxes-being-displayed-in-exchange-2010/#comments</comments>
		<pubDate>Thu, 02 Feb 2012 14:03:19 +0000</pubDate>
		<dc:creator>Matt Rude</dc:creator>
				<category><![CDATA[How-To's]]></category>
		<category><![CDATA[Email box]]></category>
		<category><![CDATA[Exchange 2010]]></category>
		<category><![CDATA[Microsoft Exchange]]></category>
		<category><![CDATA[Microsoft Exchange Server]]></category>

		<guid isPermaLink="false">http://technology.mattrude.com/?p=5259</guid>
		<description><![CDATA[Microsoft&#8217;s Exchange Management Console is clearly far from a well designed system.  Sine things are put in such abnormal locations, it seems like I spend a good part of my time, just figuring out how to do something, I could &#8230; <a href="http://technology.mattrude.com/2012/02/change-the-maximum-number-of-mailboxes-being-displayed-in-exchange-2010/">Continue reading <span class="meta-nav">&#8594;</span></a><a href="http://technology.mattrude.com/2012/02/change-the-maximum-number-of-mailboxes-being-displayed-in-exchange-2010/">Change the maximum number of mailboxes being displayed in Exchange 2010</a> is a post from; <a href="http://technology.mattrude.com/">Matt&#039;s Technology Blog</a> which is not allowed to be copied on other sites.]]></description>
			<content:encoded><![CDATA[<p>Microsoft&#8217;s Exchange Management Console is clearly far from a well designed system.  Sine things are put in such abnormal locations, it seems like I spend a good part of my time, just figuring out how to do something, I could do in my sleep with a previous version.</p>
<p>On that note, here is how to change the maximum number of recipients to display while searching in Exchange Management Console.</p>
<ol>
<li>Open the <strong>Exchange Management Console</strong></li>
<li>Expand “<strong>Recipient Configuration</strong>“</li>
<li>Expand &#8220;<strong>Mailbox</strong>&#8220;</li>
<li>On the far right hand side, within the &#8220;<strong>Action</strong>&#8221; window, choose &#8220;<strong>Modify the Maximum Number of Recipients to Display</strong>&#8220;</li>
</ol>
<a href="http://technology.mattrude.com/2012/02/change-the-maximum-number-of-mailboxes-being-displayed-in-exchange-2010/">Change the maximum number of mailboxes being displayed in Exchange 2010</a> is a post from; <a href="http://technology.mattrude.com/">Matt&#039;s Technology Blog</a> which is not allowed to be copied on other sites.]]></content:encoded>
			<wfw:commentRss>http://technology.mattrude.com/2012/02/change-the-maximum-number-of-mailboxes-being-displayed-in-exchange-2010/feed/</wfw:commentRss>
		<slash:comments>0</slash:comments>
		</item>
		<item>
		<title>Setting up CGIT to show root directories only</title>
		<link>http://technology.mattrude.com/2012/01/setting-up-cgit-to-show-root-directories-only/</link>
		<comments>http://technology.mattrude.com/2012/01/setting-up-cgit-to-show-root-directories-only/#comments</comments>
		<pubDate>Mon, 09 Jan 2012 00:42:48 +0000</pubDate>
		<dc:creator>Matt Rude</dc:creator>
				<category><![CDATA[How-To's]]></category>
		<category><![CDATA[Alias]]></category>
		<category><![CDATA[Apache]]></category>
		<category><![CDATA[Apache HTTP Server]]></category>
		<category><![CDATA[cgi script]]></category>
		<category><![CDATA[cgit]]></category>
		<category><![CDATA[Git]]></category>
		<category><![CDATA[repositories]]></category>
		<category><![CDATA[script cgi]]></category>
		<category><![CDATA[Source code]]></category>
		<category><![CDATA[Uniform Resource Locator]]></category>
		<category><![CDATA[virtualhost]]></category>
		<category><![CDATA[Web browser]]></category>
		<category><![CDATA[Web Design and Development]]></category>

		<guid isPermaLink="false">http://technology.mattrude.com/?p=5214</guid>
		<description><![CDATA[CGIT is a nice, quick, and easy way of displaying git repositories. After much fighting I figured out how to allow CGIT to display URLs such as http://code.example.com/repository.git (the git is optional). Below is the Apache config for code.example.com: Setting &#8230; <a href="http://technology.mattrude.com/2012/01/setting-up-cgit-to-show-root-directories-only/">Continue reading <span class="meta-nav">&#8594;</span></a><a href="http://technology.mattrude.com/2012/01/setting-up-cgit-to-show-root-directories-only/">Setting up CGIT to show root directories only</a> is a post from; <a href="http://technology.mattrude.com/">Matt&#039;s Technology Blog</a> which is not allowed to be copied on other sites.]]></description>
			<content:encoded><![CDATA[<p><a title="cgit" href="http://hjemli.net/git/cgit/" target="_blank">CGIT</a> is a nice, quick, and easy way of displaying <a title="git" href="http://git-scm.com/" target="_blank">git</a> repositories. After much fighting I figured out how to allow CGIT to display <a class="zem_slink" title="Uniform Resource Locator" href="http://en.wikipedia.org/wiki/Uniform_Resource_Locator" rel="wikipedia">URLs</a> such as <em>http://code.example.com/repository.git</em> (the git is optional).</p>
<p>Below is the <a title="Apache HTTP Server" href="http://httpd.apache.org/" target="_blank">Apache</a> config for code.example.com:</p>
<pre class="brush: xml; title: ; notranslate">
&lt;VirtualHost *:80&gt;
    ServerName code.example.com
    DocumentRoot /var/www/code.example.com
    CustomLog logs/code.example.com.access_log combined
    ErrorLog logs/code.example.com.error_log
    SetEnv CGIT_CONFIG          /var/www/code.example.com/cgitrc
    Alias /cgit.css             /var/www/code.example.com/cgit.css
    Alias /cgit.png             /var/www/code.example.com/cgit.png
    Alias /favicon.ico          /var/www/code.example.com/favicon.ico
    Alias /robots.txt           /var/www/code.example.com/robots.txt
    Alias /                     /var/www/code.example.com/cgit.cgi/
    &lt;Directory /var/www/code.example.com&gt;
      Options Indexes FollowSymLinks
      Options +ExecCGI
      Order allow,deny
      Allow from all
      AddHandler cgi-script .cgi
      DirectoryIndex cgit.cgi
    &lt;/Directory&gt;
&lt;/VirtualHost&gt;
</pre>
<a href="http://technology.mattrude.com/2012/01/setting-up-cgit-to-show-root-directories-only/">Setting up CGIT to show root directories only</a> is a post from; <a href="http://technology.mattrude.com/">Matt&#039;s Technology Blog</a> which is not allowed to be copied on other sites.]]></content:encoded>
			<wfw:commentRss>http://technology.mattrude.com/2012/01/setting-up-cgit-to-show-root-directories-only/feed/</wfw:commentRss>
		<slash:comments>0</slash:comments>
		</item>
		<item>
		<title>Compressing PNG file for the web</title>
		<link>http://technology.mattrude.com/2011/12/compressing-png-file-for-the-web/</link>
		<comments>http://technology.mattrude.com/2011/12/compressing-png-file-for-the-web/#comments</comments>
		<pubDate>Thu, 29 Dec 2011 16:09:57 +0000</pubDate>
		<dc:creator>Matt Rude</dc:creator>
				<category><![CDATA[How-To's]]></category>
		<category><![CDATA[egrep]]></category>
		<category><![CDATA[images on the web]]></category>
		<category><![CDATA[images web]]></category>
		<category><![CDATA[optipng]]></category>
		<category><![CDATA[png]]></category>
		<category><![CDATA[png files]]></category>
		<category><![CDATA[website]]></category>
		<category><![CDATA[WordPress]]></category>

		<guid isPermaLink="false">http://mattrudetech.wordpress.com/?p=5166</guid>
		<description><![CDATA[When using images on the web, it&#8217;s impotent to use the smallest file you can for your needs. This doesn&#8217;t mean you should use a image that is smaller then the size you wish to display it at, but to &#8230; <a href="http://technology.mattrude.com/2011/12/compressing-png-file-for-the-web/">Continue reading <span class="meta-nav">&#8594;</span></a><a href="http://technology.mattrude.com/2011/12/compressing-png-file-for-the-web/">Compressing PNG file for the web</a> is a post from; <a href="http://technology.mattrude.com/">Matt&#039;s Technology Blog</a> which is not allowed to be copied on other sites.]]></description>
			<content:encoded><![CDATA[<p>When using images on the web, it&#8217;s impotent to use the smallest file you can for your needs. This doesn&#8217;t mean you should use a image that is smaller then the size you wish to display it at, but to optimize it for the web and not send more then is needed.</p>
<p>With this goal, here is a quick way of optimizing all <a title="Portable Network Graphics" href="http://en.wikipedia.org/wiki/Portable_Network_Graphics" target="_blank">PNG</a> files in a set of directories using <a href="http://optipng.sourceforge.net/" target="_blank">optipng</a>.</p>
<pre>for a in `find /var/www/wordpress/ |egrep '*.png$'`
do
    /usr/bin/optipng $a
done</pre>
<p>Don&#8217;t worry if you already have some images that are already optimized, optipng will just skip them.</p>
<a href="http://technology.mattrude.com/2011/12/compressing-png-file-for-the-web/">Compressing PNG file for the web</a> is a post from; <a href="http://technology.mattrude.com/">Matt&#039;s Technology Blog</a> which is not allowed to be copied on other sites.]]></content:encoded>
			<wfw:commentRss>http://technology.mattrude.com/2011/12/compressing-png-file-for-the-web/feed/</wfw:commentRss>
		<slash:comments>1</slash:comments>
		</item>
		<item>
		<title>RoundCube: Error No [604]</title>
		<link>http://technology.mattrude.com/2011/12/roundcube-error-no-604/</link>
		<comments>http://technology.mattrude.com/2011/12/roundcube-error-no-604/#comments</comments>
		<pubDate>Sat, 17 Dec 2011 19:07:55 +0000</pubDate>
		<dc:creator>Matt Rude</dc:creator>
				<category><![CDATA[General]]></category>
		<category><![CDATA[config options]]></category>
		<category><![CDATA[configured]]></category>
		<category><![CDATA[Fedora]]></category>
		<category><![CDATA[memcache]]></category>
		<category><![CDATA[Memcached]]></category>
		<category><![CDATA[RoundCube]]></category>
		<category><![CDATA[session data]]></category>
		<category><![CDATA[yum]]></category>

		<guid isPermaLink="false">http://mattrudetech.wordpress.com/?p=5163</guid>
		<description><![CDATA[I recently had a client who moved RoundCube to a new server. Since the move they are receiving the below error when they go to their webmail site. SERVICE CURRENTLY NOT AVAILABLE! Error No. [604] After much digging and searching, &#8230; <a href="http://technology.mattrude.com/2011/12/roundcube-error-no-604/">Continue reading <span class="meta-nav">&#8594;</span></a><a href="http://technology.mattrude.com/2011/12/roundcube-error-no-604/">RoundCube: Error No [604]</a> is a post from; <a href="http://technology.mattrude.com/">Matt&#039;s Technology Blog</a> which is not allowed to be copied on other sites.]]></description>
			<content:encoded><![CDATA[<p style="text-align:left;">I recently had a client who moved <a title="Roundcube" href="http://roundcube.net/" target="_blank">RoundCube</a> to a new server.  Since the move they are receiving the below error when they go to their webmail site.</p>
<p style="text-align:center;">SERVICE CURRENTLY NOT AVAILABLE!<br />
Error No. [604]</p>
<p style="text-align:left;">After much digging and searching, I wasn&#8217;t coming up with much. I finely started walking threw the config file seeing what was enabled and were the different config options were pointing.  After some digging I found they had <a title="memcached" href="http://memcached.org/" target="_blank">memcache</a> configured for session data.  The <a title="php-pecl-memcache" href="http://pecl.php.net/package/memcache" target="_blank">php-pecl-memcache</a> module wasn&#8217;t installed.  I installed the module via yum, as it was a Fedora system using the below command.</p>
<pre>yum install php-pecl-memcache</pre>
<p>Since the config was still pointing at the running memcache server, the site came back up and is now working well again.</p>
<a href="http://technology.mattrude.com/2011/12/roundcube-error-no-604/">RoundCube: Error No [604]</a> is a post from; <a href="http://technology.mattrude.com/">Matt&#039;s Technology Blog</a> which is not allowed to be copied on other sites.]]></content:encoded>
			<wfw:commentRss>http://technology.mattrude.com/2011/12/roundcube-error-no-604/feed/</wfw:commentRss>
		<slash:comments>0</slash:comments>
		</item>
		<item>
		<title>Custom WordPress Cron Intervals</title>
		<link>http://technology.mattrude.com/2011/12/custom-wordpress-cron-intervals/</link>
		<comments>http://technology.mattrude.com/2011/12/custom-wordpress-cron-intervals/#comments</comments>
		<pubDate>Thu, 15 Dec 2011 01:45:49 +0000</pubDate>
		<dc:creator>Matt Rude</dc:creator>
				<category><![CDATA[General]]></category>
		<category><![CDATA[array]]></category>
		<category><![CDATA[cron]]></category>
		<category><![CDATA[hook]]></category>
		<category><![CDATA[interval]]></category>
		<category><![CDATA[intervals]]></category>
		<category><![CDATA[WordPress]]></category>

		<guid isPermaLink="false">http://technology.mattrude.com/?p=5160</guid>
		<description><![CDATA[Here’s how to have WordPress code execute on a different schedule than the default intervals of hourly, twicedaily, and daily. This specific example is for weekly execution. Taken from Viper007Bond&#8216;s post on How To Create Custom WordPress Cron Intervals. Custom &#8230; <a href="http://technology.mattrude.com/2011/12/custom-wordpress-cron-intervals/">Continue reading <span class="meta-nav">&#8594;</span></a><a href="http://technology.mattrude.com/2011/12/custom-wordpress-cron-intervals/">Custom WordPress Cron Intervals</a> is a post from; <a href="http://technology.mattrude.com/">Matt&#039;s Technology Blog</a> which is not allowed to be copied on other sites.]]></description>
			<content:encoded><![CDATA[<p>Here’s how to have WordPress code execute on a different schedule than the default intervals of <code>hourly</code>, <code>twicedaily</code>, and <code>daily</code>. This specific example is for weekly execution.</p>
<pre class="brush: php; title: ; notranslate">
&lt;?php

// Add a new interval of a week
// See http://codex.wordpress.org/Plugin_API/Filter_Reference/cron_schedules
add_filter( 'cron_schedules', 'myprefix_add_weekly_cron_schedule' );
function myprefix_add_weekly_cron_schedule( $schedules ) {
	$schedules['weekly'] = array(
		'interval' =&gt; 604800, // 1 week in seconds
		'display'  =&gt; __( 'Once Weekly' ),
	);

	return $schedules;
}

// Schedule an action if it's not already scheduled
if ( ! wp_next_scheduled( 'myprefix_my_cron_action' ) ) {
	wp_schedule_event( time(), 'weekly', 'myprefix_my_cron_action' );
}

// Hook into that action that'll fire weekly
add_action( 'myprefix_my_cron_action', 'myprefix_function_to_run' );
function myprefix_function_to_run() {
	// Add some code here
}

?&gt;
</pre>
<p><em><br />
Taken from <a title="Viper007Bond" href="http://www.viper007bond.com" target="_blank">Viper007Bond</a>&#8216;s post on <a title="How To Create Custom WordPress Cron Intervals" href="http://www.viper007bond.com/2011/12/14/how-to-create-custom-wordpress-cron-intervals/" target="_blank">How To Create Custom WordPress Cron Intervals</a>.</em></p>
<a href="http://technology.mattrude.com/2011/12/custom-wordpress-cron-intervals/">Custom WordPress Cron Intervals</a> is a post from; <a href="http://technology.mattrude.com/">Matt&#039;s Technology Blog</a> which is not allowed to be copied on other sites.]]></content:encoded>
			<wfw:commentRss>http://technology.mattrude.com/2011/12/custom-wordpress-cron-intervals/feed/</wfw:commentRss>
		<slash:comments>0</slash:comments>
		</item>
		<item>
		<title>Admin Bar API changes for 3.3</title>
		<link>http://technology.mattrude.com/2011/12/admin-bar-api-changes-for-3-3/</link>
		<comments>http://technology.mattrude.com/2011/12/admin-bar-api-changes-for-3-3/#comments</comments>
		<pubDate>Wed, 07 Dec 2011 13:34:24 +0000</pubDate>
		<dc:creator>Matt Rude</dc:creator>
				<category><![CDATA[Asides]]></category>
		<category><![CDATA[Admin Bar]]></category>
		<category><![CDATA[api]]></category>
		<category><![CDATA[nacin]]></category>
		<category><![CDATA[Release 3.3]]></category>
		<category><![CDATA[WordPress]]></category>

		<guid isPermaLink="false">http://technology.mattrude.com/?p=5153</guid>
		<description><![CDATA[Andrew Nacin wrote up a nice explanation on the changes to the WordPress Admin Bar API with the release of WordPress 3.3. Admin Bar API changes for 3.3 is a post from; Matt&#039;s Technology Blog which is not allowed to &#8230; <a href="http://technology.mattrude.com/2011/12/admin-bar-api-changes-for-3-3/">Continue reading <span class="meta-nav">&#8594;</span></a><a href="http://technology.mattrude.com/2011/12/admin-bar-api-changes-for-3-3/">Admin Bar API changes for 3.3</a> is a post from; <a href="http://technology.mattrude.com/">Matt&#039;s Technology Blog</a> which is not allowed to be copied on other sites.]]></description>
			<content:encoded><![CDATA[<p><a href="http://nacin.com/" target="_blank">Andrew Nacin</a> wrote up a nice explanation on the <a href="http://wpdevel.wordpress.com/2011/12/07/admin-bar-api-changes-in-3-3/" target="_blank">changes to the WordPress Admin Bar API</a> with the release of WordPress 3.3.</p>
<a href="http://technology.mattrude.com/2011/12/admin-bar-api-changes-for-3-3/">Admin Bar API changes for 3.3</a> is a post from; <a href="http://technology.mattrude.com/">Matt&#039;s Technology Blog</a> which is not allowed to be copied on other sites.]]></content:encoded>
			<wfw:commentRss>http://technology.mattrude.com/2011/12/admin-bar-api-changes-for-3-3/feed/</wfw:commentRss>
		<slash:comments>0</slash:comments>
		</item>
		<item>
		<title>Uploading files to Rackspace Cloud Files via the SWIFT uploader</title>
		<link>http://technology.mattrude.com/2011/12/uploading-files-to-rackspace-cloud-files-via-the-swift-uploader/</link>
		<comments>http://technology.mattrude.com/2011/12/uploading-files-to-rackspace-cloud-files-via-the-swift-uploader/#comments</comments>
		<pubDate>Wed, 07 Dec 2011 13:20:49 +0000</pubDate>
		<dc:creator>Matt Rude</dc:creator>
				<category><![CDATA[How-To's]]></category>
		<category><![CDATA[Python]]></category>
		<category><![CDATA[Computer file]]></category>
		<category><![CDATA[File Management]]></category>
		<category><![CDATA[Programming]]></category>
		<category><![CDATA[Rackspace Cloud Files]]></category>
		<category><![CDATA[Uploading and downloading]]></category>

		<guid isPermaLink="false">http://technology.mattrude.com/?p=5141</guid>
		<description><![CDATA[Rackspace Cloud Files is a simple way of backing up or storing files in the cloud.  There is no limit to the amount of data stored in the cloud, as each Gigabyte is billed at 15¢ a GB per month. &#8230; <a href="http://technology.mattrude.com/2011/12/uploading-files-to-rackspace-cloud-files-via-the-swift-uploader/">Continue reading <span class="meta-nav">&#8594;</span></a><a href="http://technology.mattrude.com/2011/12/uploading-files-to-rackspace-cloud-files-via-the-swift-uploader/">Uploading files to Rackspace Cloud Files via the SWIFT uploader</a> is a post from; <a href="http://technology.mattrude.com/">Matt&#039;s Technology Blog</a> which is not allowed to be copied on other sites.]]></description>
			<content:encoded><![CDATA[<p>Rackspace <a href="http://www.rackspace.com/cloud/cloud_hosting_products/files/" target="_blank">Cloud Files</a> is a simple way of backing up or storing files in the cloud.  There is no limit to the amount of data stored in the cloud, as each Gigabyte is billed at 15¢ a GB per month.</p>
<h3>Downloading the needed software</h3>
<p>To upload files, you will need the <a href="http://bazaar.launchpad.net/~ttx/swift/1.4.0/view/head:/bin/st" target="_blank">SWIFT</a> script written in python.</p>
<p>First start out by downloading the SWIFT script, named <em>st</em>.</p>
<pre>wget http://bazaar.launchpad.net/~ttx/swift/1.4.0/download/head:/st.py-20100712220340-zzyjabj9xczdm4cg-15/st</pre>
<p>You now need to make this file executable:</p>
<pre>chmod 755 st</pre>
<h3>Using the SWIFT uploader</h3>
<p>To list the containers in your account:</p>
<pre>./st -s -q -A https://auth.api.rackspacecloud.com/v1.0 
-U  -K  list</pre>
<p>Once you find the <a class="zem_slink" title="Containerization" href="http://en.wikipedia.org/wiki/Containerization" rel="wikipedia">container</a> you would like to use, you may then list the contents of that container as well.</p>
<pre>./st -s -q -A https://auth.api.rackspacecloud.com/v1.0 
-U  -K  list container</pre>
<p><em>Note, if you do not have a container setup yet, you may create one during the upload process.</em></p>
<a href="http://technology.mattrude.com/2011/12/uploading-files-to-rackspace-cloud-files-via-the-swift-uploader/">Uploading files to Rackspace Cloud Files via the SWIFT uploader</a> is a post from; <a href="http://technology.mattrude.com/">Matt&#039;s Technology Blog</a> which is not allowed to be copied on other sites.]]></content:encoded>
			<wfw:commentRss>http://technology.mattrude.com/2011/12/uploading-files-to-rackspace-cloud-files-via-the-swift-uploader/feed/</wfw:commentRss>
		<slash:comments>0</slash:comments>
		</item>
		<item>
		<title>Configuring WordPress to use Memcached</title>
		<link>http://technology.mattrude.com/2011/11/configuring-wordpress-to-use-memcached/</link>
		<comments>http://technology.mattrude.com/2011/11/configuring-wordpress-to-use-memcached/#comments</comments>
		<pubDate>Fri, 18 Nov 2011 03:28:54 +0000</pubDate>
		<dc:creator>Matt Rude</dc:creator>
				<category><![CDATA[How-To's]]></category>
		<category><![CDATA[Cache]]></category>
		<category><![CDATA[Fedora]]></category>
		<category><![CDATA[Memcached]]></category>
		<category><![CDATA[MySQL]]></category>
		<category><![CDATA[php]]></category>
		<category><![CDATA[Programming]]></category>
		<category><![CDATA[Server]]></category>
		<category><![CDATA[Source code]]></category>
		<category><![CDATA[SQL]]></category>
		<category><![CDATA[WordPress]]></category>

		<guid isPermaLink="false">http://technology.mattrude.com/?p=5074</guid>
		<description><![CDATA[When using WordPress self hosted software it&#8217;s generally a good idea to cache as much as possible.  Object Caching allows you store parts of the pages in memory for quicker retrieval, since the server will not need to look as much up from &#8230; <a href="http://technology.mattrude.com/2011/11/configuring-wordpress-to-use-memcached/">Continue reading <span class="meta-nav">&#8594;</span></a><a href="http://technology.mattrude.com/2011/11/configuring-wordpress-to-use-memcached/">Configuring WordPress to use Memcached</a> is a post from; <a href="http://technology.mattrude.com/">Matt&#039;s Technology Blog</a> which is not allowed to be copied on other sites.]]></description>
			<content:encoded><![CDATA[<p>When using <a class="zem_slink" title="WordPress" href="http://wordpress.org/" rel="homepage">WordPress</a> self hosted software it&#8217;s generally a good idea to cache as much as possible.  <a class="zem_slink" title="Object Cache" href="http://en.wikipedia.org/wiki/Cache" rel="wikipedia">Object Caching</a> allows you store parts of the pages in memory for quicker retrieval, since the server will not need to look as much up from the <a class="zem_slink" title="SQL" href="http://www.iso.org/iso/catalogue_detail.htm?csnumber=45498" rel="homepage">SQL database</a>.</p>
<h3>Installing the needed parts</h3>
<p>To start out, you will need to have <a title="memcached" href="http://www.memcached.org/" target="_blank">memcached</a> installed on your server. If your using <a class="zem_slink" title="Fedora (operating system)" href="http://fedoraproject.org/" rel="homepage" target="_blank">Fedora</a>, you may install memcached via <a class="zem_slink" title="Yellowdog Updater, Modified" href="http://yum.baseurl.org/" rel="homepage">Yum</a> as follows.</p>
<pre>yum -y install memcached php-pecl-memcached perl-Cache-Memcached</pre>
<h3>Configuring memcached</h3>
<p>After installing memcached you need to configure it. If working in Fedora, and using the Yum install as talked about above, you will need to change the memcached confuration by modifying it&#8217;s <em>sysconfig</em> file located at <em>/etc/sysconfig/memcached</em>.</p>
<p>A default configuration may look like this.</p>
<pre>PORT="11211"
USER="memcached"
MAXCONN="1024"
CACHESIZE="64"
OPTIONS="-l 127.0.0.1"</pre>
<p>If you would like to share this memcached server with other webservers, change the address from 127.0.0.1 to the server&#8217;s actual address.</p>
<p>To set memcached to start automatically when the server get&#8217;s rebooted, run:</p>
<pre>chkconfig memcached on</pre>
<p>And of course, don&#8217;t for get to start it</p>
<pre>service memcached start</pre>
<h3>Configuring WordPress</h3>
<p>After memcached is installed, you need to configure the WordPress side.</p>
<p>Next you should install the <a title="Memcached Object Cache WordPress Plugin" href="http://wordpress.org/extend/plugins/memcached/" target="_blank">Memcached Object Cache</a> plugin, but be careful, this is not a normal plugin.  <strong>You should not activate this plugin as you would with a normal plugin</strong>, but instead download it as you normally would, but then you need to copy the <em>object-cache.php</em> file to your <em>wp-content</em> folder.</p>
<p>From the root of your WordPress install, run the following:</p>
<pre>cp wp-content/plugins/memcached/object-cache.php wp-content/</pre>
<p>Now we need to configure WordPress to use the memcached server. Add the following near the end of your <em>wp-config.php</em> file.</p>
<pre class="brush: php; title: ; notranslate">
global $memcached_servers;
$memcached_servers = array('default' =&gt; array('127.0.0.1:11211'));
</pre>
<p>Note that were using the same server and port (127.0.0.1:11211) as was configured above while we were setting up memcached.</p>
<h3>Checking in on memcached</h3>
<p>Memcached is one of those things that just sort of runs. There&#8217;s not much direct feed back, besides the speed difference on your site.</p>
<p>One quick way is <a title="memcache-top" href="http://code.google.com/p/memcache-top/" target="_blank">memcache-top</a>. memcache-top will show you the current status of your memcached server.</p>
<p>To install, run the following.</p>
<pre class="brush: plain; title: ; notranslate">
wget http://memcache-top.googlecode.com/files/memcache-top-v0.6
chmod +x memcache-top-v0.6
./memcache-top-v0.6
</pre>
<p>Running <em>./memcache-top-v0.6</em> will assumed the default configuration we used here.</p>
<a href="http://technology.mattrude.com/2011/11/configuring-wordpress-to-use-memcached/">Configuring WordPress to use Memcached</a> is a post from; <a href="http://technology.mattrude.com/">Matt&#039;s Technology Blog</a> which is not allowed to be copied on other sites.]]></content:encoded>
			<wfw:commentRss>http://technology.mattrude.com/2011/11/configuring-wordpress-to-use-memcached/feed/</wfw:commentRss>
		<slash:comments>1</slash:comments>
		</item>
		<item>
		<title>Grant Full Control to a user&#8217;s mailbox in Exchange 2010</title>
		<link>http://technology.mattrude.com/2011/11/grant-full-control-to-a-users-mailbox-in-exchange-2010/</link>
		<comments>http://technology.mattrude.com/2011/11/grant-full-control-to-a-users-mailbox-in-exchange-2010/#comments</comments>
		<pubDate>Wed, 02 Nov 2011 20:35:05 +0000</pubDate>
		<dc:creator>Matt Rude</dc:creator>
				<category><![CDATA[How-To's]]></category>
		<category><![CDATA[Email box]]></category>
		<category><![CDATA[Exchange 2010]]></category>
		<category><![CDATA[Mailbox]]></category>
		<category><![CDATA[Microsoft Exchange]]></category>
		<category><![CDATA[Microsoft Exchange Server]]></category>
		<category><![CDATA[Microsoft Outlook]]></category>
		<category><![CDATA[User (computing)]]></category>

		<guid isPermaLink="false">http://technology.mattrude.com/?p=5030</guid>
		<description><![CDATA[To grant full control to a diffrent user&#8217;s mailbox in Exchange 2010, you will need to use the Microsoft Exchange Management Console.  After this change has been made, have the user close Outlook and reopen it, the mailbox should show &#8230; <a href="http://technology.mattrude.com/2011/11/grant-full-control-to-a-users-mailbox-in-exchange-2010/">Continue reading <span class="meta-nav">&#8594;</span></a><a href="http://technology.mattrude.com/2011/11/grant-full-control-to-a-users-mailbox-in-exchange-2010/">Grant Full Control to a user&#8217;s mailbox in Exchange 2010</a> is a post from; <a href="http://technology.mattrude.com/">Matt&#039;s Technology Blog</a> which is not allowed to be copied on other sites.]]></description>
			<content:encoded><![CDATA[<p>To grant full control to a diffrent user&#8217;s mailbox in <a class="zem_slink" title="Microsoft Exchange Server" href="http://en.wikipedia.org/wiki/Microsoft_Exchange_Server" rel="wikipedia">Exchange 2010</a>, you will need to use the Microsoft Exchange Management Console.  After this change has been made, have the user close <a class="zem_slink" title="Microsoft Outlook" href="http://en.wikipedia.org/wiki/Microsoft_Outlook" rel="wikipedia">Outlook</a> and reopen it, the mailbox should show in the left hand side, without you having to manually add it to Outlook.</p>
<p>Below will allow another user to &#8216;Send As&#8217; the first user and read/modify the their mail.</p>
<ol>
<li>Open the <strong>Exchange Management Console</strong></li>
<li>Expand &#8220;<strong>Recipient Configuration</strong>&#8220;</li>
<li>Right mouse click on &#8220;<strong>Mailbox</strong>&#8221; and choose find from the list.</li>
<li>Find the user you would like to grant permissions for (<em>ie: the mailbox of the user who will have the messages sent at</em>).</li>
<li>Right mouse click on the user and choose &#8220;<strong>Manage Full Access Permissions</strong>&#8220;</li>
<li>Add the user who will be able to send as the first user to this list.</li>
</ol>
<div><span class="Apple-style-span" style="font-size:14px;line-height:23px;">The mailbox should automatically now show in Outlook after it has been restarted.</span></div>
<a href="http://technology.mattrude.com/2011/11/grant-full-control-to-a-users-mailbox-in-exchange-2010/">Grant Full Control to a user&#8217;s mailbox in Exchange 2010</a> is a post from; <a href="http://technology.mattrude.com/">Matt&#039;s Technology Blog</a> which is not allowed to be copied on other sites.]]></content:encoded>
			<wfw:commentRss>http://technology.mattrude.com/2011/11/grant-full-control-to-a-users-mailbox-in-exchange-2010/feed/</wfw:commentRss>
		<slash:comments>0</slash:comments>
		</item>
		<item>
		<title>Importing a Subversion repo into Git</title>
		<link>http://technology.mattrude.com/2011/10/importing-a-svn-repo-into-git/</link>
		<comments>http://technology.mattrude.com/2011/10/importing-a-svn-repo-into-git/#comments</comments>
		<pubDate>Fri, 14 Oct 2011 01:41:17 +0000</pubDate>
		<dc:creator>Matt Rude</dc:creator>
				<category><![CDATA[How-To's]]></category>
		<category><![CDATA[awk print]]></category>
		<category><![CDATA[Git]]></category>
		<category><![CDATA[remotes]]></category>
		<category><![CDATA[repack]]></category>
		<category><![CDATA[Subversion]]></category>
		<category><![CDATA[svn]]></category>
		<category><![CDATA[svn import]]></category>

		<guid isPermaLink="false">http://technology.mattrude.com/?p=5017</guid>
		<description><![CDATA[To import a svn repo create a new git repo and run Then once your done, repack it. SVN Branches If you wish to also map your branches, you may run something like the following SVN Tags From a checked &#8230; <a href="http://technology.mattrude.com/2011/10/importing-a-svn-repo-into-git/">Continue reading <span class="meta-nav">&#8594;</span></a><a href="http://technology.mattrude.com/2011/10/importing-a-svn-repo-into-git/">Importing a Subversion repo into Git</a> is a post from; <a href="http://technology.mattrude.com/">Matt&#039;s Technology Blog</a> which is not allowed to be copied on other sites.]]></description>
			<content:encoded><![CDATA[<p>To import a svn repo create a new git repo and run</p>
<pre class="brush: bash; title: ; notranslate">git svn clone http://svn.foo.com/svn/project/ project -s</pre>
<p>Then once your done, repack it.</p>
<pre class="brush: bash; title: ; notranslate">git gc project/</pre>
<h3>SVN Branches</h3>
<p>If you wish to also map your branches, you may run something like the following</p>
<pre class="brush: bash; title: ; notranslate">
for a in `cat .git/packed-refs |grep remotes |grep -v pack-refs |grep -v tags |grep -v trunk |grep -v '@'|awk '{print $2}'`
 do
   b=`echo &quot;$a&quot; |sed 's/// /g' |awk '{print $3}'`
   git branch -t $b $a
 done
</pre>
<h3>SVN Tags</h3>
<p>From a checked out SVN directory, the following will give you a list of all the users in the SVN log. You will still need to updated this list before you may use it.</p>
<pre class="brush: bash; title: ; notranslate">
for a in `cat .git/packed-refs |grep remotes |grep tags |grep -v '@' |awk '{print $2}'`
 do
   b=`echo &quot;$a&quot; |sed 's/// /g' |awk '{print $4}'`
   echo &quot;creating tag $b&quot;
   git tag -a $b -m &quot;Converting SVN tag to GIT tag&quot; $a
   sleep 5
 done
</pre>
<h3>SVN Authors list</h3>
<pre class="brush: bash; title: ; notranslate">
#!/usr/bin/env bash
authors=$(svn log -q | grep -e '^r' | awk 'BEGIN { FS = &quot;|&quot; } ; { print $2 }' | sort | uniq)
for author in ${authors}; do
   echo &quot;${author} = ${author} &quot;;
done
</pre>
<p>Once you have your list built, need to add it to your .git config. I store my authors file in the .git directory.</p>
<pre class="brush: bash; title: ; notranslate">
[svn]
     authorsfile = .git/authors
</pre>
<h3>GIT/SVN Notes</h3>
<ul>
<li><a href="http://blog.tsunanet.net/2007/07/learning-git-svn-in-5min.html" target="_blank">http://tsunanet.blogspot.com/2007/07/learning-git-svn-in-5min.html</a></li>
<li>http://djwonk.com/blog/2008/05/09/cleanly-import-svn-repository-into-git/</li>
</ul>
<a href="http://technology.mattrude.com/2011/10/importing-a-svn-repo-into-git/">Importing a Subversion repo into Git</a> is a post from; <a href="http://technology.mattrude.com/">Matt&#039;s Technology Blog</a> which is not allowed to be copied on other sites.]]></content:encoded>
			<wfw:commentRss>http://technology.mattrude.com/2011/10/importing-a-svn-repo-into-git/feed/</wfw:commentRss>
		<slash:comments>0</slash:comments>
		</item>
		<item>
		<title>Git: Creating a new user for git secure remote push</title>
		<link>http://technology.mattrude.com/2011/10/git-creating-a-new-user-for-git-secure-remote-push/</link>
		<comments>http://technology.mattrude.com/2011/10/git-creating-a-new-user-for-git-secure-remote-push/#comments</comments>
		<pubDate>Fri, 14 Oct 2011 01:16:12 +0000</pubDate>
		<dc:creator>Matt Rude</dc:creator>
				<category><![CDATA[How-To's]]></category>
		<category><![CDATA[Git]]></category>
		<category><![CDATA[kelsey]]></category>
		<category><![CDATA[running start]]></category>
		<category><![CDATA[sourcecode]]></category>
		<category><![CDATA[SSH]]></category>
		<category><![CDATA[usr bin]]></category>

		<guid isPermaLink="false">http://technology.mattrude.com/?p=5013</guid>
		<description><![CDATA[Here&#8217;s a quick how-to to create a new user for git. The assumes you already have a functioning secure git server already running. Start out by creating the user, note were changing the shell to git&#8217;s own git-shell. After the &#8230; <a href="http://technology.mattrude.com/2011/10/git-creating-a-new-user-for-git-secure-remote-push/">Continue reading <span class="meta-nav">&#8594;</span></a><a href="http://technology.mattrude.com/2011/10/git-creating-a-new-user-for-git-secure-remote-push/">Git: Creating a new user for git secure remote push</a> is a post from; <a href="http://technology.mattrude.com/">Matt&#039;s Technology Blog</a> which is not allowed to be copied on other sites.]]></description>
			<content:encoded><![CDATA[<p>Here&#8217;s a quick how-to to create a new user for git. The assumes you already have a functioning secure git server already running.</p>
<p>Start out by creating the user, note were changing the shell to git&#8217;s own <em>git-shell</em>.</p>
<pre class="brush: bash; title: ; notranslate">
adduser -b /home/git -g git -m -s /usr/bin/git-shell kelsey -p
</pre>
<p>After the user is created, create a openssh key for the new user.</p>
<pre class="brush: bash; title: ; notranslate">
mkdir /home/git/kelsey/.ssh
ssh-keygen -n kelsey -t dsa -f kelsey/.ssh/id_dsa
</pre>
<p>And lastly secure the directory back down.</p>
<pre class="brush: bash; title: ; notranslate">
chown -R kelsey:kelsey /home/git/kelsey
chmod -R u=rwX,go-rwx /home/git/kelsey/.ssh
chmod +rw /home/git/kelsey/.ssh/id_dsa.pub
</pre>
<p>Kelsey will now be able to push git updates to her branches.</p>
<a href="http://technology.mattrude.com/2011/10/git-creating-a-new-user-for-git-secure-remote-push/">Git: Creating a new user for git secure remote push</a> is a post from; <a href="http://technology.mattrude.com/">Matt&#039;s Technology Blog</a> which is not allowed to be copied on other sites.]]></content:encoded>
			<wfw:commentRss>http://technology.mattrude.com/2011/10/git-creating-a-new-user-for-git-secure-remote-push/feed/</wfw:commentRss>
		<slash:comments>0</slash:comments>
		</item>
		<item>
		<title>Configuring Cisco Devices To Use An NTP Server</title>
		<link>http://technology.mattrude.com/2011/10/configuring-cisco-devices-to-use-an-ntp-server/</link>
		<comments>http://technology.mattrude.com/2011/10/configuring-cisco-devices-to-use-an-ntp-server/#comments</comments>
		<pubDate>Mon, 10 Oct 2011 22:30:27 +0000</pubDate>
		<dc:creator>Matt Rude</dc:creator>
				<category><![CDATA[How-To's]]></category>
		<category><![CDATA[cisco]]></category>
		<category><![CDATA[hardware clock]]></category>
		<category><![CDATA[NTP]]></category>
		<category><![CDATA[ntp server]]></category>
		<category><![CDATA[ntp servers]]></category>
		<category><![CDATA[periodic intervals]]></category>
		<category><![CDATA[software clock]]></category>

		<guid isPermaLink="false">http://technology.mattrude.com/?p=4999</guid>
		<description><![CDATA[You can use NTP to synchronize time on a variety of devices including networking equipment. I have included the necessary NTP commands for a variety of Cisco Systems products because it is one of the most popular manufacturers of networking &#8230; <a href="http://technology.mattrude.com/2011/10/configuring-cisco-devices-to-use-an-ntp-server/">Continue reading <span class="meta-nav">&#8594;</span></a><a href="http://technology.mattrude.com/2011/10/configuring-cisco-devices-to-use-an-ntp-server/">Configuring Cisco Devices To Use An NTP Server</a> is a post from; <a href="http://technology.mattrude.com/">Matt&#039;s Technology Blog</a> which is not allowed to be copied on other sites.]]></description>
			<content:encoded><![CDATA[<p>You can use NTP to synchronize time on a variety of devices including networking equipment. I have included the necessary NTP commands for a variety of Cisco Systems products because it is one of the most popular manufacturers of networking equipment and would feature in the overall architectures of many home office/small office (SOHO) environments and corporate departments.</p>
<h3>Cisco IOS</h3>
<p>To make your router synchronize with NTP servers with IP addresses 192.168.1.100 and 192.168.1.201, use the commands:</p>
<pre class="brush: bash; title: ; notranslate">
ciscorouter&gt; enable
password: *********
ciscorouter# config t
ciscorouter(config)# ntp update-calendar
ciscorouter(config)# ntp server 192.168.1.100
ciscorouter(config)# ntp server 192.168.1.201
ciscorouter(config)# exit
ciscorouter# wr mem
</pre>
<p>The ntp server command forms a server association with another system, and ntp update-calendar configures the system to update its hardware clock from the software clock at periodic intervals.</p>
<h3>CATOS</h3>
<p>To make your router synchronize with NTP servers with IP addresses 192.168.1.100 and 192.168.1.201, use the commands:</p>
<pre class="brush: bash; title: ; notranslate">
ciscoswitch&gt; enable
password: *********
ciscoswitch# set ntp client enable
ciscoswitch# ntp server 192.168.1.100
ciscoswitch# ntp server 192.168.1.201
ciscoswitch# exit
</pre>
<p>The ntp server command forms a server association with another system, and set ntp client enable activates the NTP client.</p>
<a href="http://technology.mattrude.com/2011/10/configuring-cisco-devices-to-use-an-ntp-server/">Configuring Cisco Devices To Use An NTP Server</a> is a post from; <a href="http://technology.mattrude.com/">Matt&#039;s Technology Blog</a> which is not allowed to be copied on other sites.]]></content:encoded>
			<wfw:commentRss>http://technology.mattrude.com/2011/10/configuring-cisco-devices-to-use-an-ntp-server/feed/</wfw:commentRss>
		<slash:comments>0</slash:comments>
		</item>
		<item>
		<title>Git Commit eMail Notifications</title>
		<link>http://technology.mattrude.com/2011/10/git-commit-email-notifications-2/</link>
		<comments>http://technology.mattrude.com/2011/10/git-commit-email-notifications-2/#comments</comments>
		<pubDate>Sun, 09 Oct 2011 16:55:30 +0000</pubDate>
		<dc:creator>Matt Rude</dc:creator>
				<category><![CDATA[PHP]]></category>
		<category><![CDATA[Scripts]]></category>
		<category><![CDATA[email]]></category>
		<category><![CDATA[Git]]></category>
		<category><![CDATA[Postfix]]></category>
		<category><![CDATA[Postfix (software)]]></category>
		<category><![CDATA[Ruby]]></category>

		<guid isPermaLink="false">http://technology.mattrude.com/?p=4998</guid>
		<description><![CDATA[Git&#8217;s Native eMail Notifier From the repository you wish to send email on commits. Git Commit Notifier This &#8216;plugin&#8217; will allow you to send an email every time a commit is committed to the repository. You may use this on &#8230; <a href="http://technology.mattrude.com/2011/10/git-commit-email-notifications-2/">Continue reading <span class="meta-nav">&#8594;</span></a><a href="http://technology.mattrude.com/2011/10/git-commit-email-notifications-2/">Git Commit eMail Notifications</a> is a post from; <a href="http://technology.mattrude.com/">Matt&#039;s Technology Blog</a> which is not allowed to be copied on other sites.]]></description>
			<content:encoded><![CDATA[<h2>Git&#8217;s Native eMail Notifier</h2>
<p>From the repository you wish to send email on commits.</p>
<pre class="brush: bash; title: ; notranslate">
cd .git/hooks
mv post-receive post-receive.bkp
ln -s /usr/share/git-core/contrib/hooks/post-receive-email post-receive git config hooks.mailinglist &quot;mailinglist@example.com&quot;
git config hooks.emailprefix &quot;[SUBJECT PREFIX] &quot; # note the trailing space </pre>
<h2>Git Commit Notifier</h2>
<p>This &#8216;plugin&#8217; will allow you to send an email every time a commit is committed to the repository. You may use this on the central repository to keep everyone following the project up to date.</p>
<ul>
<li>The source may also be downloaded at <a href="https://github.com/bitboxer/git-commit-notifier">http://github.com/bitboxer/git-commit-notifier</a></li>
</ul>
<p>To use this plugin, you first need to compile the script, then add the config information to each repository you wish to use it on.</p>
<h3>To Install Git Commit Notifier</h3>
<p>On <a href="http://fedoraproject.org">Fedora</a> 12 you first need to install Ruby and a few other dependencies. After you download the needed dependencies, you may compile the script.
<pre class="brush: bash; title: ; notranslate">
yum -y install ruby ruby-devel rubygems hpricot rubygem-hpricott
gem install git-commit-notifier
</pre>
<h3>To Configure Git Commit Notifier</h3>
<p>In your repository&#8217;s <code>.git/hooks</code> folder or if it&#8217;s a &#8220;bare&#8221; repository, just the hooks folder. Create a file named<br />
<code>post-receive</code> with the following content.</p>
<pre class="brush: bash; title: ; notranslate">
#!/bin/sh
git-commit-notifier ../git-commit-notifier.yml
</pre>
<p>Once you have saved the file, you need to make it executable.
<pre class="brush: bash; title: ; notranslate">
chmod 775 post-receive
</pre>
<p>After you have made the hook executable, check up one directory to the repository&#8217;s .git directory. From here you need to create and modify your git-commit-notifier&#8217;s config file. Start out by creating a file named <code>git-commit-notifier.yml</code>, and copy the below config to it.</p>
<h3>Git Commit Notifier Config File</h3>
<pre class="brush: bash; title: ; notranslate">
# The recipient for the commit:
mailinglist: developers@example.com

# set to true if you want to ignore empty merge messages
ignore_merge: false

# Optional parameter for the subject-line of the mail
# emailprefix: GIT

# Decorate files with link to a webview. Possible values: none or gitweb link_files: none

# select the delivery method: smtp or sendmail
delivery_method: sendmail

# settings for the smtp server
smtp_server:
address: localhost
port: 25
domain: localhost
user_name: user@localhost
password: password
authentication: plain
enable_tls: false

# settings for sendmail
sendmail_options:
location: /usr/sbin/sendmail
arguments: -i -t

# If link_files is set to &quot;gitweb&quot;, you need to configure the path to your gitweb
# instance and the project name.
gitweb:
path: &lt;a href=&quot;http://developerserver/path_to_gitweb&quot;&gt;http://developerserver/path_to_gitweb&lt;/a&gt;
project: test.git
</pre>
<a href="http://technology.mattrude.com/2011/10/git-commit-email-notifications-2/">Git Commit eMail Notifications</a> is a post from; <a href="http://technology.mattrude.com/">Matt&#039;s Technology Blog</a> which is not allowed to be copied on other sites.]]></content:encoded>
			<wfw:commentRss>http://technology.mattrude.com/2011/10/git-commit-email-notifications-2/feed/</wfw:commentRss>
		<slash:comments>4</slash:comments>
		</item>
		<item>
		<title>WordPress Sitemap Generator Plugin</title>
		<link>http://technology.mattrude.com/2011/10/wordpress-sitemap-generator-plugin-2/</link>
		<comments>http://technology.mattrude.com/2011/10/wordpress-sitemap-generator-plugin-2/#comments</comments>
		<pubDate>Fri, 07 Oct 2011 18:08:02 +0000</pubDate>
		<dc:creator>Matt Rude</dc:creator>
				<category><![CDATA[Plugins]]></category>
		<category><![CDATA[WordPress]]></category>
		<category><![CDATA[Site Management]]></category>
		<category><![CDATA[website]]></category>
		<category><![CDATA[WordPress Plugin]]></category>

		<guid isPermaLink="false">http://technology.mattrude.com/?p=3165</guid>
		<description><![CDATA[This plugin will create a sitemap for your WordPress site (http://example.com/sitemap.xml). This was originally created for a multi-site setup, but it works fine on a single site install as well. There is no &#8216;User Interface&#8217; to speak of with this &#8230; <a href="http://technology.mattrude.com/2011/10/wordpress-sitemap-generator-plugin-2/">Continue reading <span class="meta-nav">&#8594;</span></a><a href="http://technology.mattrude.com/2011/10/wordpress-sitemap-generator-plugin-2/">WordPress Sitemap Generator Plugin</a> is a post from; <a href="http://technology.mattrude.com/">Matt&#039;s Technology Blog</a> which is not allowed to be copied on other sites.]]></description>
			<content:encoded><![CDATA[<p>This plugin will create a sitemap for your WordPress site (<code>http://example.com/sitemap.xml</code>). This was originally created for a multi-site setup, but it works fine on a single site install as well. There is no &#8216;User Interface&#8217; to speak of with this plugin, just drop in place.</p>
<p>You may also download this code via it&#8217;s <a href="https://github.com/mattrude/wp-plugin-sitemap-generator">github repository</a>:</p>
<ul>
<li>Version: <a href="http://cloud.github.com/downloads/mattrude/wp-plugin-sitemap-generator/sitemap-generator.v1.0.zip">1.0</a></li>
</ul>
<p>First, create a file named <code>sitemap-generator.php</code> in your <code>mu-plugins</code> directory, (or your <code>plugins</code> directory if your using a single install WordPress setup) and past the below into it.</p>
<pre class="brush: php; title: ; notranslate">
&lt;?php
/*
Plugin Name: Sitemap Generator
Plugin URI: http://technology.mattrude.com/2011/10/07/wordpress-sitemap-generator-plugin/
Description: Automatic generate standard XML sitemap (http://example.com/sitemap.xml) that supports the protocol including Google, Yahoo, MSN, Ask.com, and others. No files stored on your disk, the sitemap.xml file is generate as needed, like your feeds.
Version: 1.0
Author: Matt Rude
Author URI: http://mattrude.com/
*/

function sitemap_flush_rules() {
        global $wp_rewrite;
        $wp_rewrite-&amp;gt;flush_rules();
}

add_action('init', 'sitemap_flush_rules');

function xml_feed_rewrite($wp_rewrite) {
        $feed_rules = array(
                '.*sitemap.xml$' =&amp;gt; 'index.php?feed=sitemap'
        );

        $wp_rewrite-&amp;gt;rules = $feed_rules + $wp_rewrite-&amp;gt;rules;
}

add_filter('generate_rewrite_rules', 'xml_feed_rewrite');

function do_feed_sitemap() {
        $template_dir = dirname(__FILE__) . '/templates';
        load_template( $template_dir . '/feed-sitemap.php' );
}

add_action('do_feed_sitemap', 'do_feed_sitemap', 10, 1);

?&gt;
</pre>
<p>Next, create a new directory named <code>templates</code> and past the below in a file named <code>feed-sitemap.php</code> in it.</p>
<pre class="brush: php; title: ; notranslate">
&lt;?php
/*
Plugin Name: Sitemap Generator
Plugin URI: http://technology.mattrude.com/projects/sitemap-wp-plugin/
Description: Automatic generate standard XML sitemap (http://example.com/sitemap.xml) that supports the protocol including Google, Yahoo, MSN, Ask.com, and others. No files stored on your disk, the sitemap.xml file is generate as needed, like your feeds.
Version: 1.1
Author: Matt Rude
Author URI: http://mattrude.com/
*/

function sitemap_flush_rules() {
        global $wp_rewrite;
        $wp_rewrite-&gt;flush_rules();
}

add_action('init', 'sitemap_flush_rules');

function sitemap_no_trailing_slash( $redirect_url ) {
    if ( is_feed() &amp;&amp; strpos( $redirect_url, 'sitemap.xml/' ) !== FALSE )
		return;

    return $redirect_url;
}
add_filter( 'redirect_canonical', 'sitemap_no_trailing_slash' );

function xml_feed_rewrite($wp_rewrite) {
        $feed_rules = array(
                '.*sitemap.xml$' =&gt; 'index.php?feed=sitemap'
        );

        $wp_rewrite-&gt;rules = $feed_rules + $wp_rewrite-&gt;rules;
}

add_filter('generate_rewrite_rules', 'xml_feed_rewrite');

function do_feed_sitemap() {
        $template_dir = dirname(__FILE__) . '/templates';
        load_template( $template_dir . '/feed-sitemap.php' );
}

add_action('do_feed_sitemap', 'do_feed_sitemap', 10, 1);

?&gt;
</pre>
<p>Next, create a new directory named <code>templates</code> and past the below in a file named <code>feed-sitemap.php</code> in it.</p>
<pre class="brush: php; title: ; notranslate">
&lt;?php
/**
 * XML Sitemap Feed Template for displaying XML Sitemap Posts feed.
 */

//header('Content-Type: text/xml; charset=' . get_option('blog_charset'), true);

echo '&lt;?xml version=&quot;1.0&quot; encoding=&quot;'.get_option('blog_charset').'&quot;?'.'&gt;'; ?&gt;

&lt;urlset xmlns=&quot;http://www.sitemaps.org/schemas/sitemap/0.9&quot;
        xmlns:image=&quot;http://www.google.com/schemas/sitemap-image/1.1&quot;&gt;

        &lt;!-- Main Site --&gt;

        &lt;url&gt;
                &lt;loc&gt;&lt;?php bloginfo_rss('url') ?&gt;&lt;/loc&gt;
                &lt;lastmod&gt;&lt;?php echo mysql2date('Y-m-d\TH:i:s\Z', get_lastpostmodified('GMT'), false); ?&gt;&lt;/lastmod&gt;
                &lt;changefreq&gt;daily&lt;/changefreq&gt;
                &lt;priority&gt;0.8&lt;/priority&gt;
        &lt;/url&gt;

        &lt;!-- Site Pages --&gt;

&lt;?php
        $args = array(
                'post_type' =&gt; 'page',
                'numberposts' =&gt; 100,
                'status' =&gt; 'publish',
                'orderby' =&gt; 'date',
                'order' =&gt; 'DESC'
        );
        $post_ids = get_posts($args);

        if ($post_ids) {
                foreach ($post_ids as $post) { ?&gt;
        &lt;url&gt;
                &lt;loc&gt;&lt;?php the_permalink_rss() ?&gt;&lt;/loc&gt;
                &lt;lastmod&gt;&lt;?php echo mysql2date('Y-m-d\TH:i:s\Z', get_post_time('Y-m-d H:i:s', true), false); ?&gt;&lt;/lastmod&gt;
                &lt;changefreq&gt;monthly&lt;/changefreq&gt;
                &lt;priority&gt;0.7&lt;/priority&gt;
        &lt;/url&gt;
&lt;?php
 } }
?&gt;

        &lt;!-- Site Posts --&gt;

&lt;?php
        $args = array(
                'post_type' =&gt; 'post',
                'numberposts' =&gt; 100,
                'post_status' =&gt; 'publish',
                'orderby' =&gt; 'date',
                'order' =&gt; 'DESC'
        );
        $post_ids = get_posts($args);

        if ($post_ids) {
                foreach ($post_ids as $post) { ?&gt;
        &lt;url&gt;
                &lt;loc&gt;&lt;?php the_permalink_rss() ?&gt;&lt;/loc&gt;
                &lt;lastmod&gt;&lt;?php echo mysql2date('Y-m-d\TH:i:s\Z', get_post_time('Y-m-d H:i:s', true), false); ?&gt;&lt;/lastmod&gt;
                &lt;changefreq&gt;monthly&lt;/changefreq&gt;
                &lt;priority&gt;0.5&lt;/priority&gt;
&lt;?php
        $args2 = array(
                'post_type' =&gt; 'attachment',
                'numberposts' =&gt; 200,
                'post_parent' =&gt; $post-&gt;ID,
                'post_mime_type' =&gt; 'image',
                'orderby' =&gt; 'date',
                'order' =&gt; 'DESC'
        );
        $images = get_posts($args2);
        if ($images) {
                foreach ($images as $post) { ?&gt;
                &lt;image:image&gt;
                        &lt;image:loc&gt;&lt;?php echo wp_get_attachment_url(); ?&gt;&lt;/image:loc&gt;
&lt;?php if ( !empty($post-&gt;post_excerpt) ) echo '                 &lt;image:caption&gt;' . esc_html($post-&gt;post_excerpt, 1) . '&lt;/image:caption&gt;
'; ?&gt;
                        &lt;image:title&gt;&lt;?php echo esc_html($post-&gt;post_title, 1) ?&gt;&lt;/image:title&gt;
                &lt;/image:image&gt;
&lt;?php } } ?&gt;
        &lt;/url&gt;
&lt;?php
                }
        }
?&gt;
&lt;/urlset&gt;
</pre>
<a href="http://technology.mattrude.com/2011/10/wordpress-sitemap-generator-plugin-2/">WordPress Sitemap Generator Plugin</a> is a post from; <a href="http://technology.mattrude.com/">Matt&#039;s Technology Blog</a> which is not allowed to be copied on other sites.]]></content:encoded>
			<wfw:commentRss>http://technology.mattrude.com/2011/10/wordpress-sitemap-generator-plugin-2/feed/</wfw:commentRss>
		<slash:comments>4</slash:comments>
		</item>
		<item>
		<title>WordPress: Disabling Plugin Stylesheet</title>
		<link>http://technology.mattrude.com/2011/10/disabling-plugin-stylesheet-2/</link>
		<comments>http://technology.mattrude.com/2011/10/disabling-plugin-stylesheet-2/#comments</comments>
		<pubDate>Fri, 07 Oct 2011 17:45:39 +0000</pubDate>
		<dc:creator>Matt Rude</dc:creator>
				<category><![CDATA[Plugins]]></category>
		<category><![CDATA[WordPress]]></category>
		<category><![CDATA[Cascading Style Sheets]]></category>
		<category><![CDATA[Hypertext Transfer Protocol]]></category>
		<category><![CDATA[JavaScript]]></category>
		<category><![CDATA[Publishers]]></category>
		<category><![CDATA[Tools]]></category>
		<category><![CDATA[WordPress Plugin Directory]]></category>

		<guid isPermaLink="false">http://devel.mattrude.com/?p=38</guid>
		<description><![CDATA[You must have seen that WordPress plugins can slow your site down with additional HTTP Requests such as adding their own stylesheet. For advanced users, who are adding custom styles for the announcement, you do not need to have an &#8230; <a href="http://technology.mattrude.com/2011/10/disabling-plugin-stylesheet-2/">Continue reading <span class="meta-nav">&#8594;</span></a><a href="http://technology.mattrude.com/2011/10/disabling-plugin-stylesheet-2/">WordPress: Disabling Plugin Stylesheet</a> is a post from; <a href="http://technology.mattrude.com/">Matt&#039;s Technology Blog</a> which is not allowed to be copied on other sites.]]></description>
			<content:encoded><![CDATA[<p>You must have seen that WordPress plugins can slow your site down with additional HTTP Requests such as adding their own stylesheet. For advanced users, who are adding custom styles for the announcement, you do not need to have an additional HTTP request for a useless stylesheet. Then add the following function in your theme’s <em>functions.php</em> file:</p>
<pre class="brush: php; title: ; notranslate">
&lt;?php
add_action( 'wp_print_styles', 'my_deregister_styles', 100 );
    function my_deregister_styles() {
    wp_deregister_style( 'ninja-annc-css' );
}
?&gt;
</pre>
<a href="http://technology.mattrude.com/2011/10/disabling-plugin-stylesheet-2/">WordPress: Disabling Plugin Stylesheet</a> is a post from; <a href="http://technology.mattrude.com/">Matt&#039;s Technology Blog</a> which is not allowed to be copied on other sites.]]></content:encoded>
			<wfw:commentRss>http://technology.mattrude.com/2011/10/disabling-plugin-stylesheet-2/feed/</wfw:commentRss>
		<slash:comments>0</slash:comments>
		</item>
		<item>
		<title>Origo a 3D printer for everyone</title>
		<link>http://technology.mattrude.com/2011/09/4978/</link>
		<comments>http://technology.mattrude.com/2011/09/4978/#comments</comments>
		<pubDate>Sat, 24 Sep 2011 19:33:47 +0000</pubDate>
		<dc:creator>Matt Rude</dc:creator>
				<category><![CDATA[General]]></category>

		<guid isPermaLink="false">http://technology.mattrude.com/2011/09/24/4978/</guid>
		<description><![CDATA[Origo a 3D printer for everyone is a post from; Matt&#039;s Technology Blog which is not allowed to be copied on other sites.<a href="http://technology.mattrude.com/2011/09/4978/">Origo a 3D printer for everyone</a> is a post from; <a href="http://technology.mattrude.com/">Matt&#039;s Technology Blog</a> which is not allowed to be copied on other sites.]]></description>
			<content:encoded><![CDATA[<a href="http://technology.mattrude.com/2011/09/4978/">Origo a 3D printer for everyone</a> is a post from; <a href="http://technology.mattrude.com/">Matt&#039;s Technology Blog</a> which is not allowed to be copied on other sites.]]></content:encoded>
			<wfw:commentRss>http://technology.mattrude.com/2011/09/4978/feed/</wfw:commentRss>
		<slash:comments>0</slash:comments>
		</item>
		<item>
		<title>Dovecot v2.1+ Statistics</title>
		<link>http://technology.mattrude.com/2011/09/dovecot-v2-1-statistics/</link>
		<comments>http://technology.mattrude.com/2011/09/dovecot-v2-1-statistics/#comments</comments>
		<pubDate>Fri, 23 Sep 2011 22:46:22 +0000</pubDate>
		<dc:creator>Matt Rude</dc:creator>
				<category><![CDATA[How-To's]]></category>
		<category><![CDATA[Dovecot]]></category>
		<category><![CDATA[email]]></category>
		<category><![CDATA[Internet Message Access Protocol]]></category>
		<category><![CDATA[Internet Protocol]]></category>
		<category><![CDATA[Mail]]></category>
		<category><![CDATA[SQL]]></category>
		<category><![CDATA[Stat (Unix)]]></category>
		<category><![CDATA[Statistics]]></category>
		<category><![CDATA[User (computing)]]></category>

		<guid isPermaLink="false">http://technology.mattrude.com/?p=4936</guid>
		<description><![CDATA[There are different &#8220;zoom levels&#8221; you may use to view the following statistics: command: Per-IMAP command session: Per IMAP/POP3 connection user: Per user (all of user&#8217;s sessions summed up) domain: Per domain (all of domain&#8217;s users summed up) ip: Per &#8230; <a href="http://technology.mattrude.com/2011/09/dovecot-v2-1-statistics/">Continue reading <span class="meta-nav">&#8594;</span></a><a href="http://technology.mattrude.com/2011/09/dovecot-v2-1-statistics/">Dovecot v2.1+ Statistics</a> is a post from; <a href="http://technology.mattrude.com/">Matt&#039;s Technology Blog</a> which is not allowed to be copied on other sites.]]></description>
			<content:encoded><![CDATA[<p>There are different &#8220;zoom levels&#8221; you may use to view the following <a class="zem_slink" title="Statistics" href="http://en.wikipedia.org/wiki/Statistics" rel="wikipedia">statistics</a>:</p>
<ul>
<li>command: Per-<a class="zem_slink" title="Internet Message Access Protocol" href="http://en.wikipedia.org/wiki/Internet_Message_Access_Protocol" rel="wikipedia">IMAP</a> command</li>
<li>session: Per IMAP/POP3 connection</li>
<li>user: Per user (all of user&#8217;s sessions summed up)</li>
<li>domain: Per domain (all of domain&#8217;s users summed up)</li>
<li>ip: Per IP address (all sessions from the IP summed up)</li>
</ul>
<h3>Basic Configuration</h3>
<pre class="brush: php; title: ; notranslate">mail_plugins = $mail_plugins stats
protocol imap {
  mail_plugins = $mail_plugins imap_stats
}
plugin {
  # how often to session statistics
  stats_refresh = 30 secs
  # track per-IMAP command statistics
  stats_track_cmds = yes
}</pre>
<h3></h3>
<p>You&#8217;ll also need to give enough permissions for mail processes to be able to write to stats-mail fifo. For example if you use a single &#8220;vmail&#8221; user for mail access:</p>
<h3></h3>
<pre class="brush: php; title: ; notranslate">service stats {
  fifo_listener stats-mail {
    user = vmail
    mode = 0600
  }
}</pre>
<h2 id="Statistics_gathered">Statistics gathered</h2>
<p>Statistics gathered using the <tt>getrusage()</tt> system call:</p>
<ul>
<li>user_cpu: User CPU (seconds.microseconds)</li>
<li>sys_cpu: System CPU (seconds.microseconds)</li>
<li>min_faults: Minor page faults (page reclaims)</li>
<li>maj_faults: Major page faults</li>
<li>vol_cs: Voluntary context switches</li>
<li>invol_cs: Involuntary context switches</li>
<li>disk_input: Number of bytes read from disk</li>
<li>disk_output: Number of bytes written to disk</li>
</ul>
<p>The disk_input and disk_output attempt to count the actual read/write bytes to physical disk, so e.g. reads from OS&#8217;s cache aren&#8217;t counted. Note that not all operating systems and filesystem support this, instead they simply show these values always as 0.</p>
<p>Statistics gathered by Dovecot&#8217;s lib-storage internally:</p>
<ul>
<li>lookup_path: Number of open() and stat() calls (i.e. &#8220;path lookups&#8221;)</li>
<li>lookup_attr: Number of stat() and <a class="zem_slink" title="Stat (Unix)" href="http://en.wikipedia.org/wiki/Stat_%28Unix%29" rel="wikipedia">fstat</a>() calls</li>
<li>read_count: Number of read() calls for message data (e.g. index files not counted)</li>
<li>read_bytes: Number of message bytes read()</li>
<li>cache_hits: Number of cache hits from <tt>dovecot.index.cache</tt> file</li>
</ul>
<p><span class="Apple-style-span" style="font-size:14px;line-height:23px;"><br />
</span></p>
<a href="http://technology.mattrude.com/2011/09/dovecot-v2-1-statistics/">Dovecot v2.1+ Statistics</a> is a post from; <a href="http://technology.mattrude.com/">Matt&#039;s Technology Blog</a> which is not allowed to be copied on other sites.]]></content:encoded>
			<wfw:commentRss>http://technology.mattrude.com/2011/09/dovecot-v2-1-statistics/feed/</wfw:commentRss>
		<slash:comments>1</slash:comments>
		</item>
		<item>
		<title>Remotely Reboot Windows with VBS</title>
		<link>http://technology.mattrude.com/2011/09/remotely-reboot-windows-with-a-vbs-script/</link>
		<comments>http://technology.mattrude.com/2011/09/remotely-reboot-windows-with-a-vbs-script/#comments</comments>
		<pubDate>Tue, 13 Sep 2011 03:23:31 +0000</pubDate>
		<dc:creator>Matt Rude</dc:creator>
				<category><![CDATA[Scripts]]></category>
		<category><![CDATA[VBScript]]></category>
		<category><![CDATA[Windows]]></category>
		<category><![CDATA[Windows XP]]></category>

		<guid isPermaLink="false">http://technology.mattrude.com/?p=4971</guid>
		<description><![CDATA[Remotely Reboot Windows with VBS is a post from; Matt&#039;s Technology Blog which is not allowed to be copied on other sites.<a href="http://technology.mattrude.com/2011/09/remotely-reboot-windows-with-a-vbs-script/">Remotely Reboot Windows with VBS</a> is a post from; <a href="http://technology.mattrude.com/">Matt&#039;s Technology Blog</a> which is not allowed to be copied on other sites.]]></description>
			<content:encoded><![CDATA[<pre class="brush: plain; title: ; notranslate">
|==========================================================================
|
| COMMENT: Remotely reboots a PC.  May use machine name or IP address.
|
|==========================================================================

On Error Resume Next
mname = InputBox(&quot;Enter Machine Name&quot;, &quot;Reboot Machine&quot;)
If Len(mname) = 0 Then Wscript.Quit

if Msgbox(&quot;Are you sure you want to reboot machine &quot; &amp; mname, vbYesNo, &quot;Reboot Machine&quot;) = vbYes then

Set OpSysSet = GetObject(&quot;winmgmts:{impersonationLevel=impersonate,(RemoteShutdown)}//&quot; &amp; mname).ExecQuery(&quot;select * from Win32_OperatingSystem where Primary=true&quot;)
for each OpSys in OpSysSet
OpSys.Reboot()
next
end if
</pre>
<a href="http://technology.mattrude.com/2011/09/remotely-reboot-windows-with-a-vbs-script/">Remotely Reboot Windows with VBS</a> is a post from; <a href="http://technology.mattrude.com/">Matt&#039;s Technology Blog</a> which is not allowed to be copied on other sites.]]></content:encoded>
			<wfw:commentRss>http://technology.mattrude.com/2011/09/remotely-reboot-windows-with-a-vbs-script/feed/</wfw:commentRss>
		<slash:comments>0</slash:comments>
		</item>
		<item>
		<title>Dovecot&#8217;s Quota Plugin</title>
		<link>http://technology.mattrude.com/2011/09/dovecots-quota-plugin/</link>
		<comments>http://technology.mattrude.com/2011/09/dovecots-quota-plugin/#comments</comments>
		<pubDate>Mon, 05 Sep 2011 14:57:49 +0000</pubDate>
		<dc:creator>Matt Rude</dc:creator>
				<category><![CDATA[Notes]]></category>
		<category><![CDATA[Data Definition Language]]></category>
		<category><![CDATA[Dovecot]]></category>
		<category><![CDATA[MySQL]]></category>
		<category><![CDATA[Plugin]]></category>
		<category><![CDATA[Postfix (software)]]></category>
		<category><![CDATA[SQL]]></category>
		<category><![CDATA[SQLite]]></category>

		<guid isPermaLink="false">http://technology.mattrude.com/?p=4943</guid>
		<description><![CDATA[The below assumes your using mdbox so dirsize or dict:sql will be the fastest. Since we already have sql setup, were going to go with that. Enabling the Quota Plugin The dovecot-dict-mysql.conf file should containe something like this And lastly, add the &#8230; <a href="http://technology.mattrude.com/2011/09/dovecots-quota-plugin/">Continue reading <span class="meta-nav">&#8594;</span></a><a href="http://technology.mattrude.com/2011/09/dovecots-quota-plugin/">Dovecot&#8217;s Quota Plugin</a> is a post from; <a href="http://technology.mattrude.com/">Matt&#039;s Technology Blog</a> which is not allowed to be copied on other sites.]]></description>
			<content:encoded><![CDATA[<p>The below assumes your using <strong><a href="http://wiki2.dovecot.org/MailboxFormat/dbox" target="_blank">mdbox</a> </strong>so dirsize or dict:sql will be the fastest. Since we already have sql setup, were going to go with that.</p>
<p><strong>Enabling the Quota Plugin</strong></p>
<pre class="brush: plain; title: ; notranslate">mail_plugins = $mail_plugins quota

protocol imap {
  # Space separated list of plugins to load (default is global mail_plugins).
  mail_plugins = $mail_plugins imap_quota
}

plugin {
  # SQL backend:
  quota = dict:User quota::proxy::quota
  quota_rule = *:storage=1024M:messages=100000
  quota_rule2 = Trash:storage=+20%%
  quota_rule3 = Junk:storage=+20%%
}dict {
  quota = mysql:/etc/dovecot/dovecot-dict-mysql.conf
}</pre>
<p>The dovecot-dict-mysql.conf file should containe something like this</p>
<pre class="brush: plain; title: ; notranslate">connect = host=localhost dbname=postfix user=postfix password=postfix
map {
  pattern = priv/quota/storage
  table = quota
  username_field = username
  value_field = bytes
}
map {
  pattern = priv/quota/messages
  table = quota
  username_field = username
  value_field = messages
}</pre>
<p>And lastly, add the following table to your email servers database in <a class="zem_slink" title="MySQL" href="http://www.mysql.com" rel="homepage">mySQL</a>.</p>
<pre class="brush: plain; title: ; notranslate">CREATE TABLE quota (
  username varchar(100) not null,
  bytes bigint not null default 0,
  messages integer not null default 0,
  primary key (username)
);</pre>
<ul>
<li><strong><a href="http://wiki2.dovecot.org/Quota" rel="nofollow">http://wiki2.dovecot.org/Quota</a></strong></li>
</ul>
<a href="http://technology.mattrude.com/2011/09/dovecots-quota-plugin/">Dovecot&#8217;s Quota Plugin</a> is a post from; <a href="http://technology.mattrude.com/">Matt&#039;s Technology Blog</a> which is not allowed to be copied on other sites.]]></content:encoded>
			<wfw:commentRss>http://technology.mattrude.com/2011/09/dovecots-quota-plugin/feed/</wfw:commentRss>
		<slash:comments>0</slash:comments>
		</item>
		<item>
		<title>Doveadm Notes</title>
		<link>http://technology.mattrude.com/2011/09/doveadm-notes/</link>
		<comments>http://technology.mattrude.com/2011/09/doveadm-notes/#comments</comments>
		<pubDate>Mon, 05 Sep 2011 14:48:12 +0000</pubDate>
		<dc:creator>Matt Rude</dc:creator>
				<category><![CDATA[Notes]]></category>
		<category><![CDATA[administration utility]]></category>
		<category><![CDATA[Dovecot]]></category>
		<category><![CDATA[inbox]]></category>
		<category><![CDATA[Mail]]></category>
		<category><![CDATA[mailboxes]]></category>
		<category><![CDATA[quota status]]></category>
		<category><![CDATA[SQLite]]></category>
		<category><![CDATA[trash folder]]></category>

		<guid isPermaLink="false">http://technology.mattrude.com/?p=4940</guid>
		<description><![CDATA[Dovecot&#8216;s administration utility can be used to manage various parts of Dovecot, as well as access users&#8217; mailboxes. Here&#8217;s a list of some commonly used commands. Show all messages older then 30 days in user matt&#8217;s Inbox doveadm search -u matt &#8230; <a href="http://technology.mattrude.com/2011/09/doveadm-notes/">Continue reading <span class="meta-nav">&#8594;</span></a><a href="http://technology.mattrude.com/2011/09/doveadm-notes/">Doveadm Notes</a> is a post from; <a href="http://technology.mattrude.com/">Matt&#039;s Technology Blog</a> which is not allowed to be copied on other sites.]]></description>
			<content:encoded><![CDATA[<p><strong><a class="zem_slink" title="Dovecot (software)" href="http://www.dovecot.org" rel="homepage">Dovecot</a>&#8216;s administration utility</strong> can be used to manage various parts of Dovecot, as well as access users&#8217; mailboxes. Here&#8217;s a list of some commonly used commands.</p>
<ul>
<li><strong>Show all messages older then 30 days in user matt&#8217;s Inbox</strong></li>
</ul>
<pre>doveadm search -u matt mailbox INBOX savedbefore 30d</pre>
<ul>
<li><strong>Expunge (delete) all messages older then 7 days in matt&#8217;s Trash folder</strong></li>
</ul>
<pre>doveadm expunge -u matt mailbox Trash savedbefore 7d</pre>
<ul>
<li><strong>List current quota status for a user (-u) or all users (-A)</strong></li>
</ul>
<pre>doveadm quota get -u matt</pre>
<a href="http://technology.mattrude.com/2011/09/doveadm-notes/">Doveadm Notes</a> is a post from; <a href="http://technology.mattrude.com/">Matt&#039;s Technology Blog</a> which is not allowed to be copied on other sites.]]></content:encoded>
			<wfw:commentRss>http://technology.mattrude.com/2011/09/doveadm-notes/feed/</wfw:commentRss>
		<slash:comments>0</slash:comments>
		</item>
		<item>
		<title>Building a WordPress Cloud, Cluster Setup</title>
		<link>http://technology.mattrude.com/2011/09/building-a-wordpress-cloud-cluster-setup/</link>
		<comments>http://technology.mattrude.com/2011/09/building-a-wordpress-cloud-cluster-setup/#comments</comments>
		<pubDate>Mon, 05 Sep 2011 01:57:33 +0000</pubDate>
		<dc:creator>Matt Rude</dc:creator>
				<category><![CDATA[General]]></category>
		<category><![CDATA[load balancing]]></category>
		<category><![CDATA[MySQL]]></category>
		<category><![CDATA[Rackspace]]></category>
		<category><![CDATA[Rackspace Cloud]]></category>
		<category><![CDATA[Servers]]></category>
		<category><![CDATA[Site Management]]></category>
		<category><![CDATA[Web server]]></category>
		<category><![CDATA[WordPress]]></category>

		<guid isPermaLink="false">http://technology.mattrude.com/?p=4909</guid>
		<description><![CDATA[This how-to will explain how to build a WordPress site on 2, 3, or more Rackspace cloud servers, with full load-balancing and redundancy. To accomplish this, you will setup multiple web-servers and one or more mySQL servers, behind two Rackspace cloud load-balancers. One load-balancer will server all you &#8230; <a href="http://technology.mattrude.com/2011/09/building-a-wordpress-cloud-cluster-setup/">Continue reading <span class="meta-nav">&#8594;</span></a><a href="http://technology.mattrude.com/2011/09/building-a-wordpress-cloud-cluster-setup/">Building a WordPress Cloud, Cluster Setup</a> is a post from; <a href="http://technology.mattrude.com/">Matt&#039;s Technology Blog</a> which is not allowed to be copied on other sites.]]></description>
			<content:encoded><![CDATA[<p>This how-to will explain how to build a <a class="zem_slink" title="WordPress" href="http://wordpress.org" rel="homepage">WordPress</a> site on 2, 3, or more <a class="zem_slink" title="Rackspace Cloud" href="http://www.rackspace.com/cloud/" rel="homepage">Rackspace cloud</a> servers, with full load-balancing and redundancy.</p>
<p>To accomplish this, you will setup multiple <a class="zem_slink" title="Web server" href="http://en.wikipedia.org/wiki/Web_server" rel="wikipedia">web-servers</a> and one or more <a class="zem_slink" title="MySQL" href="http://www.mysql.com" rel="homepage">mySQL</a> servers, behind two Rackspace cloud <a class="zem_slink" title="Load balancing (computing)" href="http://en.wikipedia.org/wiki/Load_balancing_%28computing%29" rel="wikipedia">load-balancers</a>. One load-balancer will <a class="zem_slink" title="Server (computing)" href="http://en.wikipedia.org/wiki/Server_%28computing%29" rel="wikipedia">server</a> all you normal user <a class="zem_slink" title="Internet traffic" href="http://en.wikipedia.org/wiki/Internet_traffic" rel="wikipedia">internet traffic</a> from all the web-servers.  The other load-balancer will server only your secured traffic to your admin sites (Dashboard) from a single, master, server.  You will then set WordPress to only server the admins sites threw a secure connections, this way all uploads will be saved to a single server and may be distributed from there. This also insures that you will be able to see the newly uploaded file, even before it has a chance to propagate to the other servers. The flaw with this configuration is that if the Master server goes down, no posts may be created until the issue is resolved.</p>
<h3>The Setup</h3>
<p>There are meny different ways we can accomplish this.  Here I am going to show a two server setup, but you can easily expand this into as many servers as you wish.</p>
<ul>
<li>Server1 &#8211; Master Database Server, Master Web Server</li>
<li>Server2 &#8211; Slave Database Server, Slave Web Server or only Slave Web Server</li>
</ul>
<h3>Building Server1</h3>
<p>Server1 is our main server, if Server2+went down, the site would still be fully up, just slower.</p>
<p>This How-To assumes your using Fedora hosts for these setup&#8217;s.  To start out, we need Apache, php, mySQL installed on the server.</p>
<a href="http://technology.mattrude.com/2011/09/building-a-wordpress-cloud-cluster-setup/">Building a WordPress Cloud, Cluster Setup</a> is a post from; <a href="http://technology.mattrude.com/">Matt&#039;s Technology Blog</a> which is not allowed to be copied on other sites.]]></content:encoded>
			<wfw:commentRss>http://technology.mattrude.com/2011/09/building-a-wordpress-cloud-cluster-setup/feed/</wfw:commentRss>
		<slash:comments>0</slash:comments>
		</item>
		<item>
		<title>Setting time on Windows XP via NTP</title>
		<link>http://technology.mattrude.com/2011/06/setting-time-on-windows-xp-via-ntp/</link>
		<comments>http://technology.mattrude.com/2011/06/setting-time-on-windows-xp-via-ntp/#comments</comments>
		<pubDate>Wed, 22 Jun 2011 02:32:34 +0000</pubDate>
		<dc:creator>Matt Rude</dc:creator>
				<category><![CDATA[How-To's]]></category>
		<category><![CDATA[Microsoft]]></category>
		<category><![CDATA[Microsoft Knowledge Base]]></category>
		<category><![CDATA[Microsoft Windows]]></category>
		<category><![CDATA[Network Time Protocol]]></category>
		<category><![CDATA[NTP]]></category>
		<category><![CDATA[Time Server]]></category>
		<category><![CDATA[Windows Registry]]></category>
		<category><![CDATA[Windows XP]]></category>

		<guid isPermaLink="false">http://technology.mattrude.com/?p=4276</guid>
		<description><![CDATA[Windows XP has a built-in timesynchronization feature that&#8217;s designed to automaticallysynchronize your computer&#8217;s clock with an Internet time server on aregular basis. To access this feature, double-click the clock inthe notification area of the taskbar. From the Date And TimeProperties &#8230; <a href="http://technology.mattrude.com/2011/06/setting-time-on-windows-xp-via-ntp/">Continue reading <span class="meta-nav">&#8594;</span></a><a href="http://technology.mattrude.com/2011/06/setting-time-on-windows-xp-via-ntp/">Setting time on Windows XP via NTP</a> is a post from; <a href="http://technology.mattrude.com/">Matt&#039;s Technology Blog</a> which is not allowed to be copied on other sites.]]></description>
			<content:encoded><![CDATA[<p>Windows XP has a built-in timesynchronization feature that&#8217;s designed to automaticallysynchronize your computer&#8217;s clock with an Internet time server on aregular basis. To access this feature, double-click the clock inthe notification area of the taskbar. From the Date And TimeProperties dialog box, select Internet Time. Make sure that theAutomatically Synchronize With An Internet Time Server check box isselected.</p>
<p>The Server drop-down list contains two timeservers: Microsoft&#8217;s time server at time.windows.com and the U.S.government&#8217;s atomic clock at time.nist.gov.</p>
<p>While you can manually type the name of anytime server that uses the Simple Network Time Protocol (SNTP) inthe Server text box, it&#8217;s more convenient to add time servers tothe list. However, this feature is available only onstand-alone Windows XP systems or systems that are a part of aworkgroup; it is not available on Windows XP Professional systemsthat are a part of a domain. Here&#8217;s how to add time servers:</p>
<ol>
<li>Launch the Registry Editor (Regedit.exe).</li>
<li>Go to <code>HKEY_LOCAL_MACHINE\SOFTWARE\Microsoft\Windows\CurrentVersion\DateTime\Servers</code></li>
<li>Right-click the Servers key, and select New | String value.</li>
<li>Name the value 3, and press [Enter] twice to access the Edit StringValue dialog box.</li>
<li>Type the address of the SNTP time server in the Value Data textbox, and click OK.</li>
<li>Repeat Steps 3 through 5 for each additional SNTP time server youwant to add, incrementing the value name each time: 4, 5, 6, and soon.</li>
<li>Close the Registry Editor.</li>
</ol>
<p>For a list of acceptable SNTP time servers, see <a href="http://support.microsoft.com/default.aspx?scid=kb;EN-US;q262680">Microsoft Knowledge Base article Q262680</a>.</p>
<a href="http://technology.mattrude.com/2011/06/setting-time-on-windows-xp-via-ntp/">Setting time on Windows XP via NTP</a> is a post from; <a href="http://technology.mattrude.com/">Matt&#039;s Technology Blog</a> which is not allowed to be copied on other sites.]]></content:encoded>
			<wfw:commentRss>http://technology.mattrude.com/2011/06/setting-time-on-windows-xp-via-ntp/feed/</wfw:commentRss>
		<slash:comments>0</slash:comments>
		</item>
		<item>
		<title>Setting Windows 7 to update from a network time server</title>
		<link>http://technology.mattrude.com/2011/06/setting-windows-7-to-update-from-a-network-time-server/</link>
		<comments>http://technology.mattrude.com/2011/06/setting-windows-7-to-update-from-a-network-time-server/#comments</comments>
		<pubDate>Thu, 16 Jun 2011 18:25:25 +0000</pubDate>
		<dc:creator>Matt Rude</dc:creator>
				<category><![CDATA[How-To's]]></category>
		<category><![CDATA[Command Prompt]]></category>
		<category><![CDATA[Command-line interface]]></category>
		<category><![CDATA[Graphical user interface]]></category>
		<category><![CDATA[Network Time Protocol]]></category>
		<category><![CDATA[Time Server]]></category>
		<category><![CDATA[Windows 7]]></category>

		<guid isPermaLink="false">http://technology.mattrude.com/?p=4256</guid>
		<description><![CDATA[If you have an issue with your system clock losing time, you’ve probably had to go and re-sync your clock with the internet time servers. The problem is that there are just way too many clicks required to get to &#8230; <a href="http://technology.mattrude.com/2011/06/setting-windows-7-to-update-from-a-network-time-server/">Continue reading <span class="meta-nav">&#8594;</span></a><a href="http://technology.mattrude.com/2011/06/setting-windows-7-to-update-from-a-network-time-server/">Setting Windows 7 to update from a network time server</a> is a post from; <a href="http://technology.mattrude.com/">Matt&#039;s Technology Blog</a> which is not allowed to be copied on other sites.]]></description>
			<content:encoded><![CDATA[<p>If you have an issue with your system clock losing time, you’ve probably had to go and re-sync your clock with the internet time servers. The problem is that there are just way too many clicks required to get to the right screen, so the command line is much simpler.</p>
<p>Note that you can partially solve this issue by changing the time server you are using or increasing the intervals between time checks, but there are some instances where you’ll just want to quickly sync the time manually.</p>
<p><strong>Sync Clock the Slow GUI Way</strong></p>
<p>First you’ll have to right-click on the clock and choose “Adjust Date/Time”</p>
<p><img class="alignnone size-full wp-image-4257" title="win7_TS-1" src="http://tech.mattrude.com/wp-content/uploads/2011/05/win7_TS-1.png" alt="" width="264" height="287" /></p>
<p>Then you select the Internet Time tab, and click the Change Settings button…</p>
<p><img class="alignnone size-full wp-image-4268" title="win7_TS-2" src="http://tech.mattrude.com/wp-content/uploads/2011/06/win7_TS-2.png" alt="" width="505" height="502" /></p>
<p>After the UAC prompt you can finally click the “Update now” button to tell the computer to resync.</p>
<p><img class="alignnone size-full wp-image-4269" title="win7_TS-3" src="http://tech.mattrude.com/wp-content/uploads/2011/06/win7_TS-3.png" alt="" width="480" height="296" /></p>
<p>That’s a lot of steps… but check out how simple it is from the command line.</p>
<p><strong>Sync Clock from Command Line</strong></p>
<p>Simply open an administrative mode command prompt (right-click, Run as administrator), and then type in the following command:</p>
<pre>w32tm /resync</pre>
<p><img class="alignnone size-full wp-image-4270" title="win7_TS-4" src="http://tech.mattrude.com/wp-content/uploads/2011/06/win7_TS-4.png" alt="" width="532" height="170" /></p>
<p>And now your clock is sync’d. If you want proof, you could check the time settings panel again.</p>
<p><img class="alignnone size-full wp-image-4271" title="win7_TS-5" src="http://tech.mattrude.com/wp-content/uploads/2011/06/win7_TS-5.png" alt="" width="440" height="82" /></p>
<a href="http://technology.mattrude.com/2011/06/setting-windows-7-to-update-from-a-network-time-server/">Setting Windows 7 to update from a network time server</a> is a post from; <a href="http://technology.mattrude.com/">Matt&#039;s Technology Blog</a> which is not allowed to be copied on other sites.]]></content:encoded>
			<wfw:commentRss>http://technology.mattrude.com/2011/06/setting-windows-7-to-update-from-a-network-time-server/feed/</wfw:commentRss>
		<slash:comments>0</slash:comments>
		</item>
		<item>
		<title>Outlook crashes when printing</title>
		<link>http://technology.mattrude.com/2011/06/outlook-crashes-when-printing/</link>
		<comments>http://technology.mattrude.com/2011/06/outlook-crashes-when-printing/#comments</comments>
		<pubDate>Wed, 01 Jun 2011 19:25:59 +0000</pubDate>
		<dc:creator>Matt Rude</dc:creator>
				<category><![CDATA[How-To's]]></category>
		<category><![CDATA[Microsoft]]></category>
		<category><![CDATA[Microsoft Outlook]]></category>
		<category><![CDATA[Microsoft Windows]]></category>
		<category><![CDATA[User (computing)]]></category>
		<category><![CDATA[Windows XP]]></category>

		<guid isPermaLink="false">http://technology.mattrude.com/?p=4261</guid>
		<description><![CDATA[Outlook keeps its printing style settings in a file called OutlPrnt. You can run into several issues like these hangs and crashes when the file gets corrupted. On multiple occasions I’ve also seen messages been printed in right-to-left format instead &#8230; <a href="http://technology.mattrude.com/2011/06/outlook-crashes-when-printing/">Continue reading <span class="meta-nav">&#8594;</span></a><a href="http://technology.mattrude.com/2011/06/outlook-crashes-when-printing/">Outlook crashes when printing</a> is a post from; <a href="http://technology.mattrude.com/">Matt&#039;s Technology Blog</a> which is not allowed to be copied on other sites.]]></description>
			<content:encoded><![CDATA[<p>Outlook keeps its printing style settings in a file called OutlPrnt. You can run into several issues like these hangs and crashes when the file gets corrupted. On multiple occasions I’ve also seen messages been printed in right-to-left format instead of left-to-right due to OutlPrnt corruptions.</p>
<p>You can recover from this by renaming the OutlPrnt file to .old when Outlook is closed. You can find the file here;</p>
<p><strong>Windows Vista and Windows 7</strong><br />
C:Users%username%AppDataRoamingMicrosoftOutlook</p>
<p><strong>Windows XP</strong><br />
C:Documents and Settings%username%Application DataMicrosoftOutlook</p>
<a href="http://technology.mattrude.com/2011/06/outlook-crashes-when-printing/">Outlook crashes when printing</a> is a post from; <a href="http://technology.mattrude.com/">Matt&#039;s Technology Blog</a> which is not allowed to be copied on other sites.]]></content:encoded>
			<wfw:commentRss>http://technology.mattrude.com/2011/06/outlook-crashes-when-printing/feed/</wfw:commentRss>
		<slash:comments>0</slash:comments>
		</item>
		<item>
		<title>Active Directory Saved Queries</title>
		<link>http://technology.mattrude.com/2011/05/active-directory-saved-queries/</link>
		<comments>http://technology.mattrude.com/2011/05/active-directory-saved-queries/#comments</comments>
		<pubDate>Mon, 09 May 2011 19:03:05 +0000</pubDate>
		<dc:creator>Matt Rude</dc:creator>
				<category><![CDATA[How-To's]]></category>
		<category><![CDATA[Access Providers]]></category>
		<category><![CDATA[Active Directory]]></category>
		<category><![CDATA[Computers and Internet]]></category>
		<category><![CDATA[Microsoft Windows]]></category>
		<category><![CDATA[Multi-user]]></category>
		<category><![CDATA[User (computing)]]></category>

		<guid isPermaLink="false">http://technology.mattrude.com/?p=4238</guid>
		<description><![CDATA[Locked Out Users (objectCategory=Person)(objectClass=User)(lockoutTime>=1) Dial In Access (&#38;(&#38;(&#38;(&#38;(objectCategory=person)(objectClass=user)(msNPAllowDialin=TRUE))))) Disabled User Accounts (&#38;(objectCategory=person)(objectClass=user)(userAccountControl:1.2.840.113556.1.4.803:=2)) No Expiring Accounts (&#38;(objectCategory=person)(objectClass=user) (userAccountControl:1.2.840.113556.1.4.803:=65536)) Active Accounts (&#38;(&#38;(objectCategory=person)(objectClass=user) (!userAccountControl:1.2.840.113556.1.4.803:=2))) Hidden Mailboxes (&#38;(objectCategory=person)(objectClass=user)(msExchHideFromAddressLists=TRUE)) Active Directory Saved Queries is a post from; Matt&#039;s Technology Blog which is not allowed to &#8230; <a href="http://technology.mattrude.com/2011/05/active-directory-saved-queries/">Continue reading <span class="meta-nav">&#8594;</span></a><a href="http://technology.mattrude.com/2011/05/active-directory-saved-queries/">Active Directory Saved Queries</a> is a post from; <a href="http://technology.mattrude.com/">Matt&#039;s Technology Blog</a> which is not allowed to be copied on other sites.]]></description>
			<content:encoded><![CDATA[<p><strong>Locked Out Users</strong></p>
<pre>(objectCategory=Person)(objectClass=User)(lockoutTime>=1)</pre>
<p><strong>Dial In  Access</strong></p>
<pre>(&amp;(&amp;(&amp;(&amp;(objectCategory=person)(objectClass=user)(msNPAllowDialin=TRUE)))))</pre>
<p><strong>Disabled User Accounts</strong></p>
<pre>(&amp;(objectCategory=person)(objectClass=user)(userAccountControl:1.2.840.113556.1.4.803:=2))</pre>
<p><strong>No Expiring Accounts</strong></p>
<pre>(&amp;(objectCategory=person)(objectClass=user)
(userAccountControl:1.2.840.113556.1.4.803:=65536))</pre>
<p><strong>Active Accounts</strong></p>
<pre>(&amp;(&amp;(objectCategory=person)(objectClass=user)
(!userAccountControl:1.2.840.113556.1.4.803:=2)))</pre>
<p><strong>Hidden Mailboxes</strong></p>
<pre>(&amp;(objectCategory=person)(objectClass=user)(msExchHideFromAddressLists=TRUE))</pre>
<a href="http://technology.mattrude.com/2011/05/active-directory-saved-queries/">Active Directory Saved Queries</a> is a post from; <a href="http://technology.mattrude.com/">Matt&#039;s Technology Blog</a> which is not allowed to be copied on other sites.]]></content:encoded>
			<wfw:commentRss>http://technology.mattrude.com/2011/05/active-directory-saved-queries/feed/</wfw:commentRss>
		<slash:comments>0</slash:comments>
		</item>
		<item>
		<title>How to Disable the System Beep in Windows 7</title>
		<link>http://technology.mattrude.com/2011/05/how-to-disable-the-system-beep-in-windows-7/</link>
		<comments>http://technology.mattrude.com/2011/05/how-to-disable-the-system-beep-in-windows-7/#comments</comments>
		<pubDate>Mon, 09 May 2011 13:55:03 +0000</pubDate>
		<dc:creator>Matt Rude</dc:creator>
				<category><![CDATA[How-To's]]></category>
		<category><![CDATA[Device Manager]]></category>
		<category><![CDATA[Microsoft Management Console]]></category>
		<category><![CDATA[Microsoft Windows]]></category>
		<category><![CDATA[Personal computer]]></category>
		<category><![CDATA[Windows]]></category>

		<guid isPermaLink="false">http://technology.mattrude.com/?p=4235</guid>
		<description><![CDATA[Click on Start and right click on My Computer. Choose Manage from the menu to open the Computer Management window. In the left hand pane, expand the group labeled System Tools and click on Device Manager. Not all devices in &#8230; <a href="http://technology.mattrude.com/2011/05/how-to-disable-the-system-beep-in-windows-7/">Continue reading <span class="meta-nav">&#8594;</span></a><a href="http://technology.mattrude.com/2011/05/how-to-disable-the-system-beep-in-windows-7/">How to Disable the System Beep in Windows 7</a> is a post from; <a href="http://technology.mattrude.com/">Matt&#039;s Technology Blog</a> which is not allowed to be copied on other sites.]]></description>
			<content:encoded><![CDATA[<p>Click on Start and right click on My Computer. Choose Manage from the menu to open the Computer Management window.</p>
<p><a href="http://technology.mattrude.com/2011/05/how-to-disable-the-system-beep-in-windows-7/disable-beep-1/" rel="attachment wp-att-4245"><img class="alignnone size-full wp-image-4245" title="disable-beep-1" src="http://tech.mattrude.com/wp-content/uploads/2011/05/disable-beep-1.png" alt="" width="524" height="354" /></a></p>
<p>In the left hand pane, expand the group labeled System Tools and click on <strong>Device Manager</strong>.</p>
<p><a href="http://technology.mattrude.com/2011/05/how-to-disable-the-system-beep-in-windows-7/disable-beep-2/" rel="attachment wp-att-4246"><img class="alignnone size-full wp-image-4246" title="disable-beep-2" src="http://tech.mattrude.com/wp-content/uploads/2011/05/disable-beep-2.png" alt="" width="304" height="304" /></a></p>
<p>Not all devices in your PC are displayed in the Device Manager window by default. Some devices are hidden so you need to tell Window 7 to display the hidden devices. On the menu bar, click on <strong>View-&gt;Show Hidden Devices</strong>.</p>
<p><a href="http://technology.mattrude.com/2011/05/how-to-disable-the-system-beep-in-windows-7/disable-beep-3/" rel="attachment wp-att-4248"><img class="alignnone size-full wp-image-4248" title="disable-beep-3" src="http://tech.mattrude.com/wp-content/uploads/2011/05/disable-beep-3.png" alt="" width="354" height="254" /></a></p>
<p>Back on the Computer Management window, locate and click on a group labeled Non-Plug and Play Drivers. Here you will find a long list of non-plug and play devices connected to your computer and recognized by Windows 7. Locate an item labeled Beep, right click on it, and select Properties from the menu.</p>
<p><a href="http://technology.mattrude.com/2011/05/how-to-disable-the-system-beep-in-windows-7/disable-beep-4/" rel="attachment wp-att-4249"><img class="alignnone size-full wp-image-4249" title="disable-beep-4" src="http://tech.mattrude.com/wp-content/uploads/2011/05/disable-beep-4.png" alt="" width="354" height="154" /></a></p>
<p>On the Beep Properties window, click the Driver tab and change the Startup Type to Disabled.</p>
<p><a href="http://technology.mattrude.com/2011/05/how-to-disable-the-system-beep-in-windows-7/disable-beep-5/" rel="attachment wp-att-4250"><img class="alignnone size-full wp-image-4250" title="disable-beep-5" src="http://tech.mattrude.com/wp-content/uploads/2011/05/disable-beep-5.png" alt="" width="418" height="465" /></a></p>
<p>Click the <strong>OK </strong>button and restart Windows 7. From now on, you will no longer be annoyed by the occasional system beep from within your PC’s case. If you ever have need for the system beep again, follow the instructions above but change the Startup Type to System instead. Then, your internal speaker will continue to function normally with Windows 7<br />
Once the only sound of which PCs were capable, a computer’s internal speaker is now only a diagnostic tool to troubleshoot PCs with hardware errors. Using the Windows 7 Device Manager window, you can disable the System Beep and stop those annoying beeps from within your computer’s case.<br />
This is a much better solution than removing the speaker from within your PC since you or another troubleshooter may need it diagnose some computer errors.</p>
<a href="http://technology.mattrude.com/2011/05/how-to-disable-the-system-beep-in-windows-7/">How to Disable the System Beep in Windows 7</a> is a post from; <a href="http://technology.mattrude.com/">Matt&#039;s Technology Blog</a> which is not allowed to be copied on other sites.]]></content:encoded>
			<wfw:commentRss>http://technology.mattrude.com/2011/05/how-to-disable-the-system-beep-in-windows-7/feed/</wfw:commentRss>
		<slash:comments>1</slash:comments>
		</item>
		<item>
		<title>SQLite basics</title>
		<link>http://technology.mattrude.com/2011/05/sqlite-basics/</link>
		<comments>http://technology.mattrude.com/2011/05/sqlite-basics/#comments</comments>
		<pubDate>Sun, 08 May 2011 19:01:51 +0000</pubDate>
		<dc:creator>Matt Rude</dc:creator>
				<category><![CDATA[General]]></category>
		<category><![CDATA[Database]]></category>
		<category><![CDATA[Null (SQL)]]></category>
		<category><![CDATA[Select (SQL)]]></category>
		<category><![CDATA[SQL]]></category>
		<category><![CDATA[SQLite]]></category>
		<category><![CDATA[Tools]]></category>

		<guid isPermaLink="false">http://technology.mattrude.com/?p=4229</guid>
		<description><![CDATA[Using SQLite To open a SQLite database. sqlite3 /path/to/database/file Show the tables in a database .tables To Exit SQLite .quit PHP &#38; SQLite Connect to the database try{ $dbHandle = new PDO('sqlite:/var/www/lighttpd/noc/emailserver_stat.sqlite'); }catch( PDOException $exception ){ echo "Can NOT connect &#8230; <a href="http://technology.mattrude.com/2011/05/sqlite-basics/">Continue reading <span class="meta-nav">&#8594;</span></a><a href="http://technology.mattrude.com/2011/05/sqlite-basics/">SQLite basics</a> is a post from; <a href="http://technology.mattrude.com/">Matt&#039;s Technology Blog</a> which is not allowed to be copied on other sites.]]></description>
			<content:encoded><![CDATA[<h2>Using SQLite</h2>
<ul>
<li><strong>To open a SQLite database.</strong></li>
</ul>
<pre>sqlite3 /path/to/database/file</pre>
<ul>
<li><strong>Show the tables in a database</strong></li>
</ul>
<pre>.tables</pre>
<ul>
<li><strong>To Exit SQLite</strong></li>
</ul>
<pre>.quit</pre>
<h2>PHP &amp; SQLite</h2>
<h3>Connect to the database</h3>
<pre>try{
$dbHandle = new PDO('sqlite:/var/www/lighttpd/noc/emailserver_stat.sqlite');
}catch( PDOException $exception ){
echo "Can NOT connect to database";
die($exception-&gt;getMessage());
}</pre>
<h3>Create a table if it doesn&#8217;t exist</h3>
<pre>$sqlCreateTable = 'CREATE TABLE status (date date NOT NULL default '0000-00-00', item varchar(255) NOT NULL, value varchar(255) NOT NULL)';
$dbHandle-&gt;exec($sqlCreateTable);</pre>
<h3>List the conent of a table</h3>
<pre>$search_date = "2009-02-11";
$sqlGetView = 'SELECT * FROM status WHERE date = "'.$search_date.'"';
$result = $dbHandle-&gt;query($sqlGetView);
echo "&lt;table border='1'&gt;";
 while ($entry = $result-&gt;fetch()) {
    echo "&lt;tr&gt;&lt;td&gt; " . $entry['value'] . "&lt;/td&gt;&lt;td&gt;" . $entry['item']. "&lt;/td&gt;&lt;/tr&gt;";
 } echo "&lt;/table&gt;";</pre>
<h3>Display a single value from a table</h3>
<pre>$search_date = "2009-02-11";
$sqlGetView = 'SELECT value FROM status WHERE item = 'connections' AND date = "'.$search_date.'"';
$result = $dbHandle-&gt;query($sqlGetView);
$pageView = $result-&gt;fetch();
$connections = $pageView['value'];

echo "$search_date
";
echo 'Number Of Connections: '.$connections.'
';</pre>
<a href="http://technology.mattrude.com/2011/05/sqlite-basics/">SQLite basics</a> is a post from; <a href="http://technology.mattrude.com/">Matt&#039;s Technology Blog</a> which is not allowed to be copied on other sites.]]></content:encoded>
			<wfw:commentRss>http://technology.mattrude.com/2011/05/sqlite-basics/feed/</wfw:commentRss>
		<slash:comments>0</slash:comments>
		</item>
		<item>
		<title>Configuring Spamassassin (MySQL &amp; Virtual Users)</title>
		<link>http://technology.mattrude.com/2011/05/configuring-spamassassin-mysql-virtual-users/</link>
		<comments>http://technology.mattrude.com/2011/05/configuring-spamassassin-mysql-virtual-users/#comments</comments>
		<pubDate>Sat, 07 May 2011 18:05:10 +0000</pubDate>
		<dc:creator>Matt Rude</dc:creator>
				<category><![CDATA[How-To's]]></category>
		<category><![CDATA[MySQL]]></category>
		<category><![CDATA[Postfix]]></category>
		<category><![CDATA[Postfix (software)]]></category>
		<category><![CDATA[Preference]]></category>
		<category><![CDATA[SpamAssassin]]></category>
		<category><![CDATA[Spamd]]></category>
		<category><![CDATA[SQL]]></category>
		<category><![CDATA[Table (database)]]></category>
		<category><![CDATA[User (computing)]]></category>

		<guid isPermaLink="false">http://technology.mattrude.com/?p=4218</guid>
		<description><![CDATA[With this setup you will be saving the user preferences and bayes tokens in a MySQL data source. But, while scanning a message if spamd is unable to connect to the server specified in user_scores_dsn (below) or an error occurs when querying &#8230; <a href="http://technology.mattrude.com/2011/05/configuring-spamassassin-mysql-virtual-users/">Continue reading <span class="meta-nav">&#8594;</span></a><a href="http://technology.mattrude.com/2011/05/configuring-spamassassin-mysql-virtual-users/">Configuring Spamassassin (MySQL &amp; Virtual Users)</a> is a post from; <a href="http://technology.mattrude.com/">Matt&#039;s Technology Blog</a> which is not allowed to be copied on other sites.]]></description>
			<content:encoded><![CDATA[<p>With this setup you will be saving the user preferences and bayes tokens in a <a title="MySQL" href="http://wiki.mattrude.com/MySQL">MySQL</a> data source. But, while scanning a message if spamd is unable to connect to the server specified in user_scores_dsn (below) or an error occurs when querying the SQL server then spam checking will not be performed on that message.</p>
<p>First we need to build the database table. You may download mine below.</p>
<ul>
<li><strong><a title="Spamassassin.sql" href="http://wiki.mattrude.com/images/7/7a/Spamassassin.sql">SpamAssassin Bayes tables</a></strong></li>
<li><strong><a title="Spamassassin userpref.sql" href="http://wiki.mattrude.com/images/a/a7/Spamassassin_userpref.sql">Spamassassin User Preferences table</a></strong></li>
</ul>
<p>Then import the file into the spamassassin table on your <a title="MySQL" href="http://wiki.mattrude.com/MySQL">MySQL</a> server.</p>
<pre>wget <a href="http://wiki.mattrude.com/images/7/7a/Spamassassin.sql" rel="nofollow">http://wiki.mattrude.com/images/7/7a/Spamassassin.sql</a>
wget <a href="http://wiki.mattrude.com/images/a/a7/Spamassassin_userpref.sql" rel="nofollow">http://wiki.mattrude.com/images/a/a7/Spamassassin_userpref.sql</a>
mysql -h localhost -u postfix -ppostfix spamassassin &lt; Spamassassin.sql
mysql -h localhost -u postfix -ppostfix spamassassin &lt; Spamassassin_userpref.sql</pre>
<p>To set the version number in the database, run the following.</p>
<pre>echo "INSERT INTO bayes_global_vars VALUES ('VERSION','3');" |mysql -u postfix -ppostfix spamassassin
INSERT INTO userpref (username, preference, value, prefid) VALUES ('@GLOBAL',  'required_score', '5.0', NULL);
INSERT INTO userpref (username, preference, value, prefid) VALUES ('@GLOBAL',  'rewrite_header Subject', '[SPAM]', NULL);
INSERT INTO userpref (username, preference, value, prefid) VALUES ('@GLOBAL',  'rewrite_header Subject', '1', NULL);
INSERT INTO userpref (username, preference, value, prefid) VALUES ('@GLOBAL',  'report_safe', '1', NULL);
INSERT INTO userpref (username, preference, value, prefid) VALUES ('@GLOBAL',  'trusted_networks', '192.168.1.0/24', NULL);
INSERT INTO userpref (username, preference, value, prefid) VALUES ('@GLOBAL',  'use_bayes', '1', NULL);
INSERT INTO userpref (username, preference, value, prefid) VALUES ('@GLOBAL',  'bayes_auto_learn', '1', NULL);
INSERT INTO userpref (username, preference, value, prefid) VALUES ('@GLOBAL',  'skip_rbl_checks', '0', NULL);
INSERT INTO userpref (username, preference, value, prefid) VALUES ('@GLOBAL',  'use_razor2', '1', NULL);
INSERT INTO userpref (username, preference, value, prefid) VALUES ('@GLOBAL',  'use_pyzor', '1', NULL);
INSERT INTO userpref (username, preference, value, prefid) VALUES ('@GLOBAL',  'ok_locales', '1', NULL);</pre>
<p>Now setup the configuration.</p>
<ul>
<li><strong>/etc/mail/spamassassin/local.cf</strong></li>
</ul>
<pre>required_score                  5.0
rewrite_header Subject          [SPAM]
trusted_networks                192.168.1.0/24
report_safe                     1
use_bayes                       1
bayes_auto_learn                1
skip_rbl_checks                 0
use_razor2                      1
use_pyzor                       1
ok_languages                    en

rewrite_header Subject
user_scores_dsn                 DBI:mysql:spamassassin:localhost
user_scores_sql_username        postfix
user_scores_sql_password        postfix
auto_whitelist_factory          Mail::SpamAssassin::SQLBasedAddrList
user_awl_dsn                    DBI:mysql:spamassassin:localhost
user_awl_sql_table              awl
user_awl_sql_username           postfix
user_awl_sql_password           postfix
bayes_store_module              Mail::SpamAssassin::BayesStore::MySQL
bayes_sql_dsn                   DBI:mysql:spamassassin:localhost
bayes_sql_username              postfix
bayes_sql_password              postfix</pre>
<p>The spamd server will not pay attention to SQL preferences by default, even with user_scores_dsn set in the config files. You must startup spamd with the proper options (ie -q or -Q). If the user_scores_dsn option does not exist, SpamAssassin will not attempt to use SQL for retrieving users&#8217; preferences.</p>
<p>SpamAssassin needs to be ran with the options similar to this:</p>
<pre>/usr/bin/spamd -d -x -q -Q -u nobody -r /var/run/spamd.pid</pre>
<p>I believe the best way of doing this is modify your <strong>/etc/init.d/spamassassin</strong> init file and change <strong>SPAMDOPTIONS</strong> to:</p>
<pre>SPAMDOPTIONS="-d -m5 -x -q -Q -u nobody"</pre>
<p><em>make sure <strong>/etc/sysconfig/spamassassin</strong> dosn&#8217;t override your settings run the below command to confirm spamassassin is running correctly</em></p>
<pre>ps -eaf |grep spamd</pre>
<a href="http://technology.mattrude.com/2011/05/configuring-spamassassin-mysql-virtual-users/">Configuring Spamassassin (MySQL &amp; Virtual Users)</a> is a post from; <a href="http://technology.mattrude.com/">Matt&#039;s Technology Blog</a> which is not allowed to be copied on other sites.]]></content:encoded>
			<wfw:commentRss>http://technology.mattrude.com/2011/05/configuring-spamassassin-mysql-virtual-users/feed/</wfw:commentRss>
		<slash:comments>0</slash:comments>
		</item>
		<item>
		<title>Postfix mySQL to SQLite export/import scripts</title>
		<link>http://technology.mattrude.com/2011/05/postfix-mysql-to-sqlite-exportimport-scripts/</link>
		<comments>http://technology.mattrude.com/2011/05/postfix-mysql-to-sqlite-exportimport-scripts/#comments</comments>
		<pubDate>Fri, 06 May 2011 15:41:41 +0000</pubDate>
		<dc:creator>Matt Rude</dc:creator>
				<category><![CDATA[Bash]]></category>
		<category><![CDATA[Scripts]]></category>
		<category><![CDATA[Data Definition Language]]></category>
		<category><![CDATA[Database]]></category>
		<category><![CDATA[Microsoft SQL Server]]></category>
		<category><![CDATA[SQL]]></category>
		<category><![CDATA[SQLite]]></category>
		<category><![CDATA[Tools]]></category>
		<category><![CDATA[Unique key]]></category>

		<guid isPermaLink="false">http://technology.mattrude.com/?p=4187</guid>
		<description><![CDATA[postfixdb-export.sh: #/bin/bash TMPDIR=/tmp/postfix_sqlite DATABASENAME=postfix.sqlite MYSQLDATABASE=postfix MYSQLUSER=postfix MYSQLPASS=postfix HTTPDIR=/var/www/mail.mattrude.com/noc if [ ! -e $TMPDIR ]; then mkdir -p $TMPDIR chmod a+w $TMPDIR else chmod a+w $TMPDIR fi if [ ! -e $HTTPDIR ]; then mkdir -p $HTTPDIR rm -rf $TMPDIR/csv_md5check.md5 else &#8230; <a href="http://technology.mattrude.com/2011/05/postfix-mysql-to-sqlite-exportimport-scripts/">Continue reading <span class="meta-nav">&#8594;</span></a><a href="http://technology.mattrude.com/2011/05/postfix-mysql-to-sqlite-exportimport-scripts/">Postfix mySQL to SQLite export/import scripts</a> is a post from; <a href="http://technology.mattrude.com/">Matt&#039;s Technology Blog</a> which is not allowed to be copied on other sites.]]></description>
			<content:encoded><![CDATA[<p><strong>postfixdb-export.sh:</strong></p>
<pre>#/bin/bash
TMPDIR=/tmp/postfix_sqlite
DATABASENAME=postfix.sqlite
MYSQLDATABASE=postfix
MYSQLUSER=postfix
MYSQLPASS=postfix
HTTPDIR=/var/www/mail.mattrude.com/noc

if [ ! -e $TMPDIR ]; then
 mkdir -p $TMPDIR
 chmod a+w $TMPDIR
else
 chmod a+w $TMPDIR
fi

if [ ! -e $HTTPDIR ]; then
 mkdir -p $HTTPDIR
 rm -rf $TMPDIR/csv_md5check.md5
else
 if [ ! -e $HTTPDIR/$DATABASENAME.gpg ]; then
  rm -rf $TMPDIR/csv_md5check.md5
 fi
fi

rm -rf $TMPDIR/alias.csv $TMPDIR/domain.csv $TMPDIR/mailbox.csv
echo "SELECT * FROM alias
INTO OUTFILE '$TMPDIR/alias.csv'
FIELDS TERMINATED BY '|'
LINES TERMINATED BY 'n'" |mysql $MYSQLDATABASE

echo "SELECT * FROM domain
INTO OUTFILE '$TMPDIR/domain.csv'
FIELDS TERMINATED BY '|'
LINES TERMINATED BY 'n'" |mysql $MYSQLDATABASE

echo "SELECT * FROM mailbox
INTO OUTFILE '$TMPDIR/mailbox.csv'
FIELDS TERMINATED BY '|'
LINES TERMINATED BY 'n'" |mysql $MYSQLDATABASE

if [ -e $TMPDIR/csv_md5check.md5 ]; then
 MD5STATUS=`md5sum -c $TMPDIR/csv_md5check.md5 |grep -v ".csv: OK" |wc -l` 2>&#038;1
else
 MD5STATUS=999
fi

if [ $MD5STATUS != '0' ]; then
 rm -rf $TMPDIR/$DATABASENAME $TMPDIR/$DATABASENAME.md5 $TMPDIR/schema.txt
 md5sum $TMPDIR/*.csv > $TMPDIR/csv_md5check.md5
 echo "Database $MYSQLDATABASE is being updated"
 echo "
 CREATE TABLE alias (
  address varchar(255) NOT NULL,
  goto text NOT NULL,
  domain varchar(255) NOT NULL,
  created datetime NOT NULL default '0000-00-00 00:00:00',
  modified datetime NOT NULL default '0000-00-00 00:00:00',
  active tinyint(1) NOT NULL default '1');

 CREATE TABLE domain (
  domain varchar(255) NOT NULL,
  description varchar(255) NOT NULL,
  aliases int(10) NOT NULL default '0',
  mailboxes int(10) NOT NULL default '0',
  maxquota bigint(20) NOT NULL default '0',
  quota bigint(20) NOT NULL default '0',
  transport varchar(255) NOT NULL,
  backupmx tinyint(1) NOT NULL default '0',
  created datetime NOT NULL default '0000-00-00 00:00:00',
  modified datetime NOT NULL default '0000-00-00 00:00:00',
  active tinyint(1) NOT NULL default '1' );

 CREATE TABLE mailbox (
  username varchar(255) NOT NULL,
  password varchar(255) NOT NULL,
  name varchar(255) NOT NULL,
  maildir varchar(255) NOT NULL,
  mailstore varchar(255) NOT NULL default 'mdbox:',
  quota bigint(20) NOT NULL default '0',
  domain varchar(255) NOT NULL,
  created datetime NOT NULL default '0000-00-00 00:00:00',
  modified datetime NOT NULL default '0000-00-00 00:00:00',
  quota_usage varchar(255),
  quota_usage_date varchar(255),
  active tinyint(1) NOT NULL default '1',
  local_part varchar(255) NOT NULL );
 " > $TMPDIR/schema.txt

 echo ".read $TMPDIR/schema.txt" |sqlite3 $TMPDIR/$DATABASENAME
 echo ".import $TMPDIR/alias.csv alias" |sqlite3 $TMPDIR/$DATABASENAME
 echo ".import $TMPDIR/domain.csv domain" |sqlite3 $TMPDIR/$DATABASENAME
 echo ".import $TMPDIR/mailbox.csv mailbox" |sqlite3 $TMPDIR/$DATABASENAME

 rm -rf $HTTPDIR/$DATABASENAME $HTTPDIR/$DATABASENAME.gpg $HTTPDIR/$DATABASENAME.sig
 cp $TMPDIR/$DATABASENAME $HTTPDIR/$DATABASENAME
 cd $HTTPDIR/
 gpg -b $DATABASENAME
 gpg -se -r E2E70CD8 -r D2FAA865 -r 6503BE11 $DATABASENAME
 rm -f $HTTPDIR/$DATABASENAME
 #md5sum $DATABASENAME > $DATABASENAME.md5
 #bzip2 $DATABASENAME
 #ssh odin.mattrude.com /home/matt/bin/sbin/postfix_sqlite_import.sh
fi</pre>
<p><strong>postfixdb-import.sh:</strong></p>
<pre>#/bin/bash
DBNAME=postfix.sqlite
DBDIR=/etc/postfix/database
URL=https://mail.mattrude.com/noc/postfix.sqlite
TMPDIR=/tmp/$DBNAME
LOGDIR=$TMPDIR

if [ ! -e $DBDIR ]; then
 mkdir -p $DBDIR
 chmod 700 $DBDIR
 chown 0:0 $DBDIR
fi

if [ ! -e $TMPDIR ]; then
 mkdir -p $TMPDIR
fi

if [ ! -e $LOGDIR ]; then
 mkdir -p $LOGDIR
fi

rm -rf $LOGDIR/postfix_import*.log $TMPDIR/$DBNAME.sig $DBDIR/$DBNAME.sig
wget --no-check-certificate -P $DBDIR $URL.sig > $LOGDIR/postfix_import_sig_download.log  2>&#038;1
SIGDOWNLOAD=$?

if [ $SIGDOWNLOAD != 0 ]; then
 echo "Did not download file $URL.sig; The host may be down or too busy."
 echo "Here is the download log:"
 cat $LOGDIR/postfix_import_sig_download.log
 echo ""
 echo "exiting script"
 exit 1
fi

cd $DBDIR
gpg --verify $DBNAME.sig > /dev/null 2>&#038;1
MD5STATUS=`echo $?`
if [ $MD5STATUS != '0' ]; then
 echo "Update needed, downloading updated $DBNAME."
 cd $TMPDIR
 rm -f $TMPDIR/$DBNAME.sig
 mv $DBDIR/$DBNAME.sig $TMPDIR/$DBNAME.sig
 rm -rf $TMPDIR/$DBNAME.gpg
 wget --no-check-certificate -P $TMPDIR $URL.gpg > $LOGDIR/postfix_import_download.log 2>&#038;1
 if [ -e $TMPDIR/$DBNAME.gpg ]; then
  cd $TMPDIR
  gpg $TMPDIR/$DBNAME.gpg >> $LOGDIR/postfix_import_download.log 2>&#038;1
  echo "sig test 2"
  ls -lh
  gpg --verify $DBNAME.sig > /dev/null 2>&#038;1
  SIGTEST=`echo $?`
  if [ $SIGTEST == '0' ]; then
   cd $DBDIR
   echo "Database file $DBNAME.gpg was successfully downloaded"
   ARCHIVEDATE=`date +%Y%m%d_%H%M`
   mv $DBDIR/$DBNAME $DBDIR/$DBNAME.$ARCHIVEDATE
   mv $TMPDIR/$DBNAME $DBDIR/$DBNAME
   bzip2 $DBDIR/$DBNAME.$ARCHIVEDATE
   chown 0:0 $DBDIR/$DBNAME
   chmod 666 $DBDIR/$DBNAME
   if [ -e $DBDIR/$DBNAME ]; then
    cd $DBDIR
    cp $TMPDIR/$DBNAME.sig $DBDIR/$DBNAME.sig
    MD5TEST2=`gpg --verify $DBNAME.sig |grep -v "gpg: Good signature" |wc -l`
    if [ $MD5TEST2 = '0' ]; then
     echo "$DBNAME was updated successfully!"
     rm -rf $DBDIR/$DBNAME.sig
    else
     echo "$DBNAME was downloaded successfully but the downloaded file dose not match the signature file."
     exit 1
    fi
   else
    echo "$DBNAME was not copied to the database location ($DBDIR)."
    exit 1
   fi
  else
   echo "Database $DBNAME was not updated, the signature check failed."
   echo "Here's the Signature Check Log:"
   cd $TMPDIR
   gpg --verify $DBNAME.sig
   rm -rf $TMPDIR/$DBNAME*
  fi
 else
  echo "Database $DBNAME was not updated, file was not downloaded."
  echo ""
  echo "Here's the download log:"
  cat $LOGDIR/postfix_import_download.log
  rm -rf $TMPDIR/$DBNAME*
  rm -rf $DBDIR/$DBNAME.sig
 fi
fi
rm -rf $TMPDIR/$DBNAME.sig $DBDIR/$DBNAME.sig</pre>
<a href="http://technology.mattrude.com/2011/05/postfix-mysql-to-sqlite-exportimport-scripts/">Postfix mySQL to SQLite export/import scripts</a> is a post from; <a href="http://technology.mattrude.com/">Matt&#039;s Technology Blog</a> which is not allowed to be copied on other sites.]]></content:encoded>
			<wfw:commentRss>http://technology.mattrude.com/2011/05/postfix-mysql-to-sqlite-exportimport-scripts/feed/</wfw:commentRss>
		<slash:comments>0</slash:comments>
		</item>
		<item>
		<title>WordPress Auto Backup Script</title>
		<link>http://technology.mattrude.com/2011/05/wordpress-auto-backup-script/</link>
		<comments>http://technology.mattrude.com/2011/05/wordpress-auto-backup-script/#comments</comments>
		<pubDate>Fri, 06 May 2011 01:22:10 +0000</pubDate>
		<dc:creator>Matt Rude</dc:creator>
				<category><![CDATA[Bash]]></category>
		<category><![CDATA[Scripts]]></category>
		<category><![CDATA[Backup]]></category>
		<category><![CDATA[Database]]></category>
		<category><![CDATA[MySQL]]></category>
		<category><![CDATA[php]]></category>
		<category><![CDATA[Rsync]]></category>
		<category><![CDATA[SQL]]></category>
		<category><![CDATA[WordPress]]></category>

		<guid isPermaLink="false">http://technology.mattrude.com/?p=4137</guid>
		<description><![CDATA[A quick backup script for WordPress. If you pass a config file containing the block of variables, the script will auto run for your install of WordPress. # /bin/bash BKNAME= DIR= DBHOST= DBNAME= DBUSER= DBPASS= # Backup Varibles BKDIR= # &#8230; <a href="http://technology.mattrude.com/2011/05/wordpress-auto-backup-script/">Continue reading <span class="meta-nav">&#8594;</span></a><a href="http://technology.mattrude.com/2011/05/wordpress-auto-backup-script/">WordPress Auto Backup Script</a> is a post from; <a href="http://technology.mattrude.com/">Matt&#039;s Technology Blog</a> which is not allowed to be copied on other sites.]]></description>
			<content:encoded><![CDATA[<p>A quick backup script for <a href="http://wordpress.org" target="_blank">WordPress</a>. If you pass a config file containing the block of variables, the script will auto run for your install of WordPress.</p>
<pre># /bin/bash
BKNAME=
DIR=
DBHOST=
DBNAME=
DBUSER=
DBPASS=

# Backup Varibles
BKDIR=

# Restore Variables
RSDIR=
RSARDIR=
RSUSER=
RSGROUP=

OFFSITE=

# Offsite Rsync
RSYNCHOST=
RSYNCUSERNAME=
RSYNCPASSWORD=

# Offiste SCP
SCPUSER=
SCPHOST=
SCPDIR=

if [ `date +%e` =  1 ]; then
 DAY=`date +%b`
 DATE=$DAY.`date +%Y-%m-%d`
else
 DAY=`date +%w`
 DATE=$DAY.`date +%Y-%m-%d`
fi

if [ -e $1 ]; then
 source $1
 CONFIGSTATUS="Using config file found at $1"
else
 echo "No Config file found"
 exit
fi

if [ ! -e $DB_HOST ]; then
  DBHOST=`grep "DB_HOST" $DIR/wp-config.php |sed "s/define('DB_HOST', '//" |sed "s/');//"`
  DBNAME=`grep "DB_NAME" $DIR/wp-config.php |sed "s/define('DB_NAME', '//" |sed "s/');//"`
  DBUSER=`grep "DB_USER" $DIR/wp-config.php |sed "s/define('DB_USER', '//" |sed "s/');//"`
  DBPASS=`grep "DB_PASS" $DIR/wp-config.php |sed "s/define('DB_PASSWORD', '//" |sed "s/');//"`
fi
BKDIRNAME=$BKNAME

if [ `date +%e` = 1 ]; then
 ARCHIVE=1
else
 if [ `date +%w` = 0 ]; then
  ARCHIVE=1
 else
  ARCHIVE=0
 fi
fi

if [ ! -e $BKDIR ];then
 mkdir -p $BKDIR
fi

chown -R root:root $DIR/
chown -R apache:apache $DIR/wp-content $DIR/wp-admin/update.php
chown apache:apache $DIR

if [ -e $DIR/sitemap.xml ]; then
  chown apache:apache $DIR/sitemap.xml
fi

if [ -e $DIR/sitemap.xml.gz ]; then
  chown apache:apache $DIR/sitemap.xml.gz
fi
case "$2" in
restore)
  rm -rf $RSARDIR/$BKNAME.$DAY.*
  rm -rf $RSDIR/$BKNAME
  rm -rf $DIR/$BKNAME.$DAY.*
  rm -rf $DIR/$DBNAME.*
  if [ ! -e $RSARDIR ]; then
   mkdir -p $RSARDIR
  fi
  export RSYNC_PASSWORD=$RSYNCPASSWORD
  rsync -rvzht --delete --stats $RSYNCUSERNAME@$RSYNCHOST::ibackup/odin/$BKNAME/$BKNAME.$DAY.* $RSARDIR/ --port=45873 >> $DIR/$BACKUPNAME.log 2>&#038;1
  cd $RSARDIR
  md5sum -c $BKNAME.$DATE.tgz.md5 > /dev/null 2>&#038;1
  RESTOREMD5=`echo $(($?))`
  if [ $RESTOREMD5 = 0 ]; then
   cd $RSDIR/
   cp $RSARDIR/$BKNAME.$DATE.tgz $RSDIR/$BKNAME.$DATE.tgz
   tar -xzf $RSDIR/$BKNAME.$DATE.tgz
   mv $RSDIR$DIR $RSDIR
   cd $RSDIR/$BKNAME
   md5sum -c $DBNAME.$DATE.sql.md5 > /dev/null 2>&#038;1
   RESTORESQLMD5=`echo $(($?))`
   if [ $RESTORESQLMD5 = 0 ]; then
    cd $RSDIR
    mysql -u $DBUSER -p$DBPASS $DBNAME < $RSDIR/$BKNAME/$DBNAME.$DATE.sql
    chown -R $RSUSER:$RSGROUP $RSDIR/$BKNAME
    rm -rf $RSDIR/var
    rm -rf $RSDIR/$BKNAME.$DATE.tgz
    rm -rf $RSDIR/$BKNAME/$DBNAME.$DATE.sql
    rm -rf $RSDIR/$BKNAME/$DBNAME.$DATE.log
   else
    echo "MD5 Check of the $BKNAME.$DATE.tgz SQL file failed"
    echo "Exiting $BKNAME with error code 1"
    rm -rf $RSDIR/$BKNAME.$DATE.tgz
    exit 1
   fi
  else
   echo "MD5 Check of the $BKNAME.$DATE.tgz file failed"
   echo "Exiting $BKNAME with error code 1"
   rm -rf $RSDIR/$BKNAME.$DATE.tgz
   exit 1
  fi
;;

backup)
  rm -rf $BKDIR/$BKNAME.$DAY.*
  rm -rf $DIR/$DBNAME.*

  for a in `echo "show tables;" |mysql -h $DBHOST -u $DBUSER -p$DBPASS $DBNAME -N`
  do
   echo "OPTIMIZE TABLE $a;" |mysql -h $DBHOST -u $DBUSER -p$DBPASS $DBNAME -N >> $DIR/$BKNAME.$DATE.log 2>&#038;1
  done
  mysqldump -h $DBHOST -u $DBUSER -p$DBPASS $DBNAME > $DIR/$DBNAME.$DATE.sql 2> $DIR/$BKNAME.$DATE.log
  a=$?
  mysqldump -h $DBHOST -u $DBUSER -p$DBPASS $DBNAME --xml > $DIR/$DBNAME.$DATE.xml 2> $DIR/$BKNAME.$DATE.log
  a2=$?
  cd $DIR/
  md5sum $DBNAME.$DATE.sql $DBNAME.$DATE.xml > $DBNAME.$DATE.sql.md5 2>> $DIR/$BKNAME.$DATE.log
  b=$?
  SQLERROR=`echo $(($a+$a2+$b))`
  if [ $SQLERROR != 0 ]; then
   BKNAME=$BKNAME-NOSQL
   echo "Exiting on SQL error"
   echo "DBHOST $DBHOST"
   echo "DBNAME $DBNAME"
   echo "DBUSER $DBUSER"
   echo "DBPASS $DBPASS"
   exit 1
  fi
  tar -czf $BKDIR/$BKNAME.$DATE.tgz --totals $DIR >> $DIR/$BKNAME.$DATE.log 2>&#038;1
  c=$?
  cd $BKDIR/
  md5sum $BKNAME.$DATE.tgz > $BKNAME.$DATE.tgz.md5 2>> $DIR/$BKNAME.$DATE.log
  d=$?
  TOTAL=`ls -lh $BKDIR/$BKNAME.$DATE.tgz |awk '{ print $5 }'`
  ERROR=`echo $(($a+$a2+$b+$c+$d))`
  if [ $ERROR = 0 ]; then
   STATUS=Good
  else
   STATUS=Failed
  fi

  echo "" >> $DIR/$BKNAME.$DATE.log
  echo "Starting GPG encryption" >> $DIR/$BKNAME.$DATE.log
  for a in $GPGKEY
  do
   GPGKEYD="$GPGKEYD -r $a"
  done
  #gpg -e -r $GPGKEY $BKDIR/$BKNAME.$DATE.tgz
  echo "" >> $DIR/$BKNAME.$DATE.log
  if [ $ARCHIVE = '0' ]; then
   case "$OFFSITE" in
    rsync|RSYNC)
      export RSYNC_PASSWORD=$RSYNCPASSWORD
      rsync -rvzht --delete --stats $BKDIR/ $RSYNCUSERNAME@$RSYNCHOST::ibackup/odin/$BKDIRNAME --port=45873 --exclude=Archive/ >> $DIR/$BACKUPNAME.log 2>&#038;1
    ;;

    scp|SCP)
      echo "" >> $DIR/$BKNAME.$DATE.log
      echo "Starting SCP Transmition" >> $DIR/$BKNAME.$DATE.log
      ssh $SCPUSER@$SCPHOST "mkdir -p $SCPDIR"
      ssh $SCPUSER@$SCPHOST "rm -f $SCPDIR/$BKNAME.$DAY.*"
      scp -q $BKDIR/$BKNAME.$DATE.tgz $SCPUSER@$SCPHOST:$SCPDIR/ 2>> $DIR/$BKNAME.$DATE.log
      scp -q $BKDIR/$BKNAME.$DATE.tgz.md5 $SCPUSER@$SCPHOST:$SCPDIR/ 2>> $DIR/$BKNAME.$DATE.log
      #ssh $SCPUSER@$SCPHOST "chmod 666 $SCPDIR/$BKNAME.$DAY.*"
      echo "" >> $DIR/$BKNAME.$DATE.log
    ;;
   esac
  fi

  echo "final error status is: $ERROR" >> $DIR/$BKNAME.$DATE.log
  sed '/tar: Removing leading */d' $DIR/$BKNAME.$DATE.log > $BKDIR/backuptmp.log
  #echo "INSERT INTO Backup_Log ( System, Backup_Job, Label, Output, Bytes, Status, Log ) VALUES ('`hostname -s`', 'Wiki', '$DIR', '$BKNAME.$DATE', '$TOTAL', '$STATUS', '`cat $BKDIR/backuptmp.log`');" |mysql -t -h localhost -u backup Status
  rm -rf $BKDIR/backuptmp.log
  rm -rf $DIR/$DBNAME.$DAY.*
  rm -rf $DIR/$BKNAME.$DAY.*
  ;;
*)
  echo "The valid commands are backup &#038; restore"
  exit 1
  ;;
esac</pre>
<a href="http://technology.mattrude.com/2011/05/wordpress-auto-backup-script/">WordPress Auto Backup Script</a> is a post from; <a href="http://technology.mattrude.com/">Matt&#039;s Technology Blog</a> which is not allowed to be copied on other sites.]]></content:encoded>
			<wfw:commentRss>http://technology.mattrude.com/2011/05/wordpress-auto-backup-script/feed/</wfw:commentRss>
		<slash:comments>1</slash:comments>
		</item>
		<item>
		<title>Dovecot Auto Update Script</title>
		<link>http://technology.mattrude.com/2011/05/dovecot-auto-update-script/</link>
		<comments>http://technology.mattrude.com/2011/05/dovecot-auto-update-script/#comments</comments>
		<pubDate>Wed, 04 May 2011 22:19:20 +0000</pubDate>
		<dc:creator>Matt Rude</dc:creator>
				<category><![CDATA[Bash]]></category>
		<category><![CDATA[Scripts]]></category>
		<category><![CDATA[Fedora]]></category>
		<category><![CDATA[php]]></category>
		<category><![CDATA[Programming]]></category>
		<category><![CDATA[SQLite]]></category>
		<category><![CDATA[Zlib]]></category>

		<guid isPermaLink="false">http://technology.mattrude.com/?p=4134</guid>
		<description><![CDATA[Here is a small auto update script for a Fedora build. This script will auto install all needed software and start Dovecot once it&#8217;s finished. #!/bin/bash DIR=/var/src if [ ! -e $DIR ]; then echo "Creating base directory $DIR" mkdir &#8230; <a href="http://technology.mattrude.com/2011/05/dovecot-auto-update-script/">Continue reading <span class="meta-nav">&#8594;</span></a><a href="http://technology.mattrude.com/2011/05/dovecot-auto-update-script/">Dovecot Auto Update Script</a> is a post from; <a href="http://technology.mattrude.com/">Matt&#039;s Technology Blog</a> which is not allowed to be copied on other sites.]]></description>
			<content:encoded><![CDATA[<p>Here is a small auto update script for a Fedora build.  This script will auto install all needed software and start Dovecot once it&#8217;s finished.</p>
<pre>#!/bin/bash

DIR=/var/src

if [ ! -e $DIR ]; then
  echo "Creating base directory $DIR"
  mkdir -p $DIR
fi

if [ ! -e $DIR/dovecot-2.0 ]; then
  echo "Dovecot 2.0 is not installed, Downloading a fresh copy of Dovecot 2.0"
  cd $DIR
  hg clone http://hg.dovecot.org/dovecot-2.0/ dovecot-2.0 > /dev/null
  if [ $? != 0 ]; then
    echo "Failed to download a fresh copy of Dovecot 2.0"
    exit 1
  fi
  echo "Installing any needed dependinces"
  yum -y install mercurial gcc autoconf automake libtool perl-Text-Iconv gettext gettext-devel gettext-libs openssl openssl-devel sqlite sqlite-devel zlib zlib-devel > /dev/null
  cd $DIR/dovecot-2.0
else
  cd $DIR/dovecot-2.0
  echo "Downloading updated version of Dovecot 2.0"
  echo -n "Current Version is: "
  dovecot --version
  hg pull -u > /dev/null
  if [ $? != 0 ]; then
    echo "Failed to update the Dovecot 2.0 install"
    exit 1
  fi
  dovecotver=0
  hgrepover=1
  dovecotver=`dovecot --version |awk '{print $2}' |sed 's/(//g' |sed 's/)//g'`
  hgrepover=`hg summary |grep parent |sed 's/:/ /g' |awk '{print $3}'`
  if [ ! $dovecotver ]; then
    dovecotver=0
  fi
  if [ ! $hgrepover ]; then
    hgrepover=1
  fi
  if [ $dovecotver == $hgrepover ]; then
    echo "The installed version and the downloaded version are both `dovecot --version`, not updating."
    exit 0
  else
    echo "The installed version is $dovecotver, but the current version on hg is $hgrepover, updating!"
  fi
  rm -rf *
  hg revert --all > /dev/null
  if [ $? != 0 ]; then
    echo "Failed to restore Dovecot 2.0 install"
    exit 1
  fi
fi

echo "Starting to comple Dovecot 2.0"
./autogen.sh > /dev/null 2> /dev/null
if [ $? != 0 ]; then
  echo "Failed to run autogen.sh for Dovecot 2.0"
  exit 1
fi

./configure --prefix=/usr --with-ssl=openssl --with-sqlite --with-mysql --with-ldap --with-zlib > /dev/null 2> /dev/null

if [ $? != 0 ]; then
  echo "Failed to run configure for Dovecot 2.0"
  exit 1
fi

make > /dev/null 2> /dev/null
if [ $? != 0 ]; then
  echo "Failed to run make for Dovecot 2.0"
  exit 1
fi

if [ ! -e $DIR/dovecot-2.0-pigeonhole ]; then
  echo "Dovecot Pigeonhole is not installed, Downloading a fresh copy of Dovecot Pigeonhole"
  cd $DIR
  hg clone http://hg.rename-it.nl/dovecot-2.0-pigeonhole/ > /dev/null
  if [ $? != 0 ]; then
    echo "Failed to download a fresh copy of Dovecot Pigeonhole"
    exit 1
  fi
  cd $DIR/dovecot-2.0-pigeonhole
else
  cd $DIR/dovecot-2.0-pigeonhole
  hg pull -u > /dev/null
  if [ $? != 0 ]; then
    echo "Failed to update the Dovecot Pigeonhole install"
    exit 1
  fi
  rm -rf *
  hg revert --all > /dev/null
  if [ $? != 0 ]; then
    echo "Failed to restore Dovecot Pigeonhole install"
    exit 1
  fi
fi

./autogen.sh > /dev/null 2> /dev/null
if [ $? != 0 ]; then
  echo "Failed to run autogen.sh for Sieve"
  exit 1
fi

./configure --prefix=/usr --with-dovecot=../dovecot-2.0 > /dev/null
if [ $? != 0 ]; then
  echo "Failed to run configure for Sieve"
  exit 1
fi

make > /dev/null 2> /dev/null
if [ $? != 0 ]; then
  echo "Failed to run make for Sieve"
  exit 1
fi

echo "Stopping Dovecot"
service dovecot stop
if [ $? != 0 ]; then
  echo "Failed to stop the running Dovecot proccess"
fi

cd /var/src/dovecot-2.0
make install > /dev/null 2> /dev/null
if [ $? != 0 ]; then
  echo "failed to install Dovecot"
  exit 1
fi

cd /var/src/dovecot-2.0-pigeonhole
make install > /dev/null 2> /dev/null
if [ $? != 0 ]; then
  echo "Failed to install Sieve"
  exit 1
fi

rm -rf /usr/local/etc/dovecot
ln -s /etc/dovecot /usr/local/etc/dovecot
rm -rf /usr/etc/dovecot
ln -s /etc/dovecot /usr/etc/dovecot

echo "Restarting Dovecot"
service dovecot start</pre>
<a href="http://technology.mattrude.com/2011/05/dovecot-auto-update-script/">Dovecot Auto Update Script</a> is a post from; <a href="http://technology.mattrude.com/">Matt&#039;s Technology Blog</a> which is not allowed to be copied on other sites.]]></content:encoded>
			<wfw:commentRss>http://technology.mattrude.com/2011/05/dovecot-auto-update-script/feed/</wfw:commentRss>
		<slash:comments>0</slash:comments>
		</item>
		<item>
		<title>Moving to the new Rackspace Load balancer</title>
		<link>http://technology.mattrude.com/2011/05/moving-to-the-new-rackspace-load-balancer/</link>
		<comments>http://technology.mattrude.com/2011/05/moving-to-the-new-rackspace-load-balancer/#comments</comments>
		<pubDate>Wed, 04 May 2011 21:29:22 +0000</pubDate>
		<dc:creator>Matt Rude</dc:creator>
				<category><![CDATA[General]]></category>
		<category><![CDATA[Application programming interface]]></category>
		<category><![CDATA[Cloud computing]]></category>
		<category><![CDATA[load balancing]]></category>
		<category><![CDATA[Rackspace]]></category>
		<category><![CDATA[Servers]]></category>
		<category><![CDATA[Site Management]]></category>

		<guid isPermaLink="false">http://technology.mattrude.com/?p=4109</guid>
		<description><![CDATA[Recently I have moved this site and others to a new load balancer solution by Rackspace (the company who also hosts the servers these sites run on). Prior to this change, I was running a single 1024mb ram/40gb server, with &#8230; <a href="http://technology.mattrude.com/2011/05/moving-to-the-new-rackspace-load-balancer/">Continue reading <span class="meta-nav">&#8594;</span></a><a href="http://technology.mattrude.com/2011/05/moving-to-the-new-rackspace-load-balancer/">Moving to the new Rackspace Load balancer</a> is a post from; <a href="http://technology.mattrude.com/">Matt&#039;s Technology Blog</a> which is not allowed to be copied on other sites.]]></description>
			<content:encoded><![CDATA[<p>Recently I have moved this site and others to a new <a title="Load Balancing on Wikipedia" href="http://en.wikipedia.org/wiki/Load_balancing_(computing)" target="_blank">load balancer</a> solution by <a href="http://www.rackspace.com/cloud/cloud_hosting_products/loadbalancers/?CMP=Google_rackspace+cloud+load+balancer_exact" target="_blank">Rackspace</a> (the company who also hosts the servers these sites run on).</p>
<p>Prior to this change, I was running a single 1024mb ram/40gb server, with this change I am now running two, fully master/master mirror 512mb/20gb servers, so the threw put should be a bit faster since there is now two.</p>
<p>I will hold my breath and let you know how it goes.</p>
<a href="http://technology.mattrude.com/2011/05/moving-to-the-new-rackspace-load-balancer/">Moving to the new Rackspace Load balancer</a> is a post from; <a href="http://technology.mattrude.com/">Matt&#039;s Technology Blog</a> which is not allowed to be copied on other sites.]]></content:encoded>
			<wfw:commentRss>http://technology.mattrude.com/2011/05/moving-to-the-new-rackspace-load-balancer/feed/</wfw:commentRss>
		<slash:comments>1</slash:comments>
		</item>
		<item>
		<title>Git: Creating and Importing Patches</title>
		<link>http://technology.mattrude.com/2011/05/git-creating-and-importing-patches/</link>
		<comments>http://technology.mattrude.com/2011/05/git-creating-and-importing-patches/#comments</comments>
		<pubDate>Mon, 02 May 2011 04:50:16 +0000</pubDate>
		<dc:creator>Matt Rude</dc:creator>
				<category><![CDATA[How-To's]]></category>
		<category><![CDATA[Configuration Management]]></category>
		<category><![CDATA[Git]]></category>
		<category><![CDATA[GitHub]]></category>
		<category><![CDATA[Revision control]]></category>
		<category><![CDATA[Software maintainer]]></category>
		<category><![CDATA[Tools]]></category>

		<guid isPermaLink="false">http://technology.mattrude.com/2011/05/git-creating-and-importing-patches/</guid>
		<description><![CDATA[Git allows you to create patch files that may be email or transfered in other ways the imported into a repository from outside the git chain. Creating a patch To create a patch file of the last commit git format-patch &#8230; <a href="http://technology.mattrude.com/2011/05/git-creating-and-importing-patches/">Continue reading <span class="meta-nav">&#8594;</span></a><a href="http://technology.mattrude.com/2011/05/git-creating-and-importing-patches/">Git: Creating and Importing Patches</a> is a post from; <a href="http://technology.mattrude.com/">Matt&#039;s Technology Blog</a> which is not allowed to be copied on other sites.]]></description>
			<content:encoded><![CDATA[<p>Git allows you to create patch files that may be email or transfered in other ways the imported into a repository from outside the git chain.</p>
<h6>Creating a patch</h6>
<p>To create a patch file of the last commit</p>
<pre>git format-patch -1 
gzip 0001-name_of_patch_file.patch
</pre>
<h6>Patching a file or directory</h6>
<pre>gzip -dc 0001-name_of_patch_file.patch.gz |git apply</pre>
<a href="http://technology.mattrude.com/2011/05/git-creating-and-importing-patches/">Git: Creating and Importing Patches</a> is a post from; <a href="http://technology.mattrude.com/">Matt&#039;s Technology Blog</a> which is not allowed to be copied on other sites.]]></content:encoded>
			<wfw:commentRss>http://technology.mattrude.com/2011/05/git-creating-and-importing-patches/feed/</wfw:commentRss>
		<slash:comments>0</slash:comments>
		</item>
		<item>
		<title>Git: Allow remote pushes to a checked out repository</title>
		<link>http://technology.mattrude.com/2011/05/git-allow-remote-pushes-to-a-checked-out-repository/</link>
		<comments>http://technology.mattrude.com/2011/05/git-allow-remote-pushes-to-a-checked-out-repository/#comments</comments>
		<pubDate>Sun, 01 May 2011 20:45:57 +0000</pubDate>
		<dc:creator>Matt Rude</dc:creator>
				<category><![CDATA[How-To's]]></category>
		<category><![CDATA[Configuration Management]]></category>
		<category><![CDATA[Git]]></category>
		<category><![CDATA[GitHub]]></category>
		<category><![CDATA[Repository clone]]></category>
		<category><![CDATA[Tools]]></category>

		<guid isPermaLink="false">http://technology.mattrude.com/?p=4089</guid>
		<description><![CDATA[In the remote repository you are planing on pushing to, run the following: git config receive.denycurrentbranch ignore Then download the Post-update.zip and unzip it. Now copy this file to your .git/hooks/ folder and make it executable. wget http://wiki.mattrude.com/images/d/de/Post-update.zip unzip Post-update.zip rm -rf Post-update.zip chmod &#8230; <a href="http://technology.mattrude.com/2011/05/git-allow-remote-pushes-to-a-checked-out-repository/">Continue reading <span class="meta-nav">&#8594;</span></a><a href="http://technology.mattrude.com/2011/05/git-allow-remote-pushes-to-a-checked-out-repository/">Git: Allow remote pushes to a checked out repository</a> is a post from; <a href="http://technology.mattrude.com/">Matt&#039;s Technology Blog</a> which is not allowed to be copied on other sites.]]></description>
			<content:encoded><![CDATA[<p>In the remote repository you are planing on pushing to, run the following:</p>
<pre>git config receive.denycurrentbranch ignore</pre>
<p>Then download the <a title="Post-update.zip" href="http://tech.mattrude.com/wp-content/uploads/2011/05/Post-update.zip">Post-update.zip</a> and unzip it. Now copy this file to your <em>.git/hooks/</em> folder and make it executable.</p>
<pre>wget <a href="http://wiki.mattrude.com/images/d/de/Post-update.zip" rel="nofollow">http://wiki.mattrude.com/images/d/de/Post-update.zip</a>
unzip Post-update.zip
rm -rf Post-update.zip
chmod 775 post-update
mv post-update .git/hooks/post-update</pre>
<p>You should now be able to remotely push to this repository without errors.</p>
<a href="http://technology.mattrude.com/2011/05/git-allow-remote-pushes-to-a-checked-out-repository/">Git: Allow remote pushes to a checked out repository</a> is a post from; <a href="http://technology.mattrude.com/">Matt&#039;s Technology Blog</a> which is not allowed to be copied on other sites.]]></content:encoded>
			<wfw:commentRss>http://technology.mattrude.com/2011/05/git-allow-remote-pushes-to-a-checked-out-repository/feed/</wfw:commentRss>
		<slash:comments>0</slash:comments>
		</item>
		<item>
		<title>Installing Git from Source</title>
		<link>http://technology.mattrude.com/2011/05/installing-git-from-source/</link>
		<comments>http://technology.mattrude.com/2011/05/installing-git-from-source/#comments</comments>
		<pubDate>Sun, 01 May 2011 16:32:03 +0000</pubDate>
		<dc:creator>Matt Rude</dc:creator>
				<category><![CDATA[How-To's]]></category>
		<category><![CDATA[CURL]]></category>
		<category><![CDATA[Filesystem Hierarchy Standard]]></category>
		<category><![CDATA[Git]]></category>
		<category><![CDATA[OpenSSH]]></category>
		<category><![CDATA[Tools]]></category>
		<category><![CDATA[Zlib]]></category>

		<guid isPermaLink="false">http://technology.mattrude.com/?p=4085</guid>
		<description><![CDATA[First install all needed dependence: yum install gcc perl-devel perl perl-DBD-Multi zlib-devel zlib openssh-server openssh libcurl expat expat-devel xinetd Now Download Git via a tarball: mkdir -p /var/src cd /var/src rm -rf git-git* wget --no-check-certificate https://github.com/git/git/tarball/master tar -xzf git-git* cd &#8230; <a href="http://technology.mattrude.com/2011/05/installing-git-from-source/">Continue reading <span class="meta-nav">&#8594;</span></a><a href="http://technology.mattrude.com/2011/05/installing-git-from-source/">Installing Git from Source</a> is a post from; <a href="http://technology.mattrude.com/">Matt&#039;s Technology Blog</a> which is not allowed to be copied on other sites.]]></description>
			<content:encoded><![CDATA[<p>First install all needed dependence:</p>
<pre>yum install gcc perl-devel perl perl-DBD-Multi zlib-devel zlib openssh-server 
openssh libcurl expat expat-devel xinetd</pre>
<p>Now Download Git via a tarball:</p>
<pre>mkdir -p /var/src
cd /var/src
rm -rf git-git*
wget --no-check-certificate <a href="https://nodeload.github.com/git/git/tarball/master" rel="nofollow">https://github.com/git/git/tarball/master</a>
tar -xzf git-git*
cd git-git*</pre>
<p>Or if you already have git installed, via git it&#8217;s self:</p>
<pre>mkdir -p /var/src
git clone <a href="git://git.kernel.org/pub/scm/git/git.git" rel="nofollow">git://git.kernel.org/pub/scm/git/git.git</a>
cd git</pre>
<p>Now compile the install.</p>
<pre>make configure
./configure --prefix=/usr
make
make install</pre>
<a href="http://technology.mattrude.com/2011/05/installing-git-from-source/">Installing Git from Source</a> is a post from; <a href="http://technology.mattrude.com/">Matt&#039;s Technology Blog</a> which is not allowed to be copied on other sites.]]></content:encoded>
			<wfw:commentRss>http://technology.mattrude.com/2011/05/installing-git-from-source/feed/</wfw:commentRss>
		<slash:comments>0</slash:comments>
		</item>
		<item>
		<title>Turning off { HYPERLINK http://example.com } in Outlook 2010</title>
		<link>http://technology.mattrude.com/2010/12/turning-off-hyperlink-httpexample-com-in-outlook-2010/</link>
		<comments>http://technology.mattrude.com/2010/12/turning-off-hyperlink-httpexample-com-in-outlook-2010/#comments</comments>
		<pubDate>Tue, 21 Dec 2010 14:51:17 +0000</pubDate>
		<dc:creator>Matt Rude</dc:creator>
				<category><![CDATA[How-To's]]></category>
		<category><![CDATA[Microsoft Office 2003]]></category>
		<category><![CDATA[Microsoft Office 2007]]></category>
		<category><![CDATA[Microsoft Office 2010]]></category>
		<category><![CDATA[Microsoft Outlook]]></category>
		<category><![CDATA[Office 2003]]></category>
		<category><![CDATA[Outlook 2010]]></category>

		<guid isPermaLink="false">http://technology.mattrude.com/?p=4232</guid>
		<description><![CDATA[The other day while working in Outlook 2010, I ran into a issue where, when I pasted a link in my message the link would change to { HYPERLINK http://example.com } A Google search on this problem should several ways of resolving it in Office &#8230; <a href="http://technology.mattrude.com/2010/12/turning-off-hyperlink-httpexample-com-in-outlook-2010/">Continue reading <span class="meta-nav">&#8594;</span></a><a href="http://technology.mattrude.com/2010/12/turning-off-hyperlink-httpexample-com-in-outlook-2010/">Turning off { HYPERLINK http://example.com } in Outlook 2010</a> is a post from; <a href="http://technology.mattrude.com/">Matt&#039;s Technology Blog</a> which is not allowed to be copied on other sites.]]></description>
			<content:encoded><![CDATA[<p>The other day while working in Outlook 2010, I ran into a issue where, when I pasted a link in my message the link would change to <code>{ HYPERLINK http://example.com }</code></p>
<p>A Google search on this problem should several ways of resolving it in Office 2007 or Office 2003, but those methods would not work in Office 2010 as the menus have all changed dramatically (they are now all in a ribbon). So I needed to start experimenting.  after much trial and error, I figured out that&#8230;</p>
<p>To turn off this &#8220;feature&#8221; press <strong>CTRL-F9</strong></p>
<p>To turn on this &#8220;feature&#8221; press <strong>CTRL-F8</strong></p>
<p><strong><br />
</strong></p>
<a href="http://technology.mattrude.com/2010/12/turning-off-hyperlink-httpexample-com-in-outlook-2010/">Turning off { HYPERLINK http://example.com } in Outlook 2010</a> is a post from; <a href="http://technology.mattrude.com/">Matt&#039;s Technology Blog</a> which is not allowed to be copied on other sites.]]></content:encoded>
			<wfw:commentRss>http://technology.mattrude.com/2010/12/turning-off-hyperlink-httpexample-com-in-outlook-2010/feed/</wfw:commentRss>
		<slash:comments>1</slash:comments>
		</item>
		<item>
		<title>LDAP PHP Change Password Page</title>
		<link>http://technology.mattrude.com/2010/11/ldap-php-change-password-webpage/</link>
		<comments>http://technology.mattrude.com/2010/11/ldap-php-change-password-webpage/#comments</comments>
		<pubDate>Tue, 30 Nov 2010 06:00:00 +0000</pubDate>
		<dc:creator>Matt Rude</dc:creator>
				<category><![CDATA[PHP]]></category>
		<category><![CDATA[Scripts]]></category>
		<category><![CDATA[ldap]]></category>
		<category><![CDATA[Password]]></category>
		<category><![CDATA[password change]]></category>
		<category><![CDATA[Protocols]]></category>
		<category><![CDATA[Security]]></category>
		<category><![CDATA[Server]]></category>

		<guid isPermaLink="false">http://technology.mattrude.com/?p=4052</guid>
		<description><![CDATA[Here is my quick page to allow users to change their own passwords.  To use this page, the LDAP server should to be local (as I am not connecting via SSL) and the page should to be on a secure &#8230; <a href="http://technology.mattrude.com/2010/11/ldap-php-change-password-webpage/">Continue reading <span class="meta-nav">&#8594;</span></a><a href="http://technology.mattrude.com/2010/11/ldap-php-change-password-webpage/">LDAP PHP Change Password Page</a> is a post from; <a href="http://technology.mattrude.com/">Matt&#039;s Technology Blog</a> which is not allowed to be copied on other sites.]]></description>
			<content:encoded><![CDATA[<p>Here is my quick page to allow users to change their own passwords.  To use this page, the LDAP server should to be local (as I am not connecting via SSL) and the page should to be on a secure site (https://).</p>
<pre class="brush: php; title: ; notranslate">
&lt;?php

/**
 *   LDAP PHP Change Password Webpage
 *   @author:   Matt Rude &lt;http://mattrude.com&gt;
 *   @website:  http://technology.mattrude.com/2010/11/ldap-php-change-password-webpage/
 *
 *
 *              GNU GENERAL PUBLIC LICENSE
 *                 Version 2, June 1991
 *
 * Copyright (C) 1989, 1991 Free Software Foundation, Inc.,
 * 51 Franklin Street, Fifth Floor, Boston, MA 02110-1301 USA
 * Everyone is permitted to copy and distribute verbatim copies
 * of this license document, but changing it is not allowed.
 */

$message = array();
$message_css = &quot;&quot;;

function changePassword($user,$oldPassword,$newPassword,$newPasswordCnf){
  global $message;
  global $message_css;

  $server = &quot;localhost&quot;;
  $dn = &quot;ou=People,dc=example&quot;;
   
  error_reporting(0);
  ldap_connect($server);
  $con = ldap_connect($server);
  ldap_set_option($con, LDAP_OPT_PROTOCOL_VERSION, 3);
  
  // bind anon and find user by uid
  $user_search = ldap_search($con,$dn,&quot;(|(uid=$user)(mail=$user))&quot;);
  $user_get = ldap_get_entries($con, $user_search);
  $user_entry = ldap_first_entry($con, $user_search);
  $user_dn = ldap_get_dn($con, $user_entry);
  $user_id = $user_get[0][&quot;uid&quot;][0];
  $user_givenName = $user_get[0][&quot;givenName&quot;][0];
  $user_search_arry = array( &quot;*&quot;, &quot;ou&quot;, &quot;uid&quot;, &quot;mail&quot;, &quot;passwordRetryCount&quot;, &quot;passwordhistory&quot; );
  $user_search_filter = &quot;(|(uid=$user_id)(mail=$user))&quot;;
  $user_search_opt = ldap_search($con,$user_dn,$user_search_filter,$user_search_arry);
  $user_get_opt = ldap_get_entries($con, $user_search_opt);
  $passwordRetryCount = $user_get_opt[0][&quot;passwordRetryCount&quot;][0];
  $passwordhistory = $user_get_opt[0][&quot;passwordhistory&quot;][0];
  
  //$message[] = &quot;Username: &quot; . $user_id;
  //$message[] = &quot;DN: &quot; . $user_dn;
  //$message[] = &quot;Current Pass: &quot; . $oldPassword;
  //$message[] = &quot;New Pass: &quot; . $newPassword;
  
  /* Start the testing */
  if ( $passwordRetryCount == 3 ) {
    $message[] = &quot;Error E101 - Your Account is Locked Out!!!&quot;;
    return false;
  }
  if (ldap_bind($con, $user_dn, $oldPassword) === false) {
    $message[] = &quot;Error E101 - Current Username or Password is wrong.&quot;;
    return false;
  }
  if ($newPassword != $newPasswordCnf ) {
    $message[] = &quot;Error E102 - Your New passwords do not match!&quot;;
    return false;
  }
  $encoded_newPassword = &quot;{SHA}&quot; . base64_encode( pack( &quot;H*&quot;, sha1( $newPassword ) ) );
  $history_arr = ldap_get_values($con,$user_dn,&quot;passwordhistory&quot;);
  if ( $history_arr ) {
    $message[] = &quot;Error E102 - Your New password matches one of the last 10 passwords that you used, you MUST come up with a new password.&quot;;
    return false;
  }
  if (strlen($newPassword) &lt; 8 ) {
    $message[] = &quot;Error E103 - Your new password is too short!&lt;br/&gt;Your password must be at least 8 characters long.&quot;;
    return false;
  }
  if (!preg_match(&quot;/[0-9]/&quot;,$newPassword)) {
    $message[] = &quot;Error E104 - Your new password must contain at least one number.&quot;;
    return false;
  }
  if (!preg_match(&quot;/[a-zA-Z]/&quot;,$newPassword)) {
    $message[] = &quot;Error E105 - Your new password must contain at least one letter.&quot;;
    return false;
  }
  if (!preg_match(&quot;/[A-Z]/&quot;,$newPassword)) {
    $message[] = &quot;Error E106 - Your new password must contain at least one uppercase letter.&quot;;
    return false;
  }
  if (!preg_match(&quot;/[a-z]/&quot;,$newPassword)) {
    $message[] = &quot;Error E107 - Your new password must contain at least one lowercase letter.&quot;;
    return false;
  }
  if (!$user_get) {
    $message[] = &quot;Error E200 - Unable to connect to server, you may not change your password at this time, sorry.&quot;;
    return false;
  }
 
  $auth_entry = ldap_first_entry($con, $user_search);
  $mail_addresses = ldap_get_values($con, $auth_entry, &quot;mail&quot;);
  $given_names = ldap_get_values($con, $auth_entry, &quot;givenName&quot;);
  $password_history = ldap_get_values($con, $auth_entry, &quot;passwordhistory&quot;);
  $mail_address = $mail_addresses[0];
  $first_name = $given_names[0];
  
  /* And Finally, Change the password */
  $entry = array();
  $entry[&quot;userPassword&quot;] = &quot;$newPassword&quot;;
  
  if (ldap_modify($con,$user_dn,$entry) === false){
    $error = ldap_error($con);
    $errno = ldap_errno($con);
    $message[] = &quot;E201 - Your password cannot be change, please contact the administrator.&quot;;
    $message[] = &quot;$errno - $error&quot;;
  } else {
    $message_css = &quot;yes&quot;;
    mail($mail_address,&quot;Password change notice&quot;,&quot;Dear $first_name,
Your password on http://support.example.com for account $user_id was just changed. If you did not make this change, please contact support@example.com.
If you were the one who changed your password, you may disregard this message.

Thanks
-Matt&quot;);
    $message[] = &quot;The password for $user_id has been changed.&lt;br/&gt;An informational email as been sent to $mail_address.&lt;br/&gt;Your new password is now fully Active.&quot;;
  }
}

?&gt;
&lt;!DOCTYPE html PUBLIC &quot;-//W3C//DTD XHTML 1.0 Strict//EN&quot; &quot;http://www.w3.org/TR/xhtml1/DTD/xhtml1-strict.dtd&quot;&gt;
&lt;html xmlns=&quot;http://www.w3.org/1999/xhtml&quot; xml:lang=&quot;en&quot; lang=&quot;en&quot;&gt;
&lt;head&gt;
&lt;title&gt;Password Change Page&lt;/title&gt;
&lt;style type=&quot;text/css&quot;&gt;
body { font-family: Verdana,Arial,Courier New; font-size: 0.7em; }
th { text-align: right; padding: 0.8em; }
#container { text-align: center; width: 500px; margin: 5% auto; }
.msg_yes { margin: 0 auto; text-align: center; color: green; background: #D4EAD4; border: 1px solid green; border-radius: 10px; margin: 2px; }
.msg_no { margin: 0 auto; text-align: center; color: red; background: #FFF0F0; border: 1px solid red; border-radius: 10px; margin: 2px; }
&lt;/style&gt;
&lt;meta http-equiv=&quot;Content-Type&quot; content=&quot;text/html; charset=utf-8&quot;/&gt;
&lt;/head&gt;
&lt;body&gt;
&lt;div id=&quot;container&quot;&gt;
&lt;h2&gt;Password Change Page&lt;/h2&gt;
&lt;p&gt;Your new password must be 8 characters long or longer and have at least:&lt;br/&gt;
one capital letter, one lowercase letter, &amp;amp; one number.&lt;br/&gt;
You must use a new password, your current password&lt;br/&gt;can not be the same as your new password.&lt;/p&gt;
&lt;?php
      if (isset($_POST[&quot;submitted&quot;])) {
        changePassword($_POST['username'],$_POST['oldPassword'],$_POST['newPassword1'],$_POST['newPassword2']);
        global $message_css;
        if ($message_css == &quot;yes&quot;) {
          ?&gt;&lt;div class=&quot;msg_yes&quot;&gt;&lt;?php
         } else {
          ?&gt;&lt;div class=&quot;msg_no&quot;&gt;&lt;?php
          $message[] = &quot;Your password was not changed.&quot;;
        }
        foreach ( $message as $one ) { echo &quot;&lt;p&gt;$one&lt;/p&gt;&quot;; }
      ?&gt;&lt;/div&gt;&lt;?php
      } ?&gt;
&lt;form action=&quot;&lt;?php print $_SERVER['PHP_SELF']; ?&gt;&quot; name=&quot;passwordChange&quot; method=&quot;post&quot;&gt;
&lt;table style=&quot;width: 400px; margin: 0 auto;&quot;&gt;
&lt;tr&gt;&lt;th&gt;Username or Email Address:&lt;/th&gt;&lt;td&gt;&lt;input name=&quot;username&quot; type=&quot;text&quot; size=&quot;20px&quot; autocomplete=&quot;off&quot; /&gt;&lt;/td&gt;&lt;/tr&gt;
&lt;tr&gt;&lt;th&gt;Current password:&lt;/th&gt;&lt;td&gt;&lt;input name=&quot;oldPassword&quot; size=&quot;20px&quot; type=&quot;password&quot; /&gt;&lt;/td&gt;&lt;/tr&gt;
&lt;tr&gt;&lt;th&gt;New password:&lt;/th&gt;&lt;td&gt;&lt;input name=&quot;newPassword1&quot; size=&quot;20px&quot; type=&quot;password&quot; /&gt;&lt;/td&gt;&lt;/tr&gt;
&lt;tr&gt;&lt;th&gt;New password (again):&lt;/th&gt;&lt;td&gt;&lt;input name=&quot;newPassword2&quot; size=&quot;20px&quot; type=&quot;password&quot; /&gt;&lt;/td&gt;&lt;/tr&gt;
&lt;tr&gt;&lt;td colspan=&quot;2&quot; style=&quot;text-align: center;&quot; &gt;
&lt;input name=&quot;submitted&quot; type=&quot;submit&quot; value=&quot;Change Password&quot;/&gt;
&lt;button onclick=&quot;$('frm').action='changepassword.php';$('frm').submit();&quot;&gt;Cancel&lt;/button&gt;
&lt;/td&gt;&lt;/tr&gt;
&lt;/table&gt;
&lt;/form&gt;
&lt;/div&gt;
&lt;/body&gt;
&lt;/html&gt;
</pre>
<ul>
<li>Also at: http://gist.github.com/657334</li>
</ul>
<a href="http://technology.mattrude.com/2010/11/ldap-php-change-password-webpage/">LDAP PHP Change Password Page</a> is a post from; <a href="http://technology.mattrude.com/">Matt&#039;s Technology Blog</a> which is not allowed to be copied on other sites.]]></content:encoded>
			<wfw:commentRss>http://technology.mattrude.com/2010/11/ldap-php-change-password-webpage/feed/</wfw:commentRss>
		<slash:comments>1</slash:comments>
		</item>
		<item>
		<title>Controlling a TV-IP400 Camera with ZoneMinder</title>
		<link>http://technology.mattrude.com/2010/11/controlling-a-tv-ip400-camera-with-zoneminder/</link>
		<comments>http://technology.mattrude.com/2010/11/controlling-a-tv-ip400-camera-with-zoneminder/#comments</comments>
		<pubDate>Fri, 19 Nov 2010 17:36:37 +0000</pubDate>
		<dc:creator>Matt Rude</dc:creator>
				<category><![CDATA[How-To's]]></category>
		<category><![CDATA[Application programming interface]]></category>
		<category><![CDATA[Camera]]></category>
		<category><![CDATA[IP address]]></category>
		<category><![CDATA[webcam]]></category>
		<category><![CDATA[zoneminder]]></category>

		<guid isPermaLink="false">http://technology.mattrude.com/?p=4054</guid>
		<description><![CDATA[This post was originally posted on the now offline site www.sfpeter.com.  All of the below work is from that site, and is not mine. This setup also works on version 1.24.2 (the current version as of writing this post).  You may also download &#8230; <a href="http://technology.mattrude.com/2010/11/controlling-a-tv-ip400-camera-with-zoneminder/">Continue reading <span class="meta-nav">&#8594;</span></a><a href="http://technology.mattrude.com/2010/11/controlling-a-tv-ip400-camera-with-zoneminder/">Controlling a TV-IP400 Camera with ZoneMinder</a> is a post from; <a href="http://technology.mattrude.com/">Matt&#039;s Technology Blog</a> which is not allowed to be copied on other sites.]]></description>
			<content:encoded><![CDATA[<p>This post was originally posted on the now offline site <a href="http://www.sfpeter.com/2008/07/new-trendnet-tv-ip400w-controller-for-zoneminder-123x/">www.sfpeter.com</a>.  All of the below work is from that site, and is not mine.</p>
<p>This setup also works on version 1.24.2 (the current version as of writing this post).  You may also download the archive I created this post from <a href="http://tech.mattrude.com/wp-content/uploads/2010/11/Trendnet_TV-IP400_-_Zoneminder_1.23.x.pdf" target="_blank">here</a>.</p>
<blockquote><p>I’ve finally gotten around to rewriting my old Trendnet PTZ controller for Zoneminder 1.22.x to support the new API for Zoneminder 1.23.x. It includes all the old features (moving the camera in horizontally, vertically, diagonally, and going to preset and home position) as well as a new bonus feature: move the camera simply by clicking a point in the live video that you want the camera to recenter on. This is not extremely accurate, but good enough for most uses, and faster than having to click an arrow 20 times.</p>
<p>Here’s the basic steps on how to get this Trendnet TV-IP400 / IV-IP400W driver to work in ZoneMinder:</p>
<ul>
<li>Make sure you have indeed version 1.23.x. You can see this in the title of the main console window. If you are still using version 1.22.x, either <a href="http://www.zoneminder.com/downloads" target="_blank">upgrade</a> your ZoneMinder or use my old driver.</li>
</ul>
<ul>
<li><a href="http://tech.mattrude.com/wp-content/uploads/2010/11/Zoneminder-Trendnet.1.23.x.zip" target="_blank">Download the driver file</a> here, and store it in the right directory. For me (having compiled Zoneminder from source on ubuntu) that location is /usr/local/perl/5.8.8/ZoneMinder/control. If that location doesn’t exist on your system, you can do a search for another camera driver such as Visca.pm and store the TVIP400.pm file in the same location.</li>
</ul>
<ul>
<li>Create a new camera for your TV-IP400 if you haven’t already done so. The source tab looks something like this:</li>
</ul>
<p><a href="http://tech.mattrude.com/wp-content/uploads/2010/11/source_tab.png"><img class="alignnone size-full wp-image-4057" title="source_tab" src="http://tech.mattrude.com/wp-content/uploads/2010/11/source_tab.png" alt="" width="440" height="445" /></a></p>
<p>Make sure you change the IP address and port number if necessary. You will need to make sure that access control is turned off by the way.</p>
<p>If you had enabled the ZM_OPT_CONTROL setting in the system options screen, you will also see a control tab in the camera config window. This tab should look like this:</p>
<p><a href="http://tech.mattrude.com/wp-content/uploads/2010/11/control_tab.png"><img class="alignnone size-full wp-image-4058" title="control_tab" src="http://tech.mattrude.com/wp-content/uploads/2010/11/control_tab.png" alt="" width="440" height="445" /></a></p>
<p>Again, make sure you set the correct IP address (the same as what you set in the source tab). You won’t have a TV-IP400 option yet in the Control Type dropdown, so click on ‘edit’ there and let’s create one.</p>
<p>In the Control Capabilities window, click ‘Add New Control’. Then set the settings in the Main and Move tabs as follows:</p>
<p><a href="http://tech.mattrude.com/wp-content/uploads/2010/11/main_tab.png"><img class="alignnone size-full wp-image-4059" title="main_tab" src="http://tech.mattrude.com/wp-content/uploads/2010/11/main_tab.png" alt="" width="440" height="561" /></a></p>
<p><a href="http://tech.mattrude.com/wp-content/uploads/2010/11/move_tab.png"><img class="alignnone size-full wp-image-4060" title="move_tab" src="http://tech.mattrude.com/wp-content/uploads/2010/11/move_tab.png" alt="" width="440" height="561" /></a></p>
<p>In the Pan tab, only check the ‘Can Pan’ option and leave the rest blank.<br />
In the Tilt tab, only check the ‘Can Tilt’ option.</p>
<p>All options in the Zoom, Focus, White and Iris tabs can be left blank since none of these features are supported.</p>
<p>The Presets tab should be set as follows:</p>
<p><a href="http://tech.mattrude.com/wp-content/uploads/2010/11/presets_tab.png"><img class="alignnone size-full wp-image-4061" title="presets_tab" src="http://tech.mattrude.com/wp-content/uploads/2010/11/presets_tab.png" alt="" width="440" height="561" /></a></p>
<p>Though you can’t actually set presets through ZoneMinder, you can move the camera to presets that you’ve configured through the Trendnet web interface. I’m only using 5 presets but I believe you could access all 24 presets that the Trendnet supports.</p>
<p>That’s all! Save the configuration, and give your new controllable camera a spin in ZoneMinder. Let me know how you like it.</p>
<p>Thanks to Armando Oritz for his help in testing this driver.</p></blockquote>
<a href="http://technology.mattrude.com/2010/11/controlling-a-tv-ip400-camera-with-zoneminder/">Controlling a TV-IP400 Camera with ZoneMinder</a> is a post from; <a href="http://technology.mattrude.com/">Matt&#039;s Technology Blog</a> which is not allowed to be copied on other sites.]]></content:encoded>
			<wfw:commentRss>http://technology.mattrude.com/2010/11/controlling-a-tv-ip400-camera-with-zoneminder/feed/</wfw:commentRss>
		<slash:comments>0</slash:comments>
		</item>
		<item>
		<title>VBScript to change &#8216;My Computer&#8217; to the actual Computer&#8217;s name</title>
		<link>http://technology.mattrude.com/2010/10/vbscript-to-change-my-computer-to-the-actual-computers-name/</link>
		<comments>http://technology.mattrude.com/2010/10/vbscript-to-change-my-computer-to-the-actual-computers-name/#comments</comments>
		<pubDate>Sat, 16 Oct 2010 19:56:11 +0000</pubDate>
		<dc:creator>Matt Rude</dc:creator>
				<category><![CDATA[Scripts]]></category>
		<category><![CDATA[VBScript]]></category>
		<category><![CDATA[Globally unique identifier]]></category>
		<category><![CDATA[Microsoft]]></category>
		<category><![CDATA[Microsoft Windows]]></category>
		<category><![CDATA[Operating system]]></category>
		<category><![CDATA[Registry Key]]></category>
		<category><![CDATA[webserver]]></category>
		<category><![CDATA[Windows Registry]]></category>

		<guid isPermaLink="false">http://technology.mattrude.com/?p=4045</guid>
		<description><![CDATA['============================================================================== 'LANG : VBScript 'NAME : computername.vbs 'DESCRIPTION: Changes My Computer to actual Computername '============================================================================== Option Explicit Const HKEY_CLASSES_ROOT = &#38;H80000000 Const HKEY_CURRENT_USER = &#38;H80000001 Const HKEY_LOCAL_MACHINE = &#38;H80000002 Const HKEY_USERS = &#38;H80000003 Const HKEY_PERFORMANCE_DATA = &#38;H80000004 Const HKEY_CURRENT_CONFIG = &#8230; <a href="http://technology.mattrude.com/2010/10/vbscript-to-change-my-computer-to-the-actual-computers-name/">Continue reading <span class="meta-nav">&#8594;</span></a><a href="http://technology.mattrude.com/2010/10/vbscript-to-change-my-computer-to-the-actual-computers-name/">VBScript to change &#8216;My Computer&#8217; to the actual Computer&#8217;s name</a> is a post from; <a href="http://technology.mattrude.com/">Matt&#039;s Technology Blog</a> which is not allowed to be copied on other sites.]]></description>
			<content:encoded><![CDATA[<pre>'==============================================================================
'LANG       : VBScript
'NAME       : computername.vbs
'DESCRIPTION: Changes My Computer to actual Computername
'==============================================================================
Option Explicit

Const HKEY_CLASSES_ROOT = &amp;H80000000
Const HKEY_CURRENT_USER = &amp;H80000001
Const HKEY_LOCAL_MACHINE = &amp;H80000002
Const HKEY_USERS = &amp;H80000003
Const HKEY_PERFORMANCE_DATA = &amp;H80000004
Const HKEY_CURRENT_CONFIG = &amp;H80000005
Const HKEY_DYN_DATA = &amp;H80000006

Const REG_NONE = 0
Const REG_SZ = 1
Const REG_EXPAND_SZ = 2
Const REG_BINARY = 3
Const REG_DWORD = 4
Const REG_DWORD_LITTLE_ENDIAN = 4
Const REG_DWORD_BIG_ENDIAN = 5
Const REG_LINK = 6
Const REG_MULTI_SZ = 7
Const REG_RESOURCE_LIST = 8

Dim strComputer
Dim objReg
Dim strKeyPath
Dim strValueName
Dim strValue

'==============================================================================
'==============================================================================
'Main Body
On error resume next

strComputer = "."
'wscript.echo "Binding to Registry Provider"
Set objReg=GetObject("winmgmts:{impersonationLevel=impersonate}!\" &amp; strComputer &amp; "rootdefault:StdRegProv")

strKeyPath = "CLSID{20D04FE0-3AEA-1069-A2D8-08002B30309D}"
strValueName = "LocalizedString"
strValue = "%COMPUTERNAME%"

'wscript.echo "Setting Registry Key"
objReg.SetExpandedStringValue HKEY_CLASSES_ROOT,strKeyPath,strValueName,strValue

if Err.Number &lt;&gt; 0 then
    wscript.echo ("Error # " &amp; CStr(Err.Number) &amp; " " &amp; Err.Description)
End if

wscript.quit (Err.number)</pre>
<a href="http://technology.mattrude.com/2010/10/vbscript-to-change-my-computer-to-the-actual-computers-name/">VBScript to change &#8216;My Computer&#8217; to the actual Computer&#8217;s name</a> is a post from; <a href="http://technology.mattrude.com/">Matt&#039;s Technology Blog</a> which is not allowed to be copied on other sites.]]></content:encoded>
			<wfw:commentRss>http://technology.mattrude.com/2010/10/vbscript-to-change-my-computer-to-the-actual-computers-name/feed/</wfw:commentRss>
		<slash:comments>2</slash:comments>
		</item>
		<item>
		<title>Git: Creating an unattached branch with no history</title>
		<link>http://technology.mattrude.com/2010/10/git-creating-an-unattached-branch-with-no-history/</link>
		<comments>http://technology.mattrude.com/2010/10/git-creating-an-unattached-branch-with-no-history/#comments</comments>
		<pubDate>Sat, 09 Oct 2010 00:56:43 +0000</pubDate>
		<dc:creator>Matt Rude</dc:creator>
				<category><![CDATA[How-To's]]></category>
		<category><![CDATA[Branch]]></category>
		<category><![CDATA[Command-line interface]]></category>
		<category><![CDATA[Configuration Management]]></category>
		<category><![CDATA[Git]]></category>
		<category><![CDATA[GitHub]]></category>
		<category><![CDATA[README]]></category>
		<category><![CDATA[Repository clone]]></category>
		<category><![CDATA[Tools]]></category>

		<guid isPermaLink="false">http://technology.mattrude.com/?p=3263</guid>
		<description><![CDATA[From inside your git repository, after you have committed all you changes, run: git symbolic-ref HEAD refs/heads/name-of-new-branch rm .git/index git clean -fdx You will now have an empty directory waiting for your first commit. So if your creating a new &#8230; <a href="http://technology.mattrude.com/2010/10/git-creating-an-unattached-branch-with-no-history/">Continue reading <span class="meta-nav">&#8594;</span></a><a href="http://technology.mattrude.com/2010/10/git-creating-an-unattached-branch-with-no-history/">Git: Creating an unattached branch with no history</a> is a post from; <a href="http://technology.mattrude.com/">Matt&#039;s Technology Blog</a> which is not allowed to be copied on other sites.]]></description>
			<content:encoded><![CDATA[<p>From inside your git repository, after you have committed all you changes, run:</p>
<pre>git symbolic-ref HEAD refs/heads/name-of-new-branch
rm .git/index
git clean -fdx</pre>
<p>You will now have an empty directory waiting for your first commit.</p>
<p>So if your creating a new branch for github pages for example, you would run:</p>
<pre>git symbolic-ref HEAD refs/heads/gh-pages
rm -f .git/index
git clean -fdx</pre>
<p>And your ready to start creating your page.</p>
<a href="http://technology.mattrude.com/2010/10/git-creating-an-unattached-branch-with-no-history/">Git: Creating an unattached branch with no history</a> is a post from; <a href="http://technology.mattrude.com/">Matt&#039;s Technology Blog</a> which is not allowed to be copied on other sites.]]></content:encoded>
			<wfw:commentRss>http://technology.mattrude.com/2010/10/git-creating-an-unattached-branch-with-no-history/feed/</wfw:commentRss>
		<slash:comments>0</slash:comments>
		</item>
		<item>
		<title>Installing Microsoft Exchange Tools on Windows XP</title>
		<link>http://technology.mattrude.com/2010/10/installing-exchange-tools/</link>
		<comments>http://technology.mattrude.com/2010/10/installing-exchange-tools/#comments</comments>
		<pubDate>Tue, 05 Oct 2010 12:59:55 +0000</pubDate>
		<dc:creator>Matt Rude</dc:creator>
				<category><![CDATA[How-To's]]></category>
		<category><![CDATA[Compact Disc]]></category>
		<category><![CDATA[Intel 80386]]></category>
		<category><![CDATA[Microsoft]]></category>
		<category><![CDATA[Microsoft Exchange]]></category>
		<category><![CDATA[Microsoft Exchange Server]]></category>
		<category><![CDATA[Microsoft Windows]]></category>
		<category><![CDATA[Windows XP]]></category>

		<guid isPermaLink="false">http://technology.mattrude.com/?p=3247</guid>
		<description><![CDATA[To start out, you will need the Microsoft Exchange 2003 CD or a network location with it installed On your Windows XP system, go to the your Exchange 2003 CD or network location and run the setup located &#60;drive&#62;: setupi386setup.exe Once it &#8230; <a href="http://technology.mattrude.com/2010/10/installing-exchange-tools/">Continue reading <span class="meta-nav">&#8594;</span></a><a href="http://technology.mattrude.com/2010/10/installing-exchange-tools/">Installing Microsoft Exchange Tools on Windows XP</a> is a post from; <a href="http://technology.mattrude.com/">Matt&#039;s Technology Blog</a> which is not allowed to be copied on other sites.]]></description>
			<content:encoded><![CDATA[<p>To start out, you will need the Microsoft Exchange 2003 CD or a network location with it installed</p>
<li>On your Windows XP system, go to the your Exchange 2003 CD or network location and run the setup located</li>
<p><span style="font-family: Georgia, 'Bitstream Charter', serif; line-height: 23px; font-size: 14px;"> </span></p>
<ul>
<li>&lt;<em>drive</em>&gt;:  setupi386setup.exe</li>
</ul>
<li>Once it loads on the <strong>Component Selection</strong> page, do the following:</li>
<ul>
<li>Under <strong>Component Name</strong>, locate <strong>Microsoft  Exchange</strong>. In the corresponding <strong>Action </strong>column, select  <strong>Custom</strong>.</li>
<li>Under <strong>Component Name</strong>, locate <strong>Microsoft Exchange  System Management Tools</strong>. In the corresponding <strong>Action</strong> column, select <strong>Install</strong> (see figure below).
<div><strong>Microsoft Exchange System Management Tools installation  option<br />
</strong><a rel="attachment wp-att-3248" href="http://technology.mattrude.com/2010/10/installing-exchange-tools/exchange_tools_install_screen/"><img class="size-full wp-image-3248 alignnone" title="Exchange_tools_install_screen" src="http://tech.mattrude.com/wp-content/uploads/2010/10/Exchange_tools_install_screen.gif" alt="" width="582" height="470" /></a><br />
<!--src=[..local33b759ca-c9c0-4f8e-8012-78cf0b97189e.gif]--></div>
</li>
</ul>
<li>Click <strong>Next.</strong></li>
<li>The rest is just hitting next or install until your finished.</li>
<p>.</p>
<a href="http://technology.mattrude.com/2010/10/installing-exchange-tools/">Installing Microsoft Exchange Tools on Windows XP</a> is a post from; <a href="http://technology.mattrude.com/">Matt&#039;s Technology Blog</a> which is not allowed to be copied on other sites.]]></content:encoded>
			<wfw:commentRss>http://technology.mattrude.com/2010/10/installing-exchange-tools/feed/</wfw:commentRss>
		<slash:comments>1</slash:comments>
		</item>
		<item>
		<title>Typekit Font’s for WordPress</title>
		<link>http://technology.mattrude.com/2010/10/typekit-fonts-wordpress-plugin/</link>
		<comments>http://technology.mattrude.com/2010/10/typekit-fonts-wordpress-plugin/#comments</comments>
		<pubDate>Sat, 02 Oct 2010 20:13:27 +0000</pubDate>
		<dc:creator>Matt Rude</dc:creator>
				<category><![CDATA[Plugins]]></category>
		<category><![CDATA[WordPress]]></category>
		<category><![CDATA[Typekit Fonts]]></category>
		<category><![CDATA[WordPress Plugin]]></category>

		<guid isPermaLink="false">http://technology.mattrude.com/?p=3129</guid>
		<description><![CDATA[This small plugin provides Typekit fonts to a website by adding the needed java code to the pages Place this file in your plugin directory, then check out Appearance -&#62; Fonts in from your WordPress admin. Typekit Font’s for WordPress &#8230; <a href="http://technology.mattrude.com/2010/10/typekit-fonts-wordpress-plugin/">Continue reading <span class="meta-nav">&#8594;</span></a><a href="http://technology.mattrude.com/2010/10/typekit-fonts-wordpress-plugin/">Typekit Font’s for WordPress</a> is a post from; <a href="http://technology.mattrude.com/">Matt&#039;s Technology Blog</a> which is not allowed to be copied on other sites.]]></description>
			<content:encoded><![CDATA[<p>This small plugin provides <a href="https://typekit.com/" target="_blank">Typekit</a> fonts to a website by adding the needed java code to the pages</p>
<p>Place this file in your plugin directory, then check out Appearance -&gt; Fonts in from your WordPress admin.<br />
<script src="https://gist.github.com/585087.js?file=typekit-fonts.php"></script></p>
<a href="http://technology.mattrude.com/2010/10/typekit-fonts-wordpress-plugin/">Typekit Font’s for WordPress</a> is a post from; <a href="http://technology.mattrude.com/">Matt&#039;s Technology Blog</a> which is not allowed to be copied on other sites.]]></content:encoded>
			<wfw:commentRss>http://technology.mattrude.com/2010/10/typekit-fonts-wordpress-plugin/feed/</wfw:commentRss>
		<slash:comments>2</slash:comments>
		</item>
		<item>
		<title>WordPress Sitemap Generator</title>
		<link>http://technology.mattrude.com/2010/09/wordpress-sitemap-generator-plugin/</link>
		<comments>http://technology.mattrude.com/2010/09/wordpress-sitemap-generator-plugin/#comments</comments>
		<pubDate>Fri, 17 Sep 2010 23:08:02 +0000</pubDate>
		<dc:creator>Matt Rude</dc:creator>
				<category><![CDATA[WordPress]]></category>
		<category><![CDATA[WordPress Plugin]]></category>

		<guid isPermaLink="false">http://technology.mattrude.com/?p=3165</guid>
		<description><![CDATA[This plugin will create a sitemap for your WordPress site (http://example.com/sitemap.xml). This was setup for a multisite install, but should work fine on a single install. First, create a file named sitemap-generator.php in your mu-plugins directory, (or your plugins directory &#8230; <a href="http://technology.mattrude.com/2010/09/wordpress-sitemap-generator-plugin/">Continue reading <span class="meta-nav">&#8594;</span></a><a href="http://technology.mattrude.com/2010/09/wordpress-sitemap-generator-plugin/">WordPress Sitemap Generator</a> is a post from; <a href="http://technology.mattrude.com/">Matt&#039;s Technology Blog</a> which is not allowed to be copied on other sites.]]></description>
			<content:encoded><![CDATA[<p>This plugin will create a sitemap for your WordPress site (<code>http://example.com/sitemap.xml</code>). This was setup for a multisite install, but should work fine on a single install.</p>
<p>First, create a file named sitemap-generator.php in your <code>mu-plugins</code> directory, (or your <code>plugins</code> directory if your using a single install WordPress setup) and past the below into it.</p>
<p><script src="https://gist.github.com/585087.js?file=sitemap-generator.php"></script></p>
<p>After create a new directory named <code>templates</code> and past the below in a file feed-sitemap.php in it.</p>
<p><script src="https://gist.github.com/585087.js?file=feed-sitemap.php"></script></p>
<a href="http://technology.mattrude.com/2010/09/wordpress-sitemap-generator-plugin/">WordPress Sitemap Generator</a> is a post from; <a href="http://technology.mattrude.com/">Matt&#039;s Technology Blog</a> which is not allowed to be copied on other sites.]]></content:encoded>
			<wfw:commentRss>http://technology.mattrude.com/2010/09/wordpress-sitemap-generator-plugin/feed/</wfw:commentRss>
		<slash:comments>0</slash:comments>
		</item>
		<item>
		<title>WordPress Favicon Plugin</title>
		<link>http://technology.mattrude.com/2010/09/wordpress-favicon-plugin/</link>
		<comments>http://technology.mattrude.com/2010/09/wordpress-favicon-plugin/#comments</comments>
		<pubDate>Fri, 17 Sep 2010 21:52:20 +0000</pubDate>
		<dc:creator>Matt Rude</dc:creator>
				<category><![CDATA[WordPress]]></category>
		<category><![CDATA[WordPress Plugin]]></category>

		<guid isPermaLink="false">http://technology.mattrude.com/?p=3145</guid>
		<description><![CDATA[One more quick plugin setup for multi site builds of WordPress. Just drop this in your mu-plugins folder. This plugin will first look for a local favicon, if there is none, it will go to Gravatar to see if the &#8230; <a href="http://technology.mattrude.com/2010/09/wordpress-favicon-plugin/">Continue reading <span class="meta-nav">&#8594;</span></a><a href="http://technology.mattrude.com/2010/09/wordpress-favicon-plugin/">WordPress Favicon Plugin</a> is a post from; <a href="http://technology.mattrude.com/">Matt&#039;s Technology Blog</a> which is not allowed to be copied on other sites.]]></description>
			<content:encoded><![CDATA[<p>One more quick plugin setup for multi site builds of WordPress.  Just drop this in your mu-plugins folder. This plugin will first look for a local favicon, if there is none, it will go to Gravatar to see if the Admin_Email as a gravator, if it doesn&#8217;t, it will use the default from the main install.  If a user must have a special favicon you may drop it in there files directory, for example <code>blogs.dir/5/files</code>.<br />
<script src="http://gist.github.com/585087.js?file=favicon.php"></script></p>
<a href="http://technology.mattrude.com/2010/09/wordpress-favicon-plugin/">WordPress Favicon Plugin</a> is a post from; <a href="http://technology.mattrude.com/">Matt&#039;s Technology Blog</a> which is not allowed to be copied on other sites.]]></content:encoded>
			<wfw:commentRss>http://technology.mattrude.com/2010/09/wordpress-favicon-plugin/feed/</wfw:commentRss>
		<slash:comments>0</slash:comments>
		</item>
		<item>
		<title>WordPress Feedburner Plugin</title>
		<link>http://technology.mattrude.com/2010/09/wordpress-feedburner-plugin/</link>
		<comments>http://technology.mattrude.com/2010/09/wordpress-feedburner-plugin/#comments</comments>
		<pubDate>Fri, 17 Sep 2010 18:08:40 +0000</pubDate>
		<dc:creator>Matt Rude</dc:creator>
				<category><![CDATA[WordPress]]></category>
		<category><![CDATA[WordPress Plugin]]></category>

		<guid isPermaLink="false">http://technology.mattrude.com/?p=3135</guid>
		<description><![CDATA[This is a quick plugin that will allow your users to use the Feedburner service on your their WordPress site.  Just place this file in your mu-plugins or plugins folder then checkout Settings -&#62; Reading WordPress Feedburner Plugin is a &#8230; <a href="http://technology.mattrude.com/2010/09/wordpress-feedburner-plugin/">Continue reading <span class="meta-nav">&#8594;</span></a><a href="http://technology.mattrude.com/2010/09/wordpress-feedburner-plugin/">WordPress Feedburner Plugin</a> is a post from; <a href="http://technology.mattrude.com/">Matt&#039;s Technology Blog</a> which is not allowed to be copied on other sites.]]></description>
			<content:encoded><![CDATA[<p>This is a quick plugin that will allow your users to use the Feedburner service on your their WordPress site.  Just place this file in your mu-plugins or plugins folder then checkout Settings -&gt; Reading</p>
<p><script src="http://gist.github.com/585087.js?file=feedburner.php"></script></p>
<a href="http://technology.mattrude.com/2010/09/wordpress-feedburner-plugin/">WordPress Feedburner Plugin</a> is a post from; <a href="http://technology.mattrude.com/">Matt&#039;s Technology Blog</a> which is not allowed to be copied on other sites.]]></content:encoded>
			<wfw:commentRss>http://technology.mattrude.com/2010/09/wordpress-feedburner-plugin/feed/</wfw:commentRss>
		<slash:comments>0</slash:comments>
		</item>
		<item>
		<title>Google Adsense for Search</title>
		<link>http://technology.mattrude.com/2010/09/google-adsense-for-search/</link>
		<comments>http://technology.mattrude.com/2010/09/google-adsense-for-search/#comments</comments>
		<pubDate>Fri, 17 Sep 2010 17:58:00 +0000</pubDate>
		<dc:creator>Matt Rude</dc:creator>
				<category><![CDATA[General]]></category>
		<category><![CDATA[AdSense]]></category>
		<category><![CDATA[Advertising]]></category>
		<category><![CDATA[Google]]></category>
		<category><![CDATA[Search Engines]]></category>
		<category><![CDATA[Searching]]></category>
		<category><![CDATA[World Wide Web]]></category>

		<guid isPermaLink="false">http://technology.mattrude.com/?p=3133</guid>
		<description><![CDATA[Has anyone had any luck getting Google Adsense for Search working on a MediaWiki site?  If so, what plugin did you use?  Or did you write your own? Google Adsense for Search is a post from; Matt&#039;s Technology Blog which &#8230; <a href="http://technology.mattrude.com/2010/09/google-adsense-for-search/">Continue reading <span class="meta-nav">&#8594;</span></a><a href="http://technology.mattrude.com/2010/09/google-adsense-for-search/">Google Adsense for Search</a> is a post from; <a href="http://technology.mattrude.com/">Matt&#039;s Technology Blog</a> which is not allowed to be copied on other sites.]]></description>
			<content:encoded><![CDATA[<p>Has anyone had any luck getting Google Adsense for Search working on a MediaWiki site?  If so, what plugin did you use?  Or did you write your own?</p>
<a href="http://technology.mattrude.com/2010/09/google-adsense-for-search/">Google Adsense for Search</a> is a post from; <a href="http://technology.mattrude.com/">Matt&#039;s Technology Blog</a> which is not allowed to be copied on other sites.]]></content:encoded>
			<wfw:commentRss>http://technology.mattrude.com/2010/09/google-adsense-for-search/feed/</wfw:commentRss>
		<slash:comments>0</slash:comments>
		</item>
		<item>
		<title>Shredder Turns Discarded Office Memos into Fresh New Pencil</title>
		<link>http://technology.mattrude.com/2010/09/3122/</link>
		<comments>http://technology.mattrude.com/2010/09/3122/#comments</comments>
		<pubDate>Thu, 16 Sep 2010 17:03:47 +0000</pubDate>
		<dc:creator>Matt Rude</dc:creator>
				<category><![CDATA[General]]></category>
		<category><![CDATA[Paper]]></category>
		<category><![CDATA[Paper shredder]]></category>
		<category><![CDATA[Shopping]]></category>

		<guid isPermaLink="false">http://technology.mattrude.com/?p=3122</guid>
		<description><![CDATA[Shredder Turns Discarded Office Memos into Fresh New Pencil. Shredder Turns Discarded Office Memos into Fresh New Pencil is a post from; Matt&#039;s Technology Blog which is not allowed to be copied on other sites.<a href="http://technology.mattrude.com/2010/09/3122/">Shredder Turns Discarded Office Memos into Fresh New Pencil</a> is a post from; <a href="http://technology.mattrude.com/">Matt&#039;s Technology Blog</a> which is not allowed to be copied on other sites.]]></description>
			<content:encoded><![CDATA[<p><a href="http://www.popsci.com/gadgets/article/2010-09/new-shredder-turns-discarded-office-memos-fresh-new-pencils" target="_blank">Shredder Turns Discarded Office Memos into Fresh New Pencil</a>.</p>
<a href="http://technology.mattrude.com/2010/09/3122/">Shredder Turns Discarded Office Memos into Fresh New Pencil</a> is a post from; <a href="http://technology.mattrude.com/">Matt&#039;s Technology Blog</a> which is not allowed to be copied on other sites.]]></content:encoded>
			<wfw:commentRss>http://technology.mattrude.com/2010/09/3122/feed/</wfw:commentRss>
		<slash:comments>0</slash:comments>
		</item>
		<item>
		<title>Remotely Reboot Windows with a VBS script</title>
		<link>http://technology.mattrude.com/2010/08/remotely-reboot-a-windows-with-a-vbs-script/</link>
		<comments>http://technology.mattrude.com/2010/08/remotely-reboot-a-windows-with-a-vbs-script/#comments</comments>
		<pubDate>Sun, 22 Aug 2010 17:09:03 +0000</pubDate>
		<dc:creator>Matt Rude</dc:creator>
				<category><![CDATA[Scripts]]></category>
		<category><![CDATA[VBScript]]></category>
		<category><![CDATA[Windows]]></category>
		<category><![CDATA[Windows XP]]></category>

		<guid isPermaLink="false">http://mattrude.com/?p=3039</guid>
		<description><![CDATA[Remotely Reboot Windows with a VBS script is a post from; Matt&#039;s Technology Blog which is not allowed to be copied on other sites.<a href="http://technology.mattrude.com/2010/08/remotely-reboot-a-windows-with-a-vbs-script/">Remotely Reboot Windows with a VBS script</a> is a post from; <a href="http://technology.mattrude.com/">Matt&#039;s Technology Blog</a> which is not allowed to be copied on other sites.]]></description>
			<content:encoded><![CDATA[<p><script src="http://gist.github.com/585164.js"> </script></p>
<a href="http://technology.mattrude.com/2010/08/remotely-reboot-a-windows-with-a-vbs-script/">Remotely Reboot Windows with a VBS script</a> is a post from; <a href="http://technology.mattrude.com/">Matt&#039;s Technology Blog</a> which is not allowed to be copied on other sites.]]></content:encoded>
			<wfw:commentRss>http://technology.mattrude.com/2010/08/remotely-reboot-a-windows-with-a-vbs-script/feed/</wfw:commentRss>
		<slash:comments>0</slash:comments>
		</item>
		<item>
		<title>Disabling Plugin Stylesheet</title>
		<link>http://technology.mattrude.com/2010/08/disabling-plugin-stylesheet/</link>
		<comments>http://technology.mattrude.com/2010/08/disabling-plugin-stylesheet/#comments</comments>
		<pubDate>Thu, 19 Aug 2010 17:25:39 +0000</pubDate>
		<dc:creator>Matt Rude</dc:creator>
				<category><![CDATA[How-To's]]></category>
		<category><![CDATA[WordPress]]></category>

		<guid isPermaLink="false">http://devel.mattrude.com/?p=38</guid>
		<description><![CDATA[You must have seen that WordPress plugins can slow your site down with additional HTTP Requests such as adding their own stylesheet. For advanced users, who are adding custom styles for the announcement, you do not need to have an &#8230; <a href="http://technology.mattrude.com/2010/08/disabling-plugin-stylesheet/">Continue reading <span class="meta-nav">&#8594;</span></a><a href="http://technology.mattrude.com/2010/08/disabling-plugin-stylesheet/">Disabling Plugin Stylesheet</a> is a post from; <a href="http://technology.mattrude.com/">Matt&#039;s Technology Blog</a> which is not allowed to be copied on other sites.]]></description>
			<content:encoded><![CDATA[<p>You must have seen that WordPress plugins can slow your site down with additional HTTP Requests such as adding their own stylesheet. For advanced users, who are adding custom styles for the announcement, you do not need to have an additional HTTP request for a useless stylesheet. Then add the following function in your theme’s <em>functions.php</em> file:<br />
<script src="http://gist.github.com/585155.js"> </script></p>
<a href="http://technology.mattrude.com/2010/08/disabling-plugin-stylesheet/">Disabling Plugin Stylesheet</a> is a post from; <a href="http://technology.mattrude.com/">Matt&#039;s Technology Blog</a> which is not allowed to be copied on other sites.]]></content:encoded>
			<wfw:commentRss>http://technology.mattrude.com/2010/08/disabling-plugin-stylesheet/feed/</wfw:commentRss>
		<slash:comments>0</slash:comments>
		</item>
		<item>
		<title>Video: Adding Pictures to Gallery3</title>
		<link>http://technology.mattrude.com/2010/08/video-adding-pictures-to-gallery3/</link>
		<comments>http://technology.mattrude.com/2010/08/video-adding-pictures-to-gallery3/#comments</comments>
		<pubDate>Sun, 08 Aug 2010 04:52:22 +0000</pubDate>
		<dc:creator>Matt Rude</dc:creator>
				<category><![CDATA[How-To's]]></category>
		<category><![CDATA[Web Design and Development]]></category>

		<guid isPermaLink="false">http://mattrude.com/?p=2791</guid>
		<description><![CDATA[A quick How-To video I made on how to add pictures to a Gallery3 photo gallery. Video: Adding Pictures to Gallery3 is a post from; Matt&#039;s Technology Blog which is not allowed to be copied on other sites.<a href="http://technology.mattrude.com/2010/08/video-adding-pictures-to-gallery3/">Video: Adding Pictures to Gallery3</a> is a post from; <a href="http://technology.mattrude.com/">Matt&#039;s Technology Blog</a> which is not allowed to be copied on other sites.]]></description>
			<content:encoded><![CDATA[<p>A quick How-To video I made on how to add pictures to a Gallery3 photo gallery.</p>
<p>    <iframe src="http://player.vimeo.com/video/13059599" width="620" height="395" frameborder="0" webkitAllowFullScreen mozallowfullscreen allowFullScreen></iframe></p>
<a href="http://technology.mattrude.com/2010/08/video-adding-pictures-to-gallery3/">Video: Adding Pictures to Gallery3</a> is a post from; <a href="http://technology.mattrude.com/">Matt&#039;s Technology Blog</a> which is not allowed to be copied on other sites.]]></content:encoded>
			<wfw:commentRss>http://technology.mattrude.com/2010/08/video-adding-pictures-to-gallery3/feed/</wfw:commentRss>
		<slash:comments>0</slash:comments>
		</item>
		<item>
		<title>Adding a Twitter feed</title>
		<link>http://technology.mattrude.com/2010/08/playing-with-adding-a-twitter-feed-direc/</link>
		<comments>http://technology.mattrude.com/2010/08/playing-with-adding-a-twitter-feed-direc/#comments</comments>
		<pubDate>Tue, 03 Aug 2010 17:30:34 +0000</pubDate>
		<dc:creator>Matt Rude</dc:creator>
				<category><![CDATA[Plugins]]></category>
		<category><![CDATA[WordPress]]></category>
		<category><![CDATA[Twitter]]></category>

		<guid isPermaLink="false">http://devel.mattrude.com/2010/08/03/playing-with-adding-a-twitter-feed-direc/</guid>
		<description><![CDATA[Playing with adding a twitter feed directly into my theme. Adding a Twitter feed is a post from; Matt&#039;s Technology Blog which is not allowed to be copied on other sites.<a href="http://technology.mattrude.com/2010/08/playing-with-adding-a-twitter-feed-direc/">Adding a Twitter feed</a> is a post from; <a href="http://technology.mattrude.com/">Matt&#039;s Technology Blog</a> which is not allowed to be copied on other sites.]]></description>
			<content:encoded><![CDATA[<p>Playing with adding a twitter feed directly into my theme.<br />
<script src="http://gist.github.com/585160.js"> </script></p>
<a href="http://technology.mattrude.com/2010/08/playing-with-adding-a-twitter-feed-direc/">Adding a Twitter feed</a> is a post from; <a href="http://technology.mattrude.com/">Matt&#039;s Technology Blog</a> which is not allowed to be copied on other sites.]]></content:encoded>
			<wfw:commentRss>http://technology.mattrude.com/2010/08/playing-with-adding-a-twitter-feed-direc/feed/</wfw:commentRss>
		<slash:comments>0</slash:comments>
		</item>
		<item>
		<title>Display EXIF Data on WordPress Gallery Post Image</title>
		<link>http://technology.mattrude.com/2010/07/display-exif-data-on-wordpress-gallery-post-image-2/</link>
		<comments>http://technology.mattrude.com/2010/07/display-exif-data-on-wordpress-gallery-post-image-2/#comments</comments>
		<pubDate>Thu, 15 Jul 2010 15:34:52 +0000</pubDate>
		<dc:creator>Matt Rude</dc:creator>
				<category><![CDATA[How-To's]]></category>
		<category><![CDATA[database function]]></category>
		<category><![CDATA[digital photograph]]></category>
		<category><![CDATA[exif data]]></category>
		<category><![CDATA[shutter speed]]></category>

		<guid isPermaLink="false">http://technology.mattrude.com/?p=5169</guid>
		<description><![CDATA[In this post I will talk about how to display EXIF data for an image in a WordPress post or native gallery. In order to do this you need to modify your sites theme. First start by adding the below &#8230; <a href="http://technology.mattrude.com/2010/07/display-exif-data-on-wordpress-gallery-post-image-2/">Continue reading <span class="meta-nav">&#8594;</span></a><a href="http://technology.mattrude.com/2010/07/display-exif-data-on-wordpress-gallery-post-image-2/">Display EXIF Data on WordPress Gallery Post Image</a> is a post from; <a href="http://technology.mattrude.com/">Matt&#039;s Technology Blog</a> which is not allowed to be copied on other sites.]]></description>
			<content:encoded><![CDATA[<p>In this post I will talk about how to <strong>display <a href="http://en.wikipedia.org/wiki/Exchangeable_image_file_format" target="_blank">EXIF</a></strong> data for an image in a <a class="zem_slink" title="WordPress" href="http://wordpress.org" rel="homepage">WordPress</a> post or native gallery.</p>
<p>In order to do this you need to modify your sites theme.</p>
<p><strong>First start by adding the below function to your themes function.php file.</strong></p>
<pre class="brush: plain; title: ; notranslate">
/*********************************************************************************
Using WordPress functions to retrieve the extracted EXIF
information from database
*/
function mdr_exif() { ?&gt;
&lt;div id=&quot;exif&quot;&gt;
&lt;h3 class='comment-title exif-title'&gt;&lt; ?php _e('Images EXIF Data', 'millytheme'); ?&gt;&lt;/h3&gt;
&lt;div id=&quot;exif-data&quot;&gt;
&lt; ?php
      $imgmeta = wp_get_attachment_metadata( $id );
      // Convert the shutter speed retrieve from database to fraction
      $image_shutter_speed = $imgmeta['image_meta']['shutter_speed'];
      if ($image_shutter_speed &gt; 0) {
        if ((1 / $image_shutter_speed) &gt; 1) {
          if ((number_format((1 / $image_shutter_speed), 1)) == 1.3
            or number_format((1 / $image_shutter_speed), 1) == 1.5
            or number_format((1 / $image_shutter_speed), 1) == 1.6
            or number_format((1 / $image_shutter_speed), 1) == 2.5){
            $pshutter = &quot;1/&quot; . number_format((1 / $image_shutter_speed), 1, '.', '') .&quot; &quot;.__('second', 'millytheme');
          } else {
            $pshutter = &quot;1/&quot; . number_format((1 / $image_shutter_speed), 0, '.', '') .&quot; &quot;.__('second', 'millytheme');
          }
        } else {
          $pshutter = $image_shutter_speed .&quot; &quot;.__('seconds', 'millytheme');
        }
      }

      // Start to display EXIF and IPTC data of digital photograph
      echo &quot;&lt;p&gt;&quot; . date(&quot;d-M-Y H:i:s&quot;, $imgmeta['image_meta']['created_timestamp']).&quot;&lt;/p&gt;&quot;;
      echo &quot;&lt;p&gt;&quot; . $imgmeta['image_meta']['camera'].&quot;&lt;/p&gt;&quot;;
      echo &quot;&lt;p&gt;&quot; . $imgmeta['image_meta']['focal_length'].&quot;mm&lt;/p&gt;&quot;;
      echo &quot;&lt;p&gt;f/&quot; . $imgmeta['image_meta']['aperture'].&quot;&lt;/p&gt;&quot;;
      echo &quot;&lt;p&gt;&quot; . $imgmeta['image_meta']['iso'].&quot;&lt;/p&gt;&quot;;
      echo &quot;&lt;p&gt;&quot; . $pshutter . &quot;&lt;/p&gt;&quot;
      ?&gt;
&lt;/div&gt;
&lt;div id=&quot;exif-lable&quot;&gt;
&lt; ?php // EXIF Titles
      echo &quot;&lt;p&gt;&lt;span&gt;&quot;.__('Date Taken:', 'millytheme').&quot;&lt;/span&gt;&quot;;
      echo &quot;&lt;p&gt;&lt;span&gt;&quot;.__('Camera:', 'millytheme').&quot;&lt;/span&gt;&quot;;
      echo &quot;&lt;/p&gt;&lt;p&gt;&lt;span&gt;&quot;.__('Focal Length:', 'millytheme').&quot;&lt;/span&gt;&quot;;
      echo &quot;&lt;/p&gt;&lt;p&gt;&lt;span&gt;&quot;.__('Aperture:', 'millytheme').&quot;&lt;/span&gt;&quot;;
      echo &quot;&lt;/p&gt;&lt;p&gt;&lt;span&gt;&quot;.__('ISO:', 'millytheme').&quot;&lt;/span&gt;&quot;;
      echo &quot;&lt;/p&gt;&lt;p&gt;&lt;span&gt;&quot;.__('Shutter Speed:', 'millytheme').&quot;&lt;/span&gt;&quot;; ?&gt;
&lt;/p&gt;&lt;/div&gt;
&lt;/div&gt;
&lt; ?php }</pre>
<p><strong>Then add the following to your style.css</strong></p>
<pre class="brush: css; title: ; notranslate">
/*EXIF table*/
#exif { overflow: hidden; margin: 0; padding: 0 10px 0 0; }
#exif-lable { margin: 0 0 0 15px; width: 125px; }
#exif-lable p { margin: 0; }
#exif-lable span { font-weight:bold; }
#exif-data { overflow: hidden; margin: 0; float: right; width: 540px; }
#exif-data p { margin: 0 10px; }
</pre>
<p>And lastly you need to add the function you created above to your <em>image.php</em> file. This may be the most difficult part. Depending on your theme, you need to find a space for the <em>EXIF</em> table to live on the image page. You will also need to play with the style.css entry you added to make it look correctly on your site.</p>
<a href="http://technology.mattrude.com/2010/07/display-exif-data-on-wordpress-gallery-post-image-2/">Display EXIF Data on WordPress Gallery Post Image</a> is a post from; <a href="http://technology.mattrude.com/">Matt&#039;s Technology Blog</a> which is not allowed to be copied on other sites.]]></content:encoded>
			<wfw:commentRss>http://technology.mattrude.com/2010/07/display-exif-data-on-wordpress-gallery-post-image-2/feed/</wfw:commentRss>
		<slash:comments>2</slash:comments>
		</item>
		<item>
		<title>Git Commit eMail Notifications</title>
		<link>http://technology.mattrude.com/2010/05/git-commit-email-notifications/</link>
		<comments>http://technology.mattrude.com/2010/05/git-commit-email-notifications/#comments</comments>
		<pubDate>Tue, 04 May 2010 03:35:31 +0000</pubDate>
		<dc:creator>Matt Rude</dc:creator>
				<category><![CDATA[How-To's]]></category>
		<category><![CDATA[Git]]></category>

		<guid isPermaLink="false">http://mattrude.com/?p=2272</guid>
		<description><![CDATA[Git&#8217;s Native eMail Notifier From the repository you wish to send email on commits. cd .git/hooks mv post-receive post-receive.bkp ln -s /usr/share/git-core/contrib/hooks/post-receive-email post-receive git config hooks.mailinglist "mailinglist@example.com" git config hooks.emailprefix "[SUBJECT PREFIX] " # note the trailing space Git Commit &#8230; <a href="http://technology.mattrude.com/2010/05/git-commit-email-notifications/">Continue reading <span class="meta-nav">&#8594;</span></a><a href="http://technology.mattrude.com/2010/05/git-commit-email-notifications/">Git Commit eMail Notifications</a> is a post from; <a href="http://technology.mattrude.com/">Matt&#039;s Technology Blog</a> which is not allowed to be copied on other sites.]]></description>
			<content:encoded><![CDATA[<h2>Git&#8217;s Native eMail Notifier</h2>
<p>From the repository you wish to send email on commits.</p>
<pre>cd .git/hooks
mv post-receive post-receive.bkp
ln -s /usr/share/git-core/contrib/hooks/post-receive-email post-receive
git config hooks.mailinglist "mailinglist@example.com"
git config hooks.emailprefix "[SUBJECT PREFIX] "  # note the trailing space</pre>
<h2>Git Commit Notifier</h2>
<p>This &#8216;plugin&#8217; will allow you to send an email every time a commit is committed to the repository. You may use this on the central repository to keep everyone following the project up to date.</p>
<ul>
<li>The source may also be downloaded at <a href="https://github.com/bitboxer/git-commit-notifier" target="_blank">http://github.com/bitboxer/git-commit-notifier</a></li>
</ul>
<p>To use this plugin, you first need to compile the script, then add the config information to each repository you wish to use it on.</p>
<h3>To Install Git Commit Notifier</h3>
<p>On <a href="http://fedoraproject.org" target="_blank">Fedora</a> 12 you first need to install Ruby and a few other dependences. After you download the needed dependences, you may compile the script.</p>
<pre>yum install ruby rubygems hpricot rubygem-hpricott
gem install git-commit-notifier</pre>
<h3>To Configure Git Commit Notifier</h3>
<p>In your repository&#8217;s <code>.git/hooks</code> folder or if it&#8217;s a &#8220;bare&#8221; repository, just the hooks folder. Create a file named <code>post-receive</code> with the following content.</p>
<pre>#!/bin/sh
git-commit-notifier ../git-commit-notifier.yml</pre>
<p>Once you have saved the file, you need to make it executable.</p>
<pre>chmod 775 post-receive</pre>
<p>After you have made the hook executable, check up one directory to the repository&#8217;s .git directory. From here you need to create and modify your git-commit-notifier&#8217;s config file. Start out by creating a file named <code>git-commit-notifier.yml</code>, and copy the below config to it.</p>
<h3>Git Commit Notifier Config File</h3>
<pre># The recipient for the commit:
mailinglist: developers@example.com

# set to true if you want to ignore empty merge messages
ignore_merge: false

# Optional parameter for the subject-line of the mail
# emailprefix: GIT

# Decorate files with link to a webview. Possible values: none or gitweb
link_files: none

# select the delivery method: smtp or sendmail
delivery_method: sendmail

# settings for the smtp server
smtp_server:
address: localhost
port: 25
domain: localhost
user_name: user@localhost
password: password
authentication: plain
enable_tls: false

# settings for sendmail
sendmail_options:
location: /usr/sbin/sendmail
arguments: -i -t

# If link_files is set to "gitweb", you need to configure the path to your gitweb
# instance and the project name.
gitweb:
path: http://developerserver/path_to_gitweb
project: test.git</pre>
<a href="http://technology.mattrude.com/2010/05/git-commit-email-notifications/">Git Commit eMail Notifications</a> is a post from; <a href="http://technology.mattrude.com/">Matt&#039;s Technology Blog</a> which is not allowed to be copied on other sites.]]></content:encoded>
			<wfw:commentRss>http://technology.mattrude.com/2010/05/git-commit-email-notifications/feed/</wfw:commentRss>
		<slash:comments>2</slash:comments>
		</item>
		<item>
		<title>Installing the git, cgit web interface on a Fedora</title>
		<link>http://technology.mattrude.com/2010/05/installing-cgit-web-interface-on-a-fedora-12-server-2/</link>
		<comments>http://technology.mattrude.com/2010/05/installing-cgit-web-interface-on-a-fedora-12-server-2/#comments</comments>
		<pubDate>Sun, 02 May 2010 18:44:42 +0000</pubDate>
		<dc:creator>Matt Rude</dc:creator>
				<category><![CDATA[How-To's]]></category>
		<category><![CDATA[Apache]]></category>
		<category><![CDATA[Configuration file]]></category>
		<category><![CDATA[Configuration Management]]></category>
		<category><![CDATA[Git]]></category>
		<category><![CDATA[Statistics]]></category>
		<category><![CDATA[Tools]]></category>
		<category><![CDATA[ZIP (file format)]]></category>

		<guid isPermaLink="false">http://mattrude.com/?p=2210</guid>
		<description><![CDATA[cgit is fast web interface for the git. cgit has built a cache and is compiled in c so it&#8217;s very quick. To start out, download the current version of cgit via git git clone git://hjemli.net/pub/git/cgit Next you need to &#8230; <a href="http://technology.mattrude.com/2010/05/installing-cgit-web-interface-on-a-fedora-12-server-2/">Continue reading <span class="meta-nav">&#8594;</span></a><a href="http://technology.mattrude.com/2010/05/installing-cgit-web-interface-on-a-fedora-12-server-2/">Installing the git, cgit web interface on a Fedora</a> is a post from; <a href="http://technology.mattrude.com/">Matt&#039;s Technology Blog</a> which is not allowed to be copied on other sites.]]></description>
			<content:encoded><![CDATA[<p>cgit is fast web interface for the git. cgit has built a cache and is compiled in c so it&#8217;s very quick.</p>
<p>To start out, download the current version of cgit via git</p>
<pre>git clone git://hjemli.net/pub/git/cgit</pre>
<p>Next you need to setup the git submodule</p>
<pre>cd cgit
git submodule init
git submodule update</pre>
<p>Once your done, run get-git</p>
<pre>make get-git</pre>
<p>Then compile the software</p>
<pre>make</pre>
<p>And install it</p>
<pre>make install</pre>
<p>After you have installed cgit, you will need to setup Apache to run cgit. This is pretty easy, just edit your <code>/etc/httpd/conf/httpd.conf</code> file and add the following for the site you wish to run cgit on.</p>
<pre>&lt;Directory "/var/www/code.mattrude.com/"&gt;
      AllowOverride None
      Options ExecCGI
      Order allow,deny
      Allow from all
&lt;/Directory&gt;</pre>
<p>Once your done setting up cgit in Apache, you may configure cgit by creating a cgitrc file at <code>/etc/cgitrc</code>. Below is the example config file.</p>
<pre>EXAMPLE CGITRC FILE
-------------------

# Enable caching of up to 1000 output entriess
cache-size=1000

# Specify some default clone prefixes
clone-prefix=git://foobar.com ssh://foobar.com/pub/git http://foobar.com/git

# Specify the css url
css=/css/cgit.css

# Show extra links for each repository on the index page
enable-index-links=1

# Show number of affected files per commit on the log pages
enable-log-filecount=1

# Show number of added/removed lines per commit on the log pages
enable-log-linecount=1

# Add a cgit favicon
favicon=/favicon.ico

# Use a custom logo
logo=/img/mylogo.png

# Enable statistics per week, month and quarter
max-stats=quarter

# Set the title and heading of the repository index page
root-title=foobar.com git repositories

# Set a subheading for the repository index page
root-desc=tracking the foobar development

# Include some more info about foobar.com on the index page
root-readme=/var/www/htdocs/about.html

# Allow download of tar.gz, tar.bz2 and zip-files
snapshots=tar.gz tar.bz2 zip

##
## List of common mimetypes
##

mimetype.git=image/git
mimetype.html=text/html
mimetype.jpg=image/jpeg
mimetype.jpeg=image/jpeg
mimetype.pdf=application/pdf
mimetype.png=image/png
mimetype.svg=image/svg+xml

##
## List of repositories.
## PS: Any repositories listed when section is unset will not be
##     displayed under a section heading
## PPS: This list could be kept in a different file (e.g. '/etc/cgitrepos')
##      and included like this:
##        include=/etc/cgitrepos
##

repo.url=foo
repo.path=/pub/git/foo.git
repo.desc=the master foo repository
repo.owner=fooman@foobar.com
repo.readme=info/web/about.html

repo.url=bar
repo.path=/pub/git/bar.git
repo.desc=the bars for your foo
repo.owner=barman@foobar.com
repo.readme=info/web/about.html

# The next repositories will be displayed under the 'extras' heading
section=extras

repo.url=baz
repo.path=/pub/git/baz.git
repo.desc=a set of extensions for bar users

repo.url=wiz
repo.path=/pub/git/wiz.git
repo.desc=the wizard of foo

# Add some mirrored repositories
section=mirrors

repo.url=git
repo.path=/pub/git/git.git
repo.desc=the dscm

repo.url=linux
repo.path=/pub/git/linux.git
repo.desc=the kernel

# Disable adhoc downloads of this repo
repo.snapshots=0

# Disable line-counts for this repo
repo.enable-log-linecount=0# Restrict the max statistics period for this repo
repo.max-stats=month</pre>
<a href="http://technology.mattrude.com/2010/05/installing-cgit-web-interface-on-a-fedora-12-server-2/">Installing the git, cgit web interface on a Fedora</a> is a post from; <a href="http://technology.mattrude.com/">Matt&#039;s Technology Blog</a> which is not allowed to be copied on other sites.]]></content:encoded>
			<wfw:commentRss>http://technology.mattrude.com/2010/05/installing-cgit-web-interface-on-a-fedora-12-server-2/feed/</wfw:commentRss>
		<slash:comments>0</slash:comments>
		</item>
		<item>
		<title>Installing the git, cgit web interface on a Fedora 12 server</title>
		<link>http://technology.mattrude.com/2010/05/installing-cgit-web-interface-on-a-fedora-12-server/</link>
		<comments>http://technology.mattrude.com/2010/05/installing-cgit-web-interface-on-a-fedora-12-server/#comments</comments>
		<pubDate>Sun, 02 May 2010 18:44:42 +0000</pubDate>
		<dc:creator>Matt Rude</dc:creator>
				<category><![CDATA[How-To's]]></category>
		<category><![CDATA[Git]]></category>
		<category><![CDATA[How-To]]></category>

		<guid isPermaLink="false">http://mattrude.com/?p=2210</guid>
		<description><![CDATA[cgit is fast web interface for the git. cgit has built a cache and is compiled in c so it&#8217;s very quick. To start out, download the current version of cgit via git git clone git://hjemli.net/pub/git/cgit Next you need to &#8230; <a href="http://technology.mattrude.com/2010/05/installing-cgit-web-interface-on-a-fedora-12-server/">Continue reading <span class="meta-nav">&#8594;</span></a><a href="http://technology.mattrude.com/2010/05/installing-cgit-web-interface-on-a-fedora-12-server/">Installing the git, cgit web interface on a Fedora 12 server</a> is a post from; <a href="http://technology.mattrude.com/">Matt&#039;s Technology Blog</a> which is not allowed to be copied on other sites.]]></description>
			<content:encoded><![CDATA[<p>cgit is fast web interface for the git. cgit has built a cache and is compiled in c so it&#8217;s very quick.</p>
<p>To start out, download the current version of cgit via git</p>
<pre>git clone git://hjemli.net/pub/git/cgit</pre>
<p>Next you need to setup the git submodule</p>
<pre>cd cgit
git submodule init
git submodule update</pre>
<p>Once your done, run get-git</p>
<pre>make get-git</pre>
<p>Then compile the software</p>
<pre>make</pre>
<p>And install it</p>
<pre>make install</pre>
<p>After you have installed cgit, you will need to setup Apache to run cgit.  This is pretty easy, just edit your <code>/etc/httpd/conf/httpd.conf</code> file and add the following for the site you wish to run cgit on.</p>
<pre>&lt;Directory "/var/www/code.mattrude.com/"&gt;
      AllowOverride None
      Options ExecCGI
      Order allow,deny
      Allow from all
&lt;/Directory&gt;</pre>
<p>Once your done setting up cgit in Apache, you may configure cgit by creating a cgitrc file at <code>/etc/cgitrc</code>.  Below is the example config file.</p>
<pre>EXAMPLE CGITRC FILE
-------------------

# Enable caching of up to 1000 output entriess
cache-size=1000

# Specify some default clone prefixes
clone-prefix=git://foobar.com ssh://foobar.com/pub/git http://foobar.com/git

# Specify the css url
css=/css/cgit.css

# Show extra links for each repository on the index page
enable-index-links=1

# Show number of affected files per commit on the log pages
enable-log-filecount=1

# Show number of added/removed lines per commit on the log pages
enable-log-linecount=1

# Add a cgit favicon
favicon=/favicon.ico

# Use a custom logo
logo=/img/mylogo.png

# Enable statistics per week, month and quarter
max-stats=quarter

# Set the title and heading of the repository index page
root-title=foobar.com git repositories

# Set a subheading for the repository index page
root-desc=tracking the foobar development

# Include some more info about foobar.com on the index page
root-readme=/var/www/htdocs/about.html

# Allow download of tar.gz, tar.bz2 and zip-files
snapshots=tar.gz tar.bz2 zip

##
## List of common mimetypes
##

mimetype.git=image/git
mimetype.html=text/html
mimetype.jpg=image/jpeg
mimetype.jpeg=image/jpeg
mimetype.pdf=application/pdf
mimetype.png=image/png
mimetype.svg=image/svg+xml

##
## List of repositories.
## PS: Any repositories listed when section is unset will not be
##     displayed under a section heading
## PPS: This list could be kept in a different file (e.g. '/etc/cgitrepos')
##      and included like this:
##        include=/etc/cgitrepos
##

repo.url=foo
repo.path=/pub/git/foo.git
repo.desc=the master foo repository
repo.owner=fooman@foobar.com
repo.readme=info/web/about.html

repo.url=bar
repo.path=/pub/git/bar.git
repo.desc=the bars for your foo
repo.owner=barman@foobar.com
repo.readme=info/web/about.html

# The next repositories will be displayed under the 'extras' heading
section=extras

repo.url=baz
repo.path=/pub/git/baz.git
repo.desc=a set of extensions for bar users

repo.url=wiz
repo.path=/pub/git/wiz.git
repo.desc=the wizard of foo

# Add some mirrored repositories
section=mirrors

repo.url=git
repo.path=/pub/git/git.git
repo.desc=the dscm

repo.url=linux
repo.path=/pub/git/linux.git
repo.desc=the kernel

# Disable adhoc downloads of this repo
repo.snapshots=0

# Disable line-counts for this repo
repo.enable-log-linecount=0

# Restrict the max statistics period for this repo
repo.max-stats=month</pre>
<a href="http://technology.mattrude.com/2010/05/installing-cgit-web-interface-on-a-fedora-12-server/">Installing the git, cgit web interface on a Fedora 12 server</a> is a post from; <a href="http://technology.mattrude.com/">Matt&#039;s Technology Blog</a> which is not allowed to be copied on other sites.]]></content:encoded>
			<wfw:commentRss>http://technology.mattrude.com/2010/05/installing-cgit-web-interface-on-a-fedora-12-server/feed/</wfw:commentRss>
		<slash:comments>0</slash:comments>
		</item>
		<item>
		<title>Installing the GIT Daemon for Read Only Access to Repoistory</title>
		<link>http://technology.mattrude.com/2010/03/installing-the-git-daemon-for-read-only-access-to-repoistory/</link>
		<comments>http://technology.mattrude.com/2010/03/installing-the-git-daemon-for-read-only-access-to-repoistory/#comments</comments>
		<pubDate>Mon, 29 Mar 2010 14:57:19 +0000</pubDate>
		<dc:creator>Matt Rude</dc:creator>
				<category><![CDATA[How-To's]]></category>
		<category><![CDATA[Configuration Management]]></category>
		<category><![CDATA[Fedora]]></category>
		<category><![CDATA[Git]]></category>
		<category><![CDATA[GitHub]]></category>
		<category><![CDATA[Repository clone]]></category>
		<category><![CDATA[Servers]]></category>
		<category><![CDATA[Source code]]></category>
		<category><![CDATA[Tools]]></category>

		<guid isPermaLink="false">http://mattrude.com/?p=2199</guid>
		<description><![CDATA[The idea here is to allow anyone to download your GIT repository using the native git protocol.  This is similar to the post I wrote about Creating a secure Git repository server, but the below method allows full read only &#8230; <a href="http://technology.mattrude.com/2010/03/installing-the-git-daemon-for-read-only-access-to-repoistory/">Continue reading <span class="meta-nav">&#8594;</span></a><a href="http://technology.mattrude.com/2010/03/installing-the-git-daemon-for-read-only-access-to-repoistory/">Installing the GIT Daemon for Read Only Access to Repoistory</a> is a post from; <a href="http://technology.mattrude.com/">Matt&#039;s Technology Blog</a> which is not allowed to be copied on other sites.]]></description>
			<content:encoded><![CDATA[<p>The idea here is to allow anyone to download your GIT repository using the native git protocol.   This is similar to the post I wrote about <a href="http://technology.mattrude.com/2009/07/creating-a-secure-git-repository-server/">Creating a secure Git repository server</a>, but the below method allows full read only public access to the repositories.</p>
<p>Start out by modifying the new file <code>git-daemon</code>.</p>
<pre>vim /etc/xinetd.d/git-daemon</pre>
<p>Add the below text to the file.</p>
<pre># description: The git daemon offers anonymous access to git repositories
service git
{
    disable        = no
    type           = UNLISTED
    port           = 9418
    socket_type    = stream
    wait           = no
    user           = git
    server         = /usr/libexec/git-core/git-daemon
    server_args    = --inetd --export-all --base-path=/var/git
    log_on_failure += USERID
}</pre>
<p>You may need to change the location of the git-daemon (the above example is from Fedora) and you will need to update the location of your git repository directory.</p>
<p>The above configuration will share <strong>ALL</strong> the git repositories in the <code>/var/git</code> directory.</p>
<p>If you do not wish for the all repositories to be public, you may remove the <code>--export-all</code> flag and add a empty file named <code>git-daemon-export-ok</code> to the git repository you wish to still share.</p>
<a href="http://technology.mattrude.com/2010/03/installing-the-git-daemon-for-read-only-access-to-repoistory/">Installing the GIT Daemon for Read Only Access to Repoistory</a> is a post from; <a href="http://technology.mattrude.com/">Matt&#039;s Technology Blog</a> which is not allowed to be copied on other sites.]]></content:encoded>
			<wfw:commentRss>http://technology.mattrude.com/2010/03/installing-the-git-daemon-for-read-only-access-to-repoistory/feed/</wfw:commentRss>
		<slash:comments>0</slash:comments>
		</item>
		<item>
		<title>Git Cheat Sheet</title>
		<link>http://technology.mattrude.com/2010/03/git-cheat-sheet/</link>
		<comments>http://technology.mattrude.com/2010/03/git-cheat-sheet/#comments</comments>
		<pubDate>Sat, 20 Mar 2010 18:08:20 +0000</pubDate>
		<dc:creator>Matt Rude</dc:creator>
				<category><![CDATA[General]]></category>
		<category><![CDATA[Apache Subversion]]></category>
		<category><![CDATA[Branching (software)]]></category>
		<category><![CDATA[Configuration Management]]></category>
		<category><![CDATA[Git]]></category>
		<category><![CDATA[GitHub]]></category>
		<category><![CDATA[README]]></category>
		<category><![CDATA[Server (computing)]]></category>

		<guid isPermaLink="false">http://mattrude.com/?p=2145</guid>
		<description><![CDATA[Git Global Setup git config --global user.name "Your Name Here" git config --global user.email you@example.com Git Commands Common Git Commands To download a new git repository (Public access) git clone http://git.example.com/folder/project.git Update an exciting repository (From within the projects folder) &#8230; <a href="http://technology.mattrude.com/2010/03/git-cheat-sheet/">Continue reading <span class="meta-nav">&#8594;</span></a><a href="http://technology.mattrude.com/2010/03/git-cheat-sheet/">Git Cheat Sheet</a> is a post from; <a href="http://technology.mattrude.com/">Matt&#039;s Technology Blog</a> which is not allowed to be copied on other sites.]]></description>
			<content:encoded><![CDATA[<h2>Git Global Setup</h2>
<pre> git config --global user.name "Your Name Here"
 git config --global user.email you@example.com</pre>
<h1>Git Commands</h1>
<h2>Common Git  Commands</h2>
<h2>To  download a new git repository</h2>
<p>(Public access)</p>
<pre>git clone http://git.example.com/folder/project.git</pre>
<h2>Update an exciting repository</h2>
<p><em>(From within the projects folder)</em></p>
<pre>git pull</pre>
<h2>Comment a change</h2>
<pre>git comment file.txt</pre>
<h2>To Revert a  comment</h2>
<pre>git revert ce963c9db00c25b3c1e6add1fe6032aef61a5bed</pre>
<h2>Commit</h2>
<h2>Modify the  last commit</h2>
<pre>git commit --amend</pre>
<h2>Patches</h2>
<h2>Creating a patch</h2>
<pre>git diff file_with_changes &gt; 0001-name_of_patch_file.patch
gzip 0001-name_of_patch_file.patch</pre>
<h2>Patching a file or directory</h2>
<pre>gzip -dc 0001-name_of_patch_file.patch.gz |patch -p1</pre>
<h2>Branching</h2>
<h2>Creating a  new branch</h2>
<pre>git branch <em>&lt;branch&gt;</em></pre>
<p>or to create a branch and switch to it</p>
<pre>git checkout -b <em>&lt;branch&gt;</em></pre>
<h2>Pulling changes from branches</h2>
<pre>git checkout <em>&lt;branch_committing_to&gt;</em></pre>
<p>Now that your in the branch you want to add the changes to, run:</p>
<pre>git pull . <em>&lt;branch_committing_from&gt;</em></pre>
<h2>Changing to a different branch</h2>
<pre>git checkout <em>&lt;branch&gt;</em></pre>
<h2>Deleting a branch</h2>
<pre>git branch -d <em>&lt;branch&gt;</em></pre>
<h2>Deleting a  remote branch</h2>
<pre>git push origin :<em>&lt;branch&gt;</em></pre>
<h2>Pushing a  branch to github</h2>
<pre>git push <em>&lt;remote_repository_name&gt; &lt;branch_name&gt;</em></pre>
<p>So that would be&#8230;</p>
<pre>git push origin <em>&lt;branch&gt;</em></pre>
<h2>Display  branches on github</h2>
<pre>git remote show origin</pre>
<h2>Pulling a branch from github</h2>
<pre>git checkout --track -b <em>&lt;name_of_local_branch&gt;</em> origin/<em>&lt;name_of_remote_branch&gt;</em></pre>
<h2>Tagging</h2>
<h2>Tagging a branch</h2>
<pre>git tag -a -m "tagging version 1.0" 1.0</pre>
<h2>Pushing  the tag to github</h2>
<pre>git push --tags</pre>
<h2>Deleting a tag</h2>
<pre>git tag -d 1.0</pre>
<h2>Removing a deleted tag from github</h2>
<pre>git push origin :refs/tags/1.0</pre>
<h2>Submodules</h2>
<h2>To  update existing submodules</h2>
<pre>git pull
git submodule init
git submodule update</pre>
<h2>To add a new submodule to a project</h2>
<pre>git submodule add &lt;remote-host&gt;:&lt;project.git&gt; &lt;project.git&gt;</pre>
<p>So if you are adding project &#8220;program&#8221; from the example git server  you will run</p>
<pre>git submodule add git://example.com/program.git program</pre>
<h2>Creating an secure Git remote server</h2>
<p>On the <strong>Server</strong> create the git repository</p>
<pre>mkdir name-of-git-repo.git
cd name-of-git-repo.git
git init --bare</pre>
<p>On the <strong>Client System</strong> create the git repo to import into the server</p>
<pre>git init
touch README
git add README
git commit -m 'first commit'
git remote add origin git@REMOTE_SERVER:name-of-git-repo.git
git push origin master</pre>
<h2>Importing an <a title="SVN" href="http://wiki.mattrude.com/SVN">SVN</a> repo into git</h2>
<p>To import a svn repo create a new git repo and run</p>
<pre>git svn clone https://svn.foo.com/svn/proj
git commit</pre>
<ul>
<li> <a rel="nofollow" href="http://blog.tsunanet.net/2007/07/learning-git-svn-in-5min.html">http://tsunanet.blogspot.com/2007/07/learning-git-svn-in-5min.html</a></li>
<li> http://djwonk.com/blog/2008/05/09/cleanly-import-svn-repository-into-git/</li>
</ul>
<h2>Git Links</h2>
<ul>
<li> <a rel="nofollow" href="http://help.github.com/">http://github.com/guides/home</a></li>
<li> <a rel="nofollow" href="http://git-scm.com/about">http://whygitisbetterthanx.com</a></li>
<li> <a rel="nofollow" href="https://github.com/">http://github.com</a></li>
</ul>
<a href="http://technology.mattrude.com/2010/03/git-cheat-sheet/">Git Cheat Sheet</a> is a post from; <a href="http://technology.mattrude.com/">Matt&#039;s Technology Blog</a> which is not allowed to be copied on other sites.]]></content:encoded>
			<wfw:commentRss>http://technology.mattrude.com/2010/03/git-cheat-sheet/feed/</wfw:commentRss>
		<slash:comments>0</slash:comments>
		</item>
		<item>
		<title>Run a Secure git Repository on FreeNAS</title>
		<link>http://technology.mattrude.com/2010/01/run-a-secure-git-repository-on-freenas/</link>
		<comments>http://technology.mattrude.com/2010/01/run-a-secure-git-repository-on-freenas/#comments</comments>
		<pubDate>Thu, 28 Jan 2010 00:31:38 +0000</pubDate>
		<dc:creator>Matt Rude</dc:creator>
				<category><![CDATA[How-To's]]></category>
		<category><![CDATA[Configuration Management]]></category>
		<category><![CDATA[Filesystem permissions]]></category>
		<category><![CDATA[Git]]></category>
		<category><![CDATA[GitHub]]></category>
		<category><![CDATA[Repository clone]]></category>
		<category><![CDATA[Secure Shell]]></category>
		<category><![CDATA[Tools]]></category>
		<category><![CDATA[User (computing)]]></category>

		<guid isPermaLink="false">http://mattrude.com/?p=1975</guid>
		<description><![CDATA[Running a secure git repository on FreeNAS is pretty straight forward, once you understand what your trying to do.  If you have looked over my previous post &#8220;Creating a secure Git repository server&#8221; you understand that all you really need &#8230; <a href="http://technology.mattrude.com/2010/01/run-a-secure-git-repository-on-freenas/">Continue reading <span class="meta-nav">&#8594;</span></a><a href="http://technology.mattrude.com/2010/01/run-a-secure-git-repository-on-freenas/">Run a Secure git Repository on FreeNAS</a> is a post from; <a href="http://technology.mattrude.com/">Matt&#039;s Technology Blog</a> which is not allowed to be copied on other sites.]]></description>
			<content:encoded><![CDATA[<p>Running a secure git repository on <a href="http://www.freenas.org/" target="_blank">FreeNAS</a> is pretty straight forward, once you understand what your trying to do.  If you have looked over my previous post &#8220;<a href="http://technology.mattrude.com/2009/07/creating-a-secure-git-repository-server/">Creating a secure Git repository  server</a>&#8221; you understand that all you really need to do is connect to the git repository via ssh/ssl and copy back what you need.  The hardest part of using FreeNAS is creating the keys.</p>
<p>To start out, you need to create a user account on the FreeNAS system.  This will be a generic account that everyone who has write access will use.  You may also create a account for each person, and grant each of them access to the central repository.</p>
<p>After you have your account, follow my post on &#8220;<a href="http://technology.mattrude.com/2010/01/enable-ssh-no-password-authorization-with-freenas/">Enable SSH Key Authorization on  FreeNAS</a>&#8221; to copy over the SSL key and setup the account.  Once you are able to log in as your FreeNAS git user, you may follow my previous post &#8220;<a href="http://technology.mattrude.com/2009/07/creating-a-secure-git-repository-server/">Creating  a secure Git repository  server</a>&#8221; to setup the git repository.</p>
<a href="http://technology.mattrude.com/2010/01/run-a-secure-git-repository-on-freenas/">Run a Secure git Repository on FreeNAS</a> is a post from; <a href="http://technology.mattrude.com/">Matt&#039;s Technology Blog</a> which is not allowed to be copied on other sites.]]></content:encoded>
			<wfw:commentRss>http://technology.mattrude.com/2010/01/run-a-secure-git-repository-on-freenas/feed/</wfw:commentRss>
		<slash:comments>11</slash:comments>
		</item>
		<item>
		<title>Converting a MediaWiki database from MySQL to SQLite</title>
		<link>http://technology.mattrude.com/2010/01/converting-a-mediawiki-database-from-mysql-to-sqlite/</link>
		<comments>http://technology.mattrude.com/2010/01/converting-a-mediawiki-database-from-mysql-to-sqlite/#comments</comments>
		<pubDate>Sun, 17 Jan 2010 19:15:23 +0000</pubDate>
		<dc:creator>Matt Rude</dc:creator>
				<category><![CDATA[How-To's]]></category>
		<category><![CDATA[Backup]]></category>
		<category><![CDATA[Database]]></category>
		<category><![CDATA[MediaWiki]]></category>
		<category><![CDATA[MySQL]]></category>
		<category><![CDATA[php]]></category>
		<category><![CDATA[SQLite]]></category>
		<category><![CDATA[Wiki]]></category>

		<guid isPermaLink="false">http://mattrude.com/?p=1889</guid>
		<description><![CDATA[So the plane here is to convert a fully working MediaWiki install running on MySQL to run on SQLite instead.  To do this you will need to install a 2nd MediaWIKI install on a test or development system.  Once you &#8230; <a href="http://technology.mattrude.com/2010/01/converting-a-mediawiki-database-from-mysql-to-sqlite/">Continue reading <span class="meta-nav">&#8594;</span></a><a href="http://technology.mattrude.com/2010/01/converting-a-mediawiki-database-from-mysql-to-sqlite/">Converting a MediaWiki database from MySQL to SQLite</a> is a post from; <a href="http://technology.mattrude.com/">Matt&#039;s Technology Blog</a> which is not allowed to be copied on other sites.]]></description>
			<content:encoded><![CDATA[<p>So the plane here is to convert a fully working <a href="http://www.mediawiki.org/wiki/MediaWiki" target="_blank">MediaWiki</a> install running on <a href="http://dev.mysql.com/" target="_blank">MySQL</a> to run on <a href="http://www.sqlite.org/" target="_blank">SQLite</a> instead.  To do this you will need to install a 2nd MediaWIKI install on a test or development system.  Once you are done you can move your new MediaWiki install to where every you would like.</p>
<h3>Backup up your Old MediaWiki Installation</h3>
<p>To start, from within your working MediaWiki install, first back up your data.</p>
<pre>php maintenance/dumpBackup.php --full --uploads &gt; wiki-backup.xml</pre>
<p>This will create a file named wiki-backup.xml in your MediaWiki&#8217;s root directory, copy that file to a safe place.  We aren&#8217;t going to touch the MySQL database until were done, but it&#8217;s always a good idea to have backups safe and sound in case you need them.</p>
<p>The backup script run above dose not backup your MediaWiki&#8217;s uploaded images and other files.  These files are stored in your &#8216;images&#8217; folder in the root of MediaWiki&#8217;s directory.  You need to back those up also.</p>
<pre>tar -czf wiki-images.tgz images/</pre>
<p>You should now have everything you need from your old MediaWiki install. Next you will need to install MediaWiki in a new location on your sever (or a development server).</p>
<h3>Installing your new SQLite MediaWiki site</h3>
<p>You should download and install the newest version of MediaWiki.  I always you the development trunk since this is what&#8217;s used on <a href="http://en.wikipedia.org/wiki/Special:Version" target="_blank">Wikipedia</a>.</p>
<p>During the install process you will be asked what database you would like to use, you much choose &#8216;SQLite&#8217; since this is the point of reinstalling MediaWiki.  Bring your new install all the way so you have a new install running on your server.  MediaWiki will create a default home page for you and you should be able to modify that page.  If you are unable to get MediaWiki installed or if you have a problem modifying the Main Page after the install, please see the MediaWiki <a href="http://www.mediawiki.org/wiki/Mailing_lists" target="_blank">mailing lists</a> or the <a href="http://www.mediawiki.org/wiki/Manual:FAQ" target="_blank">FAQ</a> for assistance.</p>
<h3>Restoring your Data on your new SQLite site</h3>
<p>After you have your new SQLite version of MediaWiki installed and working, you need to restore your data.  The database part of this is pretty strate forward.</p>
<p>Start by copying the xml file you created in the first step to your new MediaWiki install.  Then run the following:</p>
<pre>php maintenance/importDump.php wiki-backup.xml</pre>
<p>Depending on the amount of pages you have, this may take quite some time to process. Once this is done all your pages should be on your new install (expect the Main Page, you will need to copy that manually).<br />
To restore you images and other uploaded files, first you need to extract the tarball you made earlier to temporary location.</p>
<pre>mkdir temporary
cp wiki-images.tgz temporary
cd temporary/
tar -xzf wiki-images.tgz</pre>
<p>This will create a bunch of folders in the temporary directory, you need to copy everything in those folders into a single folder. The name of the folder doesn&#8217;t matter, I&#8217;m using tempimages, but you may use what you would like.</p>
<pre>cd ../
mkdir tempimages
cp temporary/images/*/*/* tempimages</pre>
<p>Now that you have everything in a single folder, import the content of that folder into your new MediaWiki install.</p>
<pre>php maintenance/importImages.php tempimages/</pre>
<p>And that should do it, you should now have a fully working MediaWiki install using SQLite.</p>
<a href="http://technology.mattrude.com/2010/01/converting-a-mediawiki-database-from-mysql-to-sqlite/">Converting a MediaWiki database from MySQL to SQLite</a> is a post from; <a href="http://technology.mattrude.com/">Matt&#039;s Technology Blog</a> which is not allowed to be copied on other sites.]]></content:encoded>
			<wfw:commentRss>http://technology.mattrude.com/2010/01/converting-a-mediawiki-database-from-mysql-to-sqlite/feed/</wfw:commentRss>
		<slash:comments>2</slash:comments>
		</item>
		<item>
		<title>Enable SSH Key Authorization on FreeNAS</title>
		<link>http://technology.mattrude.com/2010/01/enable-ssh-no-password-authorization-with-freenas/</link>
		<comments>http://technology.mattrude.com/2010/01/enable-ssh-no-password-authorization-with-freenas/#comments</comments>
		<pubDate>Sat, 02 Jan 2010 23:06:36 +0000</pubDate>
		<dc:creator>Matt Rude</dc:creator>
				<category><![CDATA[How-To's]]></category>
		<category><![CDATA[Digital Signature Algorithm]]></category>
		<category><![CDATA[Fedora]]></category>
		<category><![CDATA[FreeNAS]]></category>
		<category><![CDATA[Public-key cryptography]]></category>
		<category><![CDATA[Secure Shell]]></category>
		<category><![CDATA[SSH]]></category>
		<category><![CDATA[Transmission Control Protocol]]></category>
		<category><![CDATA[User (computing)]]></category>

		<guid isPermaLink="false">http://mattrude.com/?p=1882</guid>
		<description><![CDATA[FreeNAS is a powerful tools for archive data and other long-term storage requirements. Recently I have started backing up this and other off-site servers to one of my local FreeNAS boxes. Since these systems are only connected via the insecure &#8230; <a href="http://technology.mattrude.com/2010/01/enable-ssh-no-password-authorization-with-freenas/">Continue reading <span class="meta-nav">&#8594;</span></a><a href="http://technology.mattrude.com/2010/01/enable-ssh-no-password-authorization-with-freenas/">Enable SSH Key Authorization on FreeNAS</a> is a post from; <a href="http://technology.mattrude.com/">Matt&#039;s Technology Blog</a> which is not allowed to be copied on other sites.]]></description>
			<content:encoded><![CDATA[<p>FreeNAS is a powerful tools for archive data and other long-term storage requirements. Recently I have started backing up this and other off-site servers to one of my local FreeNAS boxes. Since these systems are only connected via the insecure internet (no VPN), I decided to transmit the backup files via SSH using SCP.  In order to do this without having to enter my password in for each and every backup (most of which happen while I&#8217;m hopeful sleeping), I needed to implement SSH Key Authorization on the receiving FreeNAS box.</p>
<p>To do this first I needed to create a DSA key pair on a different system.  On my Fedora 12 laptop I ran</p>
<pre>ssh-keygen -t dsa</pre>
<p>The trick here is to not create your new key pair in the default directory of &#8220;~/.ssh/&#8221; but in a temporary directory instead. So when it asks you.</p>
<pre>Generating public/private dsa key pair.
Enter file in which to save the key (/root/.ssh/id_dsa):</pre>
<p>Enter a different file in witch to save the key in.  Note this is asking for the name of a file, not the name of the directory, it will also create a .pub file, this is the public key for the above private key.</p>
<p>Now that you have a public/private key for the FreeNAS box, if you don&#8217;t already you need to create one for the user that you plan on sending the file from.  Just follow the above command, but this time, you may just hit enter all the way threw leaving all options as default.</p>
<p>Next, go to your FreeNAS web-page control panel, If you don&#8217;t already have one, you will need to create a user on your FreeNAS box for you to connect to.  You may do this via &#8220;Access -&gt; User and Groups&#8221; from the black bar on the top of the page.</p>
<p>Now from the top (black) bar go to &#8220;Services -&gt; SSH&#8221;</p>
<p>On your Services|SSH page, first make sure the service is enabled (top right hand corner). Once it is you will be able to change the below options.</p>
<ul>
<li><strong>TCP Port:</strong> The default (port 22) is fine in most cases, but note if you change it, you must use the new port for all connections.</li>
<li><strong>Permit root login:</strong> My option is that the root account should never be allowed to log in via a remote process.  You should set your system up correctly where this is not needed.</li>
<li><strong>Password authentication:</strong> For now this must be enabled (checked), once you have set &#8220;Key Authorization&#8221; up, you may disable this option.</li>
<li><strong>TCP forwarding:</strong> Disabled (unchecked)</li>
<li><strong>Compression:</strong> Enabled (checked)</li>
<li><strong>Private Key:</strong> This will be were we put the private key created above.  All you need to do is copy and paste.</li>
<li><strong>Extra options:</strong> Blank</li>
</ul>
<p>After you have made your changes, &#8220;Save and Restart&#8221; the service.</p>
<p>On your local system, you need to copy the content of the local users public (~/.ssh/username.pub) key file to a new file named &#8220;authorized_keys&#8221; <em>(Note: this is not the file we created for FreeNAS but the file we created for your local account)</em>.  This is the file that will need to be copied to your FreeNAS box.</p>
<p>Now that you have all the needed bits, we need to log into your FreeNAS server and create a &#8220;.ssh&#8221; directory to store the &#8220;authorized_keys&#8221; file.  To log in to the FreeNAS box interactively run a command similar too.</p>
<pre>ssh freenasuser@freenasaddress</pre>
<p>Or if you changed the &#8220;TCP Port&#8221; above, your command will look like this:</p>
<pre>ssh -P freenasport freenasuser@freenasaddress</pre>
<p>Once your logged in, you need to create the directory, by doing.</p>
<pre>mkdir ~/.ssh</pre>
<p>After you have successfully created your directory, you may exit out of your FreeNAS box for the next step.<br />
Back on your local system you need to copy the &#8220;authorized_keys&#8221; file created before to the FreeNAS box.  Using SCP you can do this by running a command like:</p>
<pre>scp -P freenasport authorized_keys freenasuser@freenasaddress:~/.ssh/</pre>
<p>This will copy the file to the FreeNAS box. Next, reconnect to the FreeNAS box as you did before and run.</p>
<pre>cd ~/.ssh/
chmod 600 authorized_keys</pre>
<p>Once your done, you should be able to connect to your FreeNAS box using the private key in the authorized_keys with out a password.</p>
<a href="http://technology.mattrude.com/2010/01/enable-ssh-no-password-authorization-with-freenas/">Enable SSH Key Authorization on FreeNAS</a> is a post from; <a href="http://technology.mattrude.com/">Matt&#039;s Technology Blog</a> which is not allowed to be copied on other sites.]]></content:encoded>
			<wfw:commentRss>http://technology.mattrude.com/2010/01/enable-ssh-no-password-authorization-with-freenas/feed/</wfw:commentRss>
		<slash:comments>13</slash:comments>
		</item>
		<item>
		<title>Installing Dovecot with SQLite Support</title>
		<link>http://technology.mattrude.com/2009/12/installing-dovecot-using-sqlite/</link>
		<comments>http://technology.mattrude.com/2009/12/installing-dovecot-using-sqlite/#comments</comments>
		<pubDate>Tue, 08 Dec 2009 18:31:31 +0000</pubDate>
		<dc:creator>Matt Rude</dc:creator>
				<category><![CDATA[How-To's]]></category>
		<category><![CDATA[Database]]></category>
		<category><![CDATA[MySQL]]></category>
		<category><![CDATA[Null (SQL)]]></category>
		<category><![CDATA[Postfix (software)]]></category>
		<category><![CDATA[SQL]]></category>
		<category><![CDATA[SQLite]]></category>
		<category><![CDATA[Tools]]></category>

		<guid isPermaLink="false">http://mattrude.com/?p=1648</guid>
		<description><![CDATA[Following in line with my previous post on Installing Postfix with SQL Support. This post will describe installing Dovecot from source with full SQLite support. Installing from Source First start out by downloading the lastest version from Dovecot&#8217;s website (the &#8230; <a href="http://technology.mattrude.com/2009/12/installing-dovecot-using-sqlite/">Continue reading <span class="meta-nav">&#8594;</span></a><a href="http://technology.mattrude.com/2009/12/installing-dovecot-using-sqlite/">Installing Dovecot with SQLite Support</a> is a post from; <a href="http://technology.mattrude.com/">Matt&#039;s Technology Blog</a> which is not allowed to be copied on other sites.]]></description>
			<content:encoded><![CDATA[<p>Following in line with my previous post on <a href="http://technology.mattrude.com/2009/09/installing-postfix-with-sqlite-support/" target="_blank">Installing Postfix with SQL Support</a>. This post will describe installing <a href="http://www.dovecot.org" target="_blank">Dovecot</a> from source with full <a href="http://www.sqlite.org" target="_blank">SQLite</a> support.</p>
<h3>Installing from Source</h3>
<p>First start out by downloading the lastest version from Dovecot&#8217;s website (the current version as of the writing of the how-to is 1.2.8).</p>
<pre>yum -y install sqlite sqlite-devel gcc make patch db4-devel cyrus-sasl-devel</pre>
<p>Next download and untar the source code.</p>
<pre>wget http://dovecot.org/releases/1.2/dovecot-1.2.8.tar.gz
tar -xzf dovecot-1.2.8.tar.gz
cd dovecot-1.2.8/</pre>
<p>Next, you will need to configure the code before compiling.</p>
<pre>./configure --with-sqlite
echo $?</pre>
<p>Assuming the configure command finishes with out error (the last line should be a &#8220;0&#8243;). Compile and install Dovecot.</p>
<pre>make &amp;&amp; make install</pre>
<h3>Configuring Dovecot for SQLite</h3>
<p>First we need to create or modify the dovecot config file for SQLite access.  If you are currenly using MySQL with Dovecot, switching to SQLite is pretty easy and strate forward.  Or you may just use the below dovecot config file.</p>
<pre>### Dovecot configuration file ###
### /etc/dovecot.conf ###
protocols = pop3 imap
login_user = postfix
auth_cache_size = 128
auth_cache_ttl = 600
mail_debug = yes

mail_location = maildir:%h/

protocol imap {
 listen = *:143
}

protocol lda {
  postmaster_address = postmaster@mattrude.com
  hostname = odin.mattrude.com
  mail_plugin_dir = /usr/local/lib/dovecot/lda
  auth_socket_path = /var/run/dovecot/auth-master
}

auth default {
  mechanisms = plain login
  userdb sql {
    args = /etc/dovecot-sqlite.conf
  }
  passdb sql {
    args = /etc/dovecot-sqlite.conf
  }
  socket listen {
    master {
      path = /var/run/dovecot/auth-master
      user = virtualmail
      group = virtualmail
    }
    client {
      path = /var/spool/postfix/private/auth
      mode = 0660
      user = postfix
      group = postfix
    }
  }
}</pre>
<p>After you have created the main Dovecot config file, you will need to add the SQLite config file (below).</p>
<pre>### /etc/dovecot-sqlite.conf ###
driver = sqlite
connect = /etc/postfix/postfix.sqlite
password_query = SELECT password, username AS user 
  FROM mailbox WHERE username = '%u' AND domain = '%d'
user_query = SELECT maildir, 1000 AS uid, 1000 AS gid FROM mailbox WHERE 
  username = '%u' AND domain = '%d' AND active = '1'</pre>
<p>After the config files have been created, we need to create the database file, here is where you will need SQLite installed on the system.</p>
<h3>Building the SQLite Database</h3>
<p>In order to use the SQLite function, you need a SQLite database.  First using SQLite3 run</p>
<pre>sqlite3 /etc/postfix/postfix.sqlite</pre>
<p>To create the database, then you can copy and past the following scheme into the new database.</p>
<pre>CREATE TABLE alias (
  address varchar(255) NOT NULL,
  goto text NOT NULL,
  domain varchar(255) NOT NULL,
  created datetime NOT NULL default '0000-00-00 00:00:00',
  modified datetime NOT NULL default '0000-00-00 00:00:00',
  active tinyint(1) NOT NULL default '1');

CREATE TABLE domain (
  domain varchar(255) NOT NULL,
  description varchar(255) NOT NULL,
  aliases int(10) NOT NULL default '0',
  mailboxes int(10) NOT NULL default '0',
  maxquota bigint(20) NOT NULL default '0',
  quota bigint(20) NOT NULL default '0',
  transport varchar(255) NOT NULL,
  backupmx tinyint(1) NOT NULL default '0',
  created datetime NOT NULL default '0000-00-00 00:00:00',
  modified datetime NOT NULL default '0000-00-00 00:00:00',
  active tinyint(1) NOT NULL default '1' );

CREATE TABLE mailbox (
  username varchar(255) NOT NULL,
  password varchar(255) NOT NULL,
  name varchar(255) NOT NULL,
  maildir varchar(255) NOT NULL,
  quota bigint(20) NOT NULL default '0',
  domain varchar(255) NOT NULL,
  created datetime NOT NULL default '0000-00-00 00:00:00',
  modified datetime NOT NULL default '0000-00-00 00:00:00',
  active tinyint(1) NOT NULL default '1',
  local_part varchar(255) NOT NULL );</pre>
<p>Then close the database</p>
<pre>.quit</pre>
<p>Or you may download mine from below and use the same scheme work.</p>
<ul>
<li> <a title="Postfix.sqlite" href="http://wiki.mattrude.com/images/1/15/Postfix.sqlite">postfix.sqlite</a></li>
</ul>
<pre>mkdir /var/run/dovecot</pre>
<h3>Dovecot INIT file</h3>
<pre>#!/bin/bash
#
#	/etc/rc.d/init.d/dovecot
#
# Starts the dovecot daemon
#
# chkconfig: - 65 35
# description: Dovecot Imap Server
# processname: dovecot
# Source function library.
. /etc/init.d/functions

test -x /usr/local/sbin/dovecot || exit 0

RETVAL=0
prog="Dovecot Imap"

start() {
       echo -n $"Starting $prog: "
	daemon /usr/local/sbin/dovecot
	RETVAL=$?
	[ $RETVAL -eq 0 ] &amp;&amp; touch /var/lock/subsys/dovecot
	echo
}

stop() {
	echo -n $"Stopping $prog: "
	killproc /usr/local/sbin/dovecot
	RETVAL=$?
	[ $RETVAL -eq 0 ] &amp;&amp; rm -f /var/lock/subsys/dovecot
	echo
}

case "$1" in
  start)
	start
	;;
  stop)
	stop
	;;
  reload|restart)
	stop
	start
	RETVAL=$?
	;;
  condrestart)
	if [ -f /var/lock/subsys/dovecot ]; then
	    stop
	    start
	fi
	;;
  status)
	status /usr/local/sbin/dovecot
	RETVAL=$?
	;;
  *)
	echo $"Usage: $0 {condrestart|start|stop|restart|reload|status}"
	exit 1
esac

exit $RETVAL</pre>
<a href="http://technology.mattrude.com/2009/12/installing-dovecot-using-sqlite/">Installing Dovecot with SQLite Support</a> is a post from; <a href="http://technology.mattrude.com/">Matt&#039;s Technology Blog</a> which is not allowed to be copied on other sites.]]></content:encoded>
			<wfw:commentRss>http://technology.mattrude.com/2009/12/installing-dovecot-using-sqlite/feed/</wfw:commentRss>
		<slash:comments>4</slash:comments>
		</item>
		<item>
		<title>How-To Disable tool-tips in Fedora 12 (while using GNOME)</title>
		<link>http://technology.mattrude.com/2009/11/how-to-disable-tool-tips-in-fedora-12-while-using-gnome/</link>
		<comments>http://technology.mattrude.com/2009/11/how-to-disable-tool-tips-in-fedora-12-while-using-gnome/#comments</comments>
		<pubDate>Sat, 28 Nov 2009 04:47:01 +0000</pubDate>
		<dc:creator>Matt Rude</dc:creator>
				<category><![CDATA[How-To's]]></category>
		<category><![CDATA[Fedora]]></category>
		<category><![CDATA[GNOME]]></category>
		<category><![CDATA[GNOME Shell]]></category>
		<category><![CDATA[Graphic Subsystems]]></category>
		<category><![CDATA[Operating system]]></category>
		<category><![CDATA[Ubuntu]]></category>

		<guid isPermaLink="false">http://mattrude.com/?p=1606</guid>
		<description><![CDATA[As the user you login as (ie: not root) edit or create the file named gtkrc-2.0. vim ~/.gtkrc-2.0 and add the line gtk-enable-tooltips = 0 if the file dosen&#8217;t exict yet, don&#8217;t worry about it. Last, reboot your system and &#8230; <a href="http://technology.mattrude.com/2009/11/how-to-disable-tool-tips-in-fedora-12-while-using-gnome/">Continue reading <span class="meta-nav">&#8594;</span></a><a href="http://technology.mattrude.com/2009/11/how-to-disable-tool-tips-in-fedora-12-while-using-gnome/">How-To Disable tool-tips in Fedora 12 (while using GNOME)</a> is a post from; <a href="http://technology.mattrude.com/">Matt&#039;s Technology Blog</a> which is not allowed to be copied on other sites.]]></description>
			<content:encoded><![CDATA[<p>As the user you login as (ie: not root) edit or create the file named <em>gtkrc-2.0</em>.</p>
<pre>vim ~/.gtkrc-2.0</pre>
<p>and add the line</p>
<pre>gtk-enable-tooltips = 0</pre>
<p>if the file dosen&#8217;t exict yet, don&#8217;t worry about it.</p>
<p>Last, reboot your system and the tool tips should be gone.</p>
<a href="http://technology.mattrude.com/2009/11/how-to-disable-tool-tips-in-fedora-12-while-using-gnome/">How-To Disable tool-tips in Fedora 12 (while using GNOME)</a> is a post from; <a href="http://technology.mattrude.com/">Matt&#039;s Technology Blog</a> which is not allowed to be copied on other sites.]]></content:encoded>
			<wfw:commentRss>http://technology.mattrude.com/2009/11/how-to-disable-tool-tips-in-fedora-12-while-using-gnome/feed/</wfw:commentRss>
		<slash:comments>0</slash:comments>
		</item>
		<item>
		<title>Auto Update Script for MiniMyth</title>
		<link>http://technology.mattrude.com/2009/11/auto-update-script-for-minimyth/</link>
		<comments>http://technology.mattrude.com/2009/11/auto-update-script-for-minimyth/#comments</comments>
		<pubDate>Sat, 21 Nov 2009 06:13:09 +0000</pubDate>
		<dc:creator>Matt Rude</dc:creator>
				<category><![CDATA[How-To's]]></category>
		<category><![CDATA[Apache]]></category>
		<category><![CDATA[minimyth]]></category>
		<category><![CDATA[Mythtv]]></category>
		<category><![CDATA[Servers]]></category>
		<category><![CDATA[SQL]]></category>
		<category><![CDATA[URL]]></category>
		<category><![CDATA[Wget]]></category>
		<category><![CDATA[WWW]]></category>

		<guid isPermaLink="false">http://mattrude.com/?p=1516</guid>
		<description><![CDATA[This script will download the newest version of MiniMyth and update your tftp directory. It first downloads the version file and compares that version number to the current install version of MiniMyth install.  If it determines that the version dose &#8230; <a href="http://technology.mattrude.com/2009/11/auto-update-script-for-minimyth/">Continue reading <span class="meta-nav">&#8594;</span></a><a href="http://technology.mattrude.com/2009/11/auto-update-script-for-minimyth/">Auto Update Script for MiniMyth</a> is a post from; <a href="http://technology.mattrude.com/">Matt&#039;s Technology Blog</a> which is not allowed to be copied on other sites.]]></description>
			<content:encoded><![CDATA[<p>This script will download the newest version of <a href="http://www.minimyth.org/" target="_blank">MiniMyth</a> and update your tftp directory.</p>
<p>It first downloads the version file and compares that version number to the current install version of MiniMyth install.  If it determines that the version dose not match it will then download the current release, untar it and move the files to their current locations. It dose not delete any older versions on your server.</p>
<ul>
<li>The <strong><em>TFTPDIR</em></strong> variable is the location on your tftp server where the MiniMyth files are stored.</li>
<li>The <strong><em>URL</em></strong> variable is the MiniMyth directory that the install of MiniMyth you wish to use lives.</li>
</ul>
<p>You may also download the full directory structure with this script from <a href="https://github.com/mattrude/minimyth-build-script" target="_self">my github repository</a> or from my server.</p>
<pre># /bin/bash
# Matt Rude &lt;m@mattrude.com&gt; 11-Nov-2009
#
TFTPDIR=/tftpboot/PXEClient
URL="http://minimyth.org/download/stable/latest/"
##############################################################################
if [ -e $TFTPDIR/version ]; then
 mv $TFTPDIR/version $TFTPDIR/version.last
 rm -rf $TFTPDIR/verstion.md5
else
 touch $TFTPDIR/version.log
 touch $TFTPDIR/version.last
fi

cd $TFTPDIR
wget -nc $URL/version &gt; /dev/null 2&gt;&amp;1
VER=`cat $TFTPDIR/version`
OLDVER=`cat $TFTPDIR/version.last`

if [ "$VER" = "$OLDVER" ]; then
 chown -R apache:apache $TFTPDIR/*
 exit 0
else
 echo "`date` Upgraded to version: $VER" &gt;&gt; version.log

 rm -rf $TFTPDIR/ram-minimyth-*.tar.bz2.md5
 wget -nc $URL/ram-minimyth-$VER.tar.bz2 &gt; /dev/null 2&gt;&amp;1
 wget -nc $URL/ram-minimyth-$VER.tar.bz2.md5 &gt; /dev/null 2&gt;&amp;1
 MD5STAT=`md5sum -c ram-minimyth-$VER.tar.bz2.md5 |awk ' {print $2 }'`
 if [ "$MD5STAT" = "OK" ]; then
  rm -f $TFTPDIR/kerne*
  rm -f $TFTPDIR/rootf*
  rm -fr $TFTPDIR/conf/default/theme*
  tar -xjf ram-minimyth-$VER.tar.bz2
  rm -rf ram-minimyth-$VER.*
 else
  echo "`date` Minimyth Version $VER Failed the MD5 check" &gt;&gt; version.log
  echo "" &gt; $TFTPDIR/version
  exit 1
 fi

 RAMDIR=$TFTPDIR/ram-minimyth-$VER

 mkdir -p $TFTPDIR/conf/default
 cp $RAMDIR/kernel $TFTPDIR/kernel-$VER
 cp $RAMDIR/rootfs $TFTPDIR/rootfs-$VER
 cp -r $RAMDIR/themes $TFTPDIR/conf/default/themes-$VER

 ln -s kernel-$VER kernel
 ln -s rootfs-$VER rootfs
 cd $TFTPDIR/conf/default
 ln -s themes-$VER themes
 #mythtvosd --template=scroller --scroll_text="minimyth upgraded to: $VER" &gt; /dev/null
fi

cd $TFTPDIR
mv version.log version.tmp
tail -2 version.tmp &gt; version.log
rm -rf version.tmp
chown -R apache:apache $TFTPDIR/*
exit 0
</pre>
<a href="http://technology.mattrude.com/2009/11/auto-update-script-for-minimyth/">Auto Update Script for MiniMyth</a> is a post from; <a href="http://technology.mattrude.com/">Matt&#039;s Technology Blog</a> which is not allowed to be copied on other sites.]]></content:encoded>
			<wfw:commentRss>http://technology.mattrude.com/2009/11/auto-update-script-for-minimyth/feed/</wfw:commentRss>
		<slash:comments>0</slash:comments>
		</item>
		<item>
		<title>Next Gallery Image Link in Image Posts</title>
		<link>http://technology.mattrude.com/2009/10/next-gallery-image-link-in-image-posts/</link>
		<comments>http://technology.mattrude.com/2009/10/next-gallery-image-link-in-image-posts/#comments</comments>
		<pubDate>Tue, 27 Oct 2009 17:51:32 +0000</pubDate>
		<dc:creator>Matt Rude</dc:creator>
				<category><![CDATA[How-To's]]></category>
		<category><![CDATA[HTML element]]></category>
		<category><![CDATA[Languages]]></category>
		<category><![CDATA[Metadata]]></category>
		<category><![CDATA[php]]></category>
		<category><![CDATA[Programming]]></category>
		<category><![CDATA[WordPress]]></category>
		<category><![CDATA[WordPress Plugin Directory]]></category>

		<guid isPermaLink="false">http://mattrude.com/?p=1477</guid>
		<description><![CDATA[If you were to view one of the images in my WordPress gallery, such as my Minnesota State Fair – 2009 gallery, and view one of the images.  You will see a previous and next image on the bottom of &#8230; <a href="http://technology.mattrude.com/2009/10/next-gallery-image-link-in-image-posts/">Continue reading <span class="meta-nav">&#8594;</span></a><a href="http://technology.mattrude.com/2009/10/next-gallery-image-link-in-image-posts/">Next Gallery Image Link in Image Posts</a> is a post from; <a href="http://technology.mattrude.com/">Matt&#039;s Technology Blog</a> which is not allowed to be copied on other sites.]]></description>
			<content:encoded><![CDATA[<p>If you were to view one of the images in my WordPress gallery, such as my <a href="http://mattrude.com/2009/09/minnesota-state-fair-2009/" target="_blank">Minnesota State Fair – 2009</a> gallery, and view one of the images.  You will see a previous and next image on the bottom of the image page.  As you may of already of guessed, the next and previous images are all part of the way my theme handles image pages.</p>
<p>In order to do this, I needed to add the below snippet to my image.php file.  You should already have a &#8220;navigation&#8221; section, find it, and replace it with the below code <strong>(MAKE SURE YOU BACK UP YOUR IMAGE.PHP FILE FIRST)</strong>.</p>
<pre>&lt;div class="image-navigation"&gt;
	&lt;?php $attachments = array_values(get_children( array('post_parent' =&gt; $post-&gt;post_parent, 'post_status' =&gt; 'inherit', 'post_type' =&gt; 'attachment', 'post_mime_type' =&gt; 'image', 'order' =&gt; 'ASC', 'orderby' =&gt; 'menu_order ID') ));
	foreach ( $attachments as $k =&gt; $attachment )
		if ( $attachment-&gt;ID == $post-&gt;ID )
			break;
	$attachments = array_values(get_children( array('post_parent' =&gt; $post-&gt;post_parent, 'post_status' =&gt; 'inherit', 'post_type' =&gt; 'attachment', 'post_mime_type' =&gt; 'image', 'order' =&gt; 'ASC', 'orderby' =&gt; 'menu_order ID') ));
       $next_url =  isset($attachments[$k+1]) ? get_permalink($attachments[$k+1]-&gt;ID) : get_permalink($attachments[0]-&gt;ID);
       $previous_url =  isset($attachments[$k-1]) ? get_permalink($attachments[$k-1]-&gt;ID) : get_permalink($attachments[0]-&gt;ID);
	if ( wp_get_attachment_image( $post-&gt;ID+1 ) != null ) { ?&gt;
		&lt;p class="attachment"&gt;
			Next Image&lt;br /&gt;
			&lt;a href="&lt;?php echo $next_url; ?&gt;"&gt;&lt;?php echo wp_get_attachment_image( $post-&gt;ID+1, 'thumbnail' ); ?&gt;&lt;/a&gt;
		&lt;/p&gt;
    &lt;?php }

    if ( wp_get_attachment_image( $post-&gt;ID-1 ) != null ) { ?&gt;
        &lt;p class="attachment"&gt;
            Previous Image&lt;br /&gt;
            &lt;a href="&lt;?php echo $previous_url; ?&gt;"&gt;&lt;?php echo wp_get_attachment_image( $post-&gt;ID-1, 'thumbnail' ); ?&gt;&lt;/a&gt;
        &lt;/p&gt;
    &lt;?php } ?&gt;
&lt;/div&gt;
</pre>
<a href="http://technology.mattrude.com/2009/10/next-gallery-image-link-in-image-posts/">Next Gallery Image Link in Image Posts</a> is a post from; <a href="http://technology.mattrude.com/">Matt&#039;s Technology Blog</a> which is not allowed to be copied on other sites.]]></content:encoded>
			<wfw:commentRss>http://technology.mattrude.com/2009/10/next-gallery-image-link-in-image-posts/feed/</wfw:commentRss>
		<slash:comments>7</slash:comments>
		</item>
		<item>
		<title>WordPress 2.9 Post Thumbnail Function</title>
		<link>http://technology.mattrude.com/2009/10/wordpress-2-9-post-thumbnail-function/</link>
		<comments>http://technology.mattrude.com/2009/10/wordpress-2-9-post-thumbnail-function/#comments</comments>
		<pubDate>Mon, 12 Oct 2009 01:26:24 +0000</pubDate>
		<dc:creator>Matt Rude</dc:creator>
				<category><![CDATA[How-To's]]></category>
		<category><![CDATA[Cascading Style Sheets]]></category>
		<category><![CDATA[FAQs Help and Tutorials]]></category>
		<category><![CDATA[Photograph]]></category>
		<category><![CDATA[Thumbnail]]></category>
		<category><![CDATA[WordPress]]></category>
		<category><![CDATA[WordPress Plugin Directory]]></category>

		<guid isPermaLink="false">http://mattrude.com/?p=1392</guid>
		<description><![CDATA[WordPress 2.9 brings a new function for users of gallery&#8217;s the add_theme_support(&#8216;post-thumbnails&#8217;) function. with this you will get a new item on your new post window named Post Thumbnail (see right).  After you have added a post Thumbnail to a &#8230; <a href="http://technology.mattrude.com/2009/10/wordpress-2-9-post-thumbnail-function/">Continue reading <span class="meta-nav">&#8594;</span></a><a href="http://technology.mattrude.com/2009/10/wordpress-2-9-post-thumbnail-function/">WordPress 2.9 Post Thumbnail Function</a> is a post from; <a href="http://technology.mattrude.com/">Matt&#039;s Technology Blog</a> which is not allowed to be copied on other sites.]]></description>
			<content:encoded><![CDATA[<p><a href="http://tech.mattrude.com/wp-content/uploads/2009/10/post_thumbnail.png"><img class="alignright size-full wp-image-1391" src="http://tech.mattrude.com/wp-content/uploads/2009/10/post_thumbnail.png" alt="post_thumbnail" width="308" height="74" /></a>WordPress 2.9 brings a new function for users of gallery&#8217;s the <em>add_theme_support(&#8216;post-thumbnails&#8217;)</em> function. with this you will get a new item on your new post window named <strong>Post Thumbnail </strong>(<em>see right</em>).  After you have added a post Thumbnail to a post, you need to display it.  By using a &#8220;gallery&#8221; category, creating the below two files (or adding the code to files) and editing your category.php file, you may display a custom gallery page.</p>
<ul>
<li><a href="http://mattrude.com/category/gallery/" target="_blank">See a example here</a></li>
</ul>
<p>To start, create a new file named <em>gallery-function.php</em> and add the following code to it, this file should live in the root of your current theme&#8217;s directory.</p>
<p><strong>gallery-function.php</strong></p>
<pre>&lt;link rel="stylesheet" href="&lt;?php bloginfo('template_url'); ?&gt;gallery-function.css" type="text/css" media="screen" /&gt;
&lt;div id="gallerypost-&lt;?php the_ID(); ?&gt;"&gt;
    &lt;div id="gallerypost_main-&lt;?php the_ID(); ?&gt;"&gt;
	&lt;div id="gallerypost_thumbnail-&lt;?php the_ID(); ?&gt;"&gt;
		&lt;?php post_thumbnail(); ?&gt;
	&lt;/div&gt;
	&lt;div id="gallerypost_body-&lt;?php the_ID(); ?&gt;"&gt;
		&lt;?php $images =&amp; get_children( 'post_type=attachment&amp;post_mime_type=image' ); ?&gt;
		&lt;h2&gt;&lt;a rel="bookmark" href="&lt;?php the_permalink(); ?&gt;"&gt;&lt;?php the_title(); ?&gt;&lt;/a&gt;&lt;/h2&gt;
		&lt;div&gt;&lt;small&gt;Posted by &lt;?php the_author_posts_link(); ?&gt; on &lt;?php the_time('F jS, Y') ?&gt;&lt;/small&gt;&lt;/div&gt;
		&lt;div&gt;
			&lt;?php the_excerpt(); ?&gt;
		&lt;/div&gt;
	&lt;/div&gt;
    &lt;/div&gt;
    &lt;div id="gallerypost_sub-&lt;?php the_ID(); ?&gt;"&gt;
	&lt;div id="gallerypost_sub_left-&lt;?php the_ID(); ?&gt;"&gt;
		&lt;p&gt;&lt;?php echo get_the_term_list( $post-&gt;ID, 'people', 'Who: ', ', ', '&lt;br /&gt;' ); ?&gt;&lt;/p&gt;
		&lt;p&gt;&lt;?php echo get_the_term_list( $post-&gt;ID, 'events', 'What: ', ', ', '&lt;br /&gt;' ); ?&gt;&lt;/p&gt;
             	&lt;p&gt;&lt;?php echo get_the_term_list( $post-&gt;ID, 'places', 'Where: ', ', ', '' ); ?&gt;&lt;/p&gt;
	&lt;/div&gt;
	&lt;div id"gallerypost_sub_right-&lt;?php the_ID(); ?&gt;"&gt;
		This Album contains &lt;?php echo $wpdb-&gt;get_var( "SELECT COUNT(*) FROM $wpdb-&gt;posts WHERE post_parent = '$post-&gt;ID' AND post_type = 'attachment'" ); ?&gt; items.
	&lt;/div&gt;
    &lt;/div&gt;
&lt;/div&gt;</pre>
<p>Next create a file named <em>gallery-function.css</em> and also add it to our current theme&#8217;s root directory.<br />
<strong>gallery-function.css</strong></p>
<pre>.gallerypost {
        background-color:#fff;
        display: block;
        hNeight: 300px;
        margin: 0px 0px 10px 0px;
        padding: 20px 10px 10px 10px;
        overflow: hidden;
        border-bottom: 1px solid #D2C4A2;
        }
.gallerypost_body {
        float: right;
        width: 430px;
        margin: 0 20px 0 0;
        }
.gallerypost_body p {
        margin: 50px 0px 0px 0px;
        }
.gallerypost_body .entry p {
        margin: 0px 0px 0px 0px;
        }
.gallerypost_body .entry {
        margin: 0px 0px 0px 0px;
        }
.gallerypost_main {
        width: 690px;
        }
.gallerypost_sub {
        display: block;
        padding: 210px 0px 0px 10px;
        }
.gallerypost_sub {
        display: block;
        padding: 210px 0px 0px 10px;
        }
.gallerypost_sub p {
        vertical-align: bottom;
        margin: 0;
        }
.gallerypost_sub_left {
        width: 220px;
        display: block;
        float: left;
        }
.gallerypost_sub_right {
        width: 220px;
        display: block;
        float: right;
        }
.gallerypost_thumbnail {
        float: left;
        }
.gallerypost_thumbnail img {
        margin: 0 0 0 10px;
        color: #000;
        }</pre>
<p>And lastly you will need to add the following to your <em>functions.php</em> file in your current theme&#8217;s root directory (you may add it anywhere in <em>functions.php</em>).</p>
<pre>add_theme_support('post-thumbnails');
set_post_thumbnail_size(200, 200);</pre>
<p>Now that we have our functions built, we need to add some code to your <em>category.php</em> file.</p>
<p>Right after:</p>
<pre>&lt;?php while (have_posts()) : the_post(); ?&gt;</pre>
<p>Add the following code.  This will display the <em>gallery-function.php</em> code when a post is in the &#8220;gallery&#8221; category.</p>
<pre>&lt;? if ( is_category( 'gallery' )) {
                    include('gallery-index.php');
               } else { ?&gt;</pre>
<p>Next Before:</p>
<pre>&lt;?php endwhile; ?&gt;</pre>
<p>Add the following to close the if statement.</p>
<pre>&lt;?php } ?&gt;</pre>
<p>And that should do it, you should now see the post image on the gallery category page similar to below.</p>
<p><a href="http://tech.mattrude.com/wp-content/uploads/2009/10/Gallery-screenshot.jpg"><img class="alignnone size-full wp-image-1420" src="http://tech.mattrude.com/wp-content/uploads/2009/10/Gallery-screenshot.jpg" alt="Gallery-screenshot" width="678" height="246" /></a></p>
<a href="http://technology.mattrude.com/2009/10/wordpress-2-9-post-thumbnail-function/">WordPress 2.9 Post Thumbnail Function</a> is a post from; <a href="http://technology.mattrude.com/">Matt&#039;s Technology Blog</a> which is not allowed to be copied on other sites.]]></content:encoded>
			<wfw:commentRss>http://technology.mattrude.com/2009/10/wordpress-2-9-post-thumbnail-function/feed/</wfw:commentRss>
		<slash:comments>7</slash:comments>
		</item>
		<item>
		<title>Postfix: remap from addresses with a generic map</title>
		<link>http://technology.mattrude.com/2009/09/postfix-remap-from-addresses-with-a-generic-map/</link>
		<comments>http://technology.mattrude.com/2009/09/postfix-remap-from-addresses-with-a-generic-map/#comments</comments>
		<pubDate>Sun, 27 Sep 2009 16:27:30 +0000</pubDate>
		<dc:creator>Matt Rude</dc:creator>
				<category><![CDATA[How-To's]]></category>
		<category><![CDATA[Email address]]></category>
		<category><![CDATA[Example.com]]></category>
		<category><![CDATA[MySQL]]></category>
		<category><![CDATA[Postfix]]></category>
		<category><![CDATA[Servers]]></category>
		<category><![CDATA[SpamAssassin]]></category>

		<guid isPermaLink="false">http://mattrude.com/?p=1366</guid>
		<description><![CDATA[Depending on the software you are using, you may need to change the outbound (from) address of outbound email.  In this How-To, we will change the outbound email address from &#8220;apache@example.com&#8221; to &#8220;webmaster@example.com&#8221;. To start out, go to your postfix &#8230; <a href="http://technology.mattrude.com/2009/09/postfix-remap-from-addresses-with-a-generic-map/">Continue reading <span class="meta-nav">&#8594;</span></a><a href="http://technology.mattrude.com/2009/09/postfix-remap-from-addresses-with-a-generic-map/">Postfix: remap from addresses with a generic map</a> is a post from; <a href="http://technology.mattrude.com/">Matt&#039;s Technology Blog</a> which is not allowed to be copied on other sites.]]></description>
			<content:encoded><![CDATA[<p>Depending on the software you are using, you may need to change the outbound (from) address of outbound email.  In this How-To, we will change the outbound email address from &#8220;apache@example.com&#8221; to &#8220;webmaster@example.com&#8221;.</p>
<p>To start out, go to your postfix directory and modify/create your generic file.  Your generic file will map the two addresses to each other.  At the end of your generic file add a space or tab seperated file simmiler to this.</p>
<pre>apache@example.com         webmaster@example.com</pre>
<p>Once you have added the entries to your generic file, you need to hash the file so postfix may quickly access it.</p>
<pre>postmap /etc/postfix/generic</pre>
<p>After you map has been created, you will need to add the entry to your main.cf file to tell Postfix to use your generic map.</p>
<pre>smtp_generic_maps = hash:/etc/postfix/generic</pre>
<p>Once you have updated your main.cf file, you need to reload postfix</p>
<pre>postfix reload</pre>
<a href="http://technology.mattrude.com/2009/09/postfix-remap-from-addresses-with-a-generic-map/">Postfix: remap from addresses with a generic map</a> is a post from; <a href="http://technology.mattrude.com/">Matt&#039;s Technology Blog</a> which is not allowed to be copied on other sites.]]></content:encoded>
			<wfw:commentRss>http://technology.mattrude.com/2009/09/postfix-remap-from-addresses-with-a-generic-map/feed/</wfw:commentRss>
		<slash:comments>2</slash:comments>
		</item>
		<item>
		<title>wp reCAPTCHA form version 0.1 released</title>
		<link>http://technology.mattrude.com/2009/09/wp-recaptcha-form-version-0-1-released/</link>
		<comments>http://technology.mattrude.com/2009/09/wp-recaptcha-form-version-0-1-released/#comments</comments>
		<pubDate>Fri, 18 Sep 2009 05:54:37 +0000</pubDate>
		<dc:creator>Matt Rude</dc:creator>
				<category><![CDATA[General]]></category>
		<category><![CDATA[Google]]></category>
		<category><![CDATA[Plugin]]></category>
		<category><![CDATA[reCAPTCHA]]></category>
		<category><![CDATA[Tools]]></category>
		<category><![CDATA[WordPress]]></category>

		<guid isPermaLink="false">http://mattrude.com/?p=1207</guid>
		<description><![CDATA[I have released wp-reCAPTCHA version 0.1. This plugin will allows you to also add subjects to your contact form.  Please check it out on it page at http://mattrude.com/projects/wp-recaptcha-form/. wp reCAPTCHA form version 0.1 released is a post from; Matt&#039;s Technology &#8230; <a href="http://technology.mattrude.com/2009/09/wp-recaptcha-form-version-0-1-released/">Continue reading <span class="meta-nav">&#8594;</span></a><a href="http://technology.mattrude.com/2009/09/wp-recaptcha-form-version-0-1-released/">wp reCAPTCHA form version 0.1 released</a> is a post from; <a href="http://technology.mattrude.com/">Matt&#039;s Technology Blog</a> which is not allowed to be copied on other sites.]]></description>
			<content:encoded><![CDATA[<p>I have released wp-reCAPTCHA version 0.1. This plugin will allows you to also add subjects to your contact form.  Please check it out on it page at <a href="http://mattrude.com/projects/wp-recaptcha-form/" target="_self">http://mattrude.com/projects/wp-recaptcha-form/</a>.</p>
<a href="http://technology.mattrude.com/2009/09/wp-recaptcha-form-version-0-1-released/">wp reCAPTCHA form version 0.1 released</a> is a post from; <a href="http://technology.mattrude.com/">Matt&#039;s Technology Blog</a> which is not allowed to be copied on other sites.]]></content:encoded>
			<wfw:commentRss>http://technology.mattrude.com/2009/09/wp-recaptcha-form-version-0-1-released/feed/</wfw:commentRss>
		<slash:comments>0</slash:comments>
		</item>
		<item>
		<title>Installing Postfix with SQLite Support</title>
		<link>http://technology.mattrude.com/2009/09/installing-postfix-with-sqlite-support/</link>
		<comments>http://technology.mattrude.com/2009/09/installing-postfix-with-sqlite-support/#comments</comments>
		<pubDate>Sun, 13 Sep 2009 19:12:05 +0000</pubDate>
		<dc:creator>Matt Rude</dc:creator>
				<category><![CDATA[How-To's]]></category>
		<category><![CDATA[Database]]></category>
		<category><![CDATA[Null (SQL)]]></category>
		<category><![CDATA[Postfix (software)]]></category>
		<category><![CDATA[SpamAssassin]]></category>
		<category><![CDATA[SQL]]></category>
		<category><![CDATA[SQLite]]></category>
		<category><![CDATA[Tools]]></category>

		<guid isPermaLink="false">http://mattrude.com/?p=1176</guid>
		<description><![CDATA[This How-to will show you how to set up Postfix with SQLite support on a Fedora 11 system.  This will require us to compile Postfix from scratch. Installing the dependences yum -y install sqlite sqlite-devel gcc make patch db4-devel cyrus-sasl-devel &#8230; <a href="http://technology.mattrude.com/2009/09/installing-postfix-with-sqlite-support/">Continue reading <span class="meta-nav">&#8594;</span></a><a href="http://technology.mattrude.com/2009/09/installing-postfix-with-sqlite-support/">Installing Postfix with SQLite Support</a> is a post from; <a href="http://technology.mattrude.com/">Matt&#039;s Technology Blog</a> which is not allowed to be copied on other sites.]]></description>
			<content:encoded><![CDATA[<p>This How-to will show you how to set up Postfix with SQLite support on a Fedora 11 system.  This will require us to compile Postfix from scratch.</p>
<h3><span>Installing the dependences </span></h3>
<pre>yum -y install sqlite sqlite-devel gcc make patch db4-devel cyrus-sasl-devel
echo "postfix:x:89:89::/var/spool/postfix:/sbin/nologin" &gt;&gt; /etc/passwd
echo "postdrop:x:90:90::/var/spool/postfix:/sbin/nologin" &gt;&gt; /etc/passwd
echo "postfix:x:89:" &gt;&gt; /etc/group
echo "postdrop:x:90:" &gt;&gt; /etc/group
ln -s /usr/lib/sasl2/ /usr/local/lib/sasl2</pre>
<h3><span>Download and Patch Postfix </span></h3>
<p>Download and unpack the current Postfix Version.</p>
<pre>wget http://postfix.energybeam.com/source/official/postfix-2.6.5.tar.gz
tar -xzf postfix-2.6.5.tar.gz
cd postfix-2.6.5</pre>
<p>Download and Patch Postfix with the SQLite Postfix patch</p>
<pre>wget http://www.treibsand.com/postfix-sqlite/postfix-2.6-20080216_sqlite.patch
patch -ul -d . -p1 &lt; postfix-2.6-20080216_sqlite.patch
echo $?</pre>
<h3><span>Building Postfix </span></h3>
<p><strong>To Build with SQLite Support</strong></p>
<pre>make -f Makefile.init makefiles 'CCARGS=-DHAS_SQLITE -I/usr/local/include' 
'AUXLIBS=-L/usr/local/lib -lsqlite3'
echo $?</pre>
<p><strong>Or to Build with SQLite &amp; TLS Support</strong><br />
Requires:</p>
<pre>yum -y install openssl-devel
make -f Makefile.init makefiles 'CCARGS=-DHAS_SQLITE -I/usr/local/include -DUSE_TLS' 
'AUXLIBS=-L/usr/local/lib -lsqlite3 -lz -lm -lssl -lcrypto'
echo $?</pre>
<p><strong>To Build with SQLite, Dovecot, &amp; TLS Support</strong></p>
<pre>yum -y install openssl-devel dovecot-devel
make makefiles 'CCARGS=-DHAS_SQLITE -I/usr/include/sasl/ -DUSE_SASL_AUTH -DUSE_CYRUS_SASL  -DDEF_SERVER_SASL_TYPE="dovecot" -DUSE_TLS' -I/usr/local/include 
   'AUXLIBS=-L/usr/local/lib -lsqlite3 -lz -lm -lssl -lcrypto -lsasl2'
echo $?</pre>
<h3>Compiling Postfix</h3>
<p>Now Compile Postfix</p>
<pre>make
echo $?</pre>
<p><strong>And Install it</strong></p>
<pre>make install</pre>
<h2><span>Building the SQLite Database </span></h2>
<p>In order to use the SQLite function, you need a SQLite database.  First using SQLite3 run</p>
<pre>sqlite3 /etc/postfix/postfix.sqlite</pre>
<p>To create the database, then you can copy and past the following scheme into the new database.</p>
<pre>CREATE TABLE alias (
  address varchar(255) NOT NULL,
  goto text NOT NULL,
  domain varchar(255) NOT NULL,
  created datetime NOT NULL default '0000-00-00 00:00:00',
  modified datetime NOT NULL default '0000-00-00 00:00:00',
  active tinyint(1) NOT NULL default '1');

CREATE TABLE domain (
  domain varchar(255) NOT NULL,
  description varchar(255) NOT NULL,
  aliases int(10) NOT NULL default '0',
  mailboxes int(10) NOT NULL default '0',
  maxquota bigint(20) NOT NULL default '0',
  quota bigint(20) NOT NULL default '0',
  transport varchar(255) NOT NULL,
  backupmx tinyint(1) NOT NULL default '0',
  created datetime NOT NULL default '0000-00-00 00:00:00',
  modified datetime NOT NULL default '0000-00-00 00:00:00',
  active tinyint(1) NOT NULL default '1' );

CREATE TABLE mailbox (
  username varchar(255) NOT NULL,
  password varchar(255) NOT NULL,
  name varchar(255) NOT NULL,
  maildir varchar(255) NOT NULL,
  quota bigint(20) NOT NULL default '0',
  domain varchar(255) NOT NULL,
  created datetime NOT NULL default '0000-00-00 00:00:00',
  modified datetime NOT NULL default '0000-00-00 00:00:00',
  active tinyint(1) NOT NULL default '1',
  local_part varchar(255) NOT NULL );</pre>
<p>Then close the database</p>
<pre>.quit</pre>
<p>Or you may download mine from below and use the same scheme work.</p>
<ul>
<li> <a title="Postfix.sqlite" href="http://wiki.mattrude.com/images/1/15/Postfix.sqlite">postfix.sqlite</a></li>
</ul>
<p>Once you have your database file place it in <strong>/etc/postfix/</strong> as something like <strong>/etc/postfix/postfix.sqlite</strong> then run</p>
<pre>chown root:root /etc/postfix/postfix.sqlite
chmod 600 /etc/postfix/postfix.sqlite</pre>
<h2><span>Configuring Postfix </span></h2>
<p>Now add the maps to you config.</p>
<p><strong>/etc/postfix/main.cf</strong></p>
<pre>relay_domains = sqlite:/etc/postfix/sqlite_relay_domains_maps.cf
relay_recipient_maps = sqlite:/etc/postfix/sqlite_relay_recipient_maps.cf
virtual_alias_maps = sqlite:/etc/postfix/sqlite_virtual_alias_maps.cf
virtual_mailbox_domains = sqlite:/etc/postfix/sqlite_virtual_domains_maps.cf
virtual_mailbox_maps = sqlite:/etc/postfix/sqlite_virtual_mailbox_maps.cf

virtual_mailbox_base = /var/spool/virtualmailboxes
virtual_minimum_uid= 1000
virtual_uid_maps = static:1000
virtual_gid_maps = static:1000</pre>
<p><strong>sqlite_relay_domains_maps.cf</strong></p>
<pre>dbpath = /etc/postfix/postfix.sqlite
query = SELECT domain FROM domain WHERE domain='%s' AND backupmx = '1' AND active = '1'</pre>
<p><strong>sqlite_relay_recipient_maps.cf</strong></p>
<pre>dbpath = /etc/postfix/postfix.sqlite
query = SELECT goto FROM alias WHERE address='%s' AND active = 1</pre>
<p><strong>sqlite_virtual_alias_maps.cf</strong></p>
<pre>dbpath = /etc/postfix/postfix.sqlite
query = SELECT goto FROM alias WHERE address='%s' AND active = '1'</pre>
<p><strong>sqlite_virtual_domains_maps.cf</strong></p>
<pre>dbpath = /etc/postfix/postfix.sqlite
query = SELECT domain FROM domain WHERE domain='%s' AND backupmx = '0' AND active = '1'</pre>
<p><strong>sqlite_virtual_mailbox_maps.cf</strong></p>
<pre>dbpath = /etc/postfix/postfix.sqlite
query = SELECT maildir FROM mailbox WHERE username='%s' AND active = '1'</pre>
<h2><span>Setting up a fresh install of Postfix </span></h2>
<pre>mkdir /var/spool/virtualmailboxes/
echo "virtualmail:x:1000:1000::/var/spool/virtualmailboxes:/sbin/nologin" &gt;&gt; /etc/passwd
echo "virtualmail:x:1000:" &gt;&gt; /etc/group
chmod 700 /var/spool/virtualmailboxes/
chown -R virtualmail:virtualmail /var/spool/virtualmailboxes/
rm -f /usr/lib/sendmail
ln -s /usr/sbin/sendmail /usr/lib/sendmail</pre>
<h2><span>Adding SQLite entry&#8217;s </span></h2>
<p><strong>First add a Domain</strong></p>
<pre>echo "INSERT INTO domain ( domain, description, transport )
VALUES ( 'laptop.mattrude.com', 'laptops domain', 'virtual' );" |sqlite3 /etc/postfix/postfix.sqlite</pre>
<p><strong> Then add a user</strong></p>
<pre>echo "INSERT INTO mailbox ( username, password, name, maildir, domain, local_part )
VALUES ( 'matt@laptop.mattrude.com', 'password', 'Matt', 'laptop.mattrude.com/matt@laptop.mattrude.com/', 'laptop.mattrude.com', 'matt' );" |sqlite3 /etc/postfix/postfix.sqlite</pre>
<p><strong>Last we need to add the mailboxes alias</strong></p>
<pre>echo "INSERT INTO alias ( address, goto, domain )
VALUES ( 'matt@laptop.mattrude.com', 'matt@laptop.mattrude.com', 'laptop.mattrude.com' );" |sqlite3 /etc/postfix/postfix.sqlite
</pre>
<p>Next, contue on to my <a href="http://technology.mattrude.com/2009/12/installing-dovecot-using-sqlite/">Dovecot SQLite how-to</a> to finish your email server.</p>
<a href="http://technology.mattrude.com/2009/09/installing-postfix-with-sqlite-support/">Installing Postfix with SQLite Support</a> is a post from; <a href="http://technology.mattrude.com/">Matt&#039;s Technology Blog</a> which is not allowed to be copied on other sites.]]></content:encoded>
			<wfw:commentRss>http://technology.mattrude.com/2009/09/installing-postfix-with-sqlite-support/feed/</wfw:commentRss>
		<slash:comments>2</slash:comments>
		</item>
		<item>
		<title>RoundCube Regression Testing</title>
		<link>http://technology.mattrude.com/2009/09/roundcube-regression-testing/</link>
		<comments>http://technology.mattrude.com/2009/09/roundcube-regression-testing/#comments</comments>
		<pubDate>Sun, 06 Sep 2009 04:09:20 +0000</pubDate>
		<dc:creator>Matt Rude</dc:creator>
				<category><![CDATA[General]]></category>
		<category><![CDATA[Address book]]></category>
		<category><![CDATA[Clients]]></category>
		<category><![CDATA[E-mail spam]]></category>
		<category><![CDATA[email]]></category>
		<category><![CDATA[Mail]]></category>
		<category><![CDATA[Regression testing]]></category>
		<category><![CDATA[Software development]]></category>

		<guid isPermaLink="false">http://mattrude.com/?p=967</guid>
		<description><![CDATA[With the release of RoundCube 0.3-stable and all the upgrades that will happen, It feels like a good time to talk about regression testing.  Regression testing is when you test the functions of a peace of software to make sure &#8230; <a href="http://technology.mattrude.com/2009/09/roundcube-regression-testing/">Continue reading <span class="meta-nav">&#8594;</span></a><a href="http://technology.mattrude.com/2009/09/roundcube-regression-testing/">RoundCube Regression Testing</a> is a post from; <a href="http://technology.mattrude.com/">Matt&#039;s Technology Blog</a> which is not allowed to be copied on other sites.]]></description>
			<content:encoded><![CDATA[<p>With the release of <a title="RoundCube's Website" href="http://www.roundcube.net" target="_blank">RoundCube</a> <a href="http://trac.roundcube.net/wiki/Changelog" target="_blank">0.3-stable</a> and all the upgrades that will happen, It feels like a good time to talk about regression testing.  Regression testing is when you test the functions of a peace of software to make sure that your updates didn&#8217;t break any functions.  In RoundCube it takes me about 10 minuets to fully test a site.  Here&#8217;s my check list, yours my vary depending on the plugins your using.</p>
<h3><span>Main Screen </span></h3>
<ul>
<li>Read a <strong>HTML</strong> message from the preview panel
<ul>
<li>Confirm the &#8220;<strong>View Header</strong>&#8221; drop down window works with HTML messages</li>
</ul>
</li>
<li>Read a <strong>Plain Text</strong> message from the preview panel
<ul>
<li>Confirm the &#8220;<strong>View Header</strong>&#8221; drop down window works with Plain Text messages</li>
</ul>
</li>
<li>Read a <strong>HTML</strong> message full screen
<ul>
<li>Confirm the &#8220;View Header&#8221; drop down window works with HTML messages</li>
<li>Confirm the &#8220;Read Source&#8221; button works with HTML messages</li>
</ul>
</li>
<li>Read a <strong>Plain Text</strong> message full screen
<ul>
<li>Confirm the &#8220;View Header&#8221; drop down window works with Plain Text messages</li>
<li>Confirm the &#8220;Read Source&#8221; button works with Plain Text messages</li>
</ul>
</li>
<li>Change Message pages</li>
<li>Select <strong>All</strong>, <strong>Unread</strong>, <strong>None</strong> from the bottom center</li>
<li>Is the <strong>quota meter</strong> displaying</li>
<li>Flag (star) a message</li>
<li>Search for a known message value</li>
<li>Move a message from Inbox to a folder</li>
<li>Move a message from a folder to the Inbox</li>
<li>Send a message to an internal account</li>
<li>Send a message to an external account</li>
<li>Add a message via the plus symbol when viewing a message
<ul>
<li> Dose it show up in Personal Settings / Spam / Address Rules</li>
</ul>
</li>
</ul>
<h3><span>Address Book </span></h3>
<ul>
<li>Add an Address Book entry
<ul>
<li> Dose it show up in Personal Settings / Spam / Address Rules</li>
</ul>
</li>
<li>Change an existing entry</li>
<li>&#8220;<strong>Compose Mail To</strong>&#8221; button, top center</li>
<li>&#8220;<strong>Export Contacts in vCard format</strong>&#8221; button, top center</li>
<li>&#8220;Import Contacts&#8221; button, top center</li>
<li>Delete a contact
<ul>
<li> Dose it delete from Personal Settings / Spam / Address Rules</li>
</ul>
</li>
</ul>
<h3><span>Personal Settings / Folders </span></h3>
<ul>
<li>Subscribe to a folder</li>
<li>Unsubscribe from a folder</li>
<li>Add a folder</li>
<li>Delete a folder</li>
</ul>
<h3><span>Personal Settings / Identities </span></h3>
<ul>
<li>Add a new &#8220;Identity&#8221;
<ul>
<li>Send a message with this identity</li>
</ul>
</li>
<li>Modify an existing &#8220;Identity&#8221;
<ul>
<li>Send a message with this identity</li>
</ul>
</li>
<li>Delete an Identity</li>
<li>Change <strong>default</strong> Identity&#8217;s</li>
</ul>
<h3><span>Personal Settings / Spam </span></h3>
<ul>
<li>Add a new white list entry</li>
<li>Add a new black list entry</li>
<li>Delete a white list entry</li>
<li>Delete a black list entry</li>
</ul>
<a href="http://technology.mattrude.com/2009/09/roundcube-regression-testing/">RoundCube Regression Testing</a> is a post from; <a href="http://technology.mattrude.com/">Matt&#039;s Technology Blog</a> which is not allowed to be copied on other sites.]]></content:encoded>
			<wfw:commentRss>http://technology.mattrude.com/2009/09/roundcube-regression-testing/feed/</wfw:commentRss>
		<slash:comments>0</slash:comments>
		</item>
		<item>
		<title>Allow Logwatch to collect data from OpenVPN&#8217;s logs</title>
		<link>http://technology.mattrude.com/2009/08/allow-logwatch-to-collect-data-from-openvpns-logs/</link>
		<comments>http://technology.mattrude.com/2009/08/allow-logwatch-to-collect-data-from-openvpns-logs/#comments</comments>
		<pubDate>Mon, 31 Aug 2009 21:46:12 +0000</pubDate>
		<dc:creator>Matt Rude</dc:creator>
				<category><![CDATA[How-To's]]></category>
		<category><![CDATA[Cisco Systems VPN Client]]></category>
		<category><![CDATA[IP address]]></category>
		<category><![CDATA[OpenVPN]]></category>
		<category><![CDATA[Transport Layer Security]]></category>
		<category><![CDATA[Virtual private network]]></category>

		<guid isPermaLink="false">http://mattrude.com/?p=959</guid>
		<description><![CDATA[To allow Logwatch to check OpenVPN&#8217;s logs running on a Fedora or other Linux system you need to install this script &#38; conf file. In order for this script &#38; config file to work you must disable both log &#38; &#8230; <a href="http://technology.mattrude.com/2009/08/allow-logwatch-to-collect-data-from-openvpns-logs/">Continue reading <span class="meta-nav">&#8594;</span></a><a href="http://technology.mattrude.com/2009/08/allow-logwatch-to-collect-data-from-openvpns-logs/">Allow Logwatch to collect data from OpenVPN&#8217;s logs</a> is a post from; <a href="http://technology.mattrude.com/">Matt&#039;s Technology Blog</a> which is not allowed to be copied on other sites.]]></description>
			<content:encoded><![CDATA[<p>To allow Logwatch to check OpenVPN&#8217;s logs running on a Fedora or other Linux system you need to install this script &amp; conf file.</p>
<p>In order for this script &amp; config file to work you must disable both <strong>log</strong> &amp; <strong>log-append</strong> in the OpenVPN Server Config File.</p>
<pre>;log          openvpn.log
;log-append   openvpn.log</pre>
<p><strong>The Files are:</strong></p>
<pre>/etc/logwatch/scripts/openvpn      - Logwatch perl module
/etc/logwatch/conf/openvpn.conf    - Configuration file</pre>
<p><strong>/etc/logwatch/scripts/openvpn</strong></p>
<pre>#!/usr/bin/perl
##########################################################################
# $Log: openvpn,v $
# Revision 1.0  2005/07/27 17:19:34  hyppo
# Filippo Grassilli http://hyppo.com/email.php
#
# Written and maintained by:
#    Filippo Grassilli http://hyppo.com/email.php
##########################################################################

use Logwatch ':ip';

$Debug = $ENV{'LOGWATCH_DEBUG'};
$Detail = $ENV{'LOGWATCH_DETAIL_LEVEL'} || 0;
$DoLookup = $ENV{'openvpn_ip_lookup'};
$Detail = $ENV{'openvpn_detail_level'} || $Detail;

if ( $Debug &gt;= 5 ) {
   print STDERR "nnDEBUG: Inside OpenVPN Filter nn";
}

while (defined($ThisLine = &lt;STDIN&gt;)) {
   if (  # Ignore...
      ($ThisLine =~ /Control Channel/) or
      ($ThisLine =~ /Data Channel (Decrypt|Encrypt|MTU)/) or
      ($ThisLine =~ /TLS: soft reset/) or
      ($ThisLine =~ /reading client specific options/) or
      ($ThisLine =~ /Expected Remote/) or
      ($ThisLine =~ /LZO compression/) or
      ($ThisLine =~ /killed expiring key/) or
      ($ThisLine =~ /Diffie-Hellman initialized/) or
      ($ThisLine =~ /Local Options hash/) or
      ($ThisLine =~ /Replay-window backtrack/) or
      ($ThisLine =~ /TLS: Initial packet/) or
      ($ThisLine =~ /ip (addr add|link set) dev/) or
      ($ThisLine =~ /Re-using SSL/) or
      ($ThisLine =~ /MULTI: Learn/) or
      ($ThisLine =~ /Received control message/) or
      ($ThisLine =~ /(Restart pause|process restarting)/) or
      ($ThisLine =~ /Inactivity timeout/) or
      ($ThisLine =~ /CRL CHECK OK/) or
      ($ThisLine =~ /VERIFY OK: nsCertType/) or
      ($ThisLine =~ /d+:d+ SIGUSR1[.*restart/) or
      ($ThisLine =~ /^TCP/UDP: Closing socket/) or
      ($ThisLine =~ /^UDPv4 link /) or
      ($ThisLine =~ /^TUN/TAP device /) or
      ($ThisLine =~ /Closing TUN/TAP interface/) or
      ($ThisLine =~ /Interrupted system call/) or
      ($ThisLine =~ /^TLS-Auth MTU parms/) or
      ($ThisLine =~ /^MULTI:/) or
      ($ThisLine =~ /^ succeeded$/) or
      ($ThisLine =~ /^IFCONFIG POOL/)
   ) {
      # Don't care about these...
   } elsif ( ($ThisLine =~ /^OpenVPN .* built on .*/) ) {
      # OpenVPN version
      chomp($ThisLine);
      $OpenVPNVersion=$ThisLine;
   } elsif ( ($ThisLine =~ /^Initialization Sequence Completed/) ) {
      $StartOpenVPN++;
   } elsif ( ($ThisLine =~ /^SIGTERM.* process exiting/) ) {
      $ShutdownOpenVPN++;
   } elsif ( ($Host,$Cert) = ( $ThisLine =~ /^([^:]*):d+ VERIFY OK: depth=d+, (.*)$/ ) ) {
      ## Successful cert exchange
      $FullHost = LookupIP ($Host);
      $CertVerified{$Cert}{$FullHost}++;
   } elsif ( ($Host,$User) = ( $ThisLine =~ /^([^:]*):d+ [([^]]+)] Peer Connection Init/ ) ) {
      ## x.x.x.x:y [user] Peer Connection Initiated with x.x.x.x:y
      $FullHost = LookupIP ($Host);
      $ClientConnection{$User}{$FullHost}++;
   } elsif ( ($HostUser,$Param) = ( $ThisLine =~ /^([^:]*):d+ SENT CONTROL [.*]: (.*)/ ) ) {
      ## user/x.x.x.x:y SENT CONTROL [user]: xxxx....
      chomp($Param);
      $ClientParam{$HostUser}{$Param}++;
   } else {
      # Report any unmatched entries...
      chomp($ThisLine);
      $OtherList{$ThisLine}++;
   }
}

#######################################

if ( ( $Detail &gt;= 5 ) and ($StartOpenVPN) ) {
   if ($OpenVPNVersion) { print "$OpenVPNVersionn"; }
   print "OpenVPN started/reloaded: $StartOpenVPN Time(s)n";
}
if ( ( $Detail &gt;= 5 ) and ($ShutdownOpenVPN) ) {
   print "OpenVPN shutdown: $ShutdownOpenVPN Time(s)n";
}

if ( ( $Detail &gt;= 5 ) and (keys %ClientConnection) ) {
   print "nOpenVPN Client Connections:n";
   foreach $ThisOne (sort {$a cmp $b} keys %ClientConnection) {
      print "   $ThisOne:n";
      foreach $Message (sort {$a cmp $b} keys %{$ClientConnection{$ThisOne}}) {
         print "       $Message: $ClientConnection{$ThisOne}{$Message} Time(s)n";
      }
   }
}
if ( ( $Detail &gt;= 5 ) and (keys %ClientParam) ) {
   print "nOpenVPN Client Connection Parameters:n";
   foreach $ThisOne (sort {$a cmp $b} keys %ClientParam) {
      print "   $ThisOne:n";
      foreach $Message (sort {$a cmp $b} keys %{$ClientParam{$ThisOne}}) {
         print "       $Message: $ClientParam{$ThisOne}{$Message} Time(s)n";
      }
   }
}
if ( ( $Detail &gt;= 5 ) and (keys %CertVerified) ) {
   print "nCertificates verified:n";
   foreach $ThisOne (sort {$a cmp $b} keys %CertVerified) {
      ($Crt1,$Crt2) = ( $ThisOne =~ /^/(.*)/OU=(.*)$/ );
      # print " $ThisOne:n";
      print " $Crt1n OU=$Crt2:n";
      foreach $Client (sort {$a cmp $b} keys %{$CertVerified{$ThisOne}}) {
         print "       $Client: $CertVerified{$ThisOne}{$Client} Time(s)n";
      }
   }
}

if (keys %OtherList) {
   print "n**Unmatched Entries**n";
   foreach $line (sort {$a cmp $b} keys %OtherList) {
      print "   $line: $OtherList{$line} Time(s)n";
   }
}

exit(0);</pre>
<p><strong>/etc/logwatch/conf/openvpn.conf</strong></p>
<pre>###########################################################################
# $Id: openvpn.conf,v 1.0 2005/07/27 17:08:09 hyppo Exp $
# Written and maintained by:
#    Filippo Grassilli &lt;http://hyppo.com/email.php&gt;
###########################################################################

Title = "OpenVPN"

# Which logfile group...
LogFile = messages

# Whether or not to lookup the IPs into hostnames...
# Setting this to Yes will significantly increase runtime
$openvpn_ip_lookup = Yes
$openvpn_detail_level = 5

# Only give lines pertaining to the named service...
*OnlyService = openvpn
*RemoveHeaders
</pre>
<a href="http://technology.mattrude.com/2009/08/allow-logwatch-to-collect-data-from-openvpns-logs/">Allow Logwatch to collect data from OpenVPN&#8217;s logs</a> is a post from; <a href="http://technology.mattrude.com/">Matt&#039;s Technology Blog</a> which is not allowed to be copied on other sites.]]></content:encoded>
			<wfw:commentRss>http://technology.mattrude.com/2009/08/allow-logwatch-to-collect-data-from-openvpns-logs/feed/</wfw:commentRss>
		<slash:comments>0</slash:comments>
		</item>
		<item>
		<title>Setting the Time Zone on Fedora from the shell</title>
		<link>http://technology.mattrude.com/2009/08/setting-the-time-zone-on-fedora-from-the-shell/</link>
		<comments>http://technology.mattrude.com/2009/08/setting-the-time-zone-on-fedora-from-the-shell/#comments</comments>
		<pubDate>Sun, 23 Aug 2009 20:13:15 +0000</pubDate>
		<dc:creator>Matt Rude</dc:creator>
				<category><![CDATA[How-To's]]></category>
		<category><![CDATA[Central Time Zone (North America)]]></category>
		<category><![CDATA[Coordinated Universal Time]]></category>
		<category><![CDATA[Eastern Time Zone]]></category>
		<category><![CDATA[Fedora]]></category>
		<category><![CDATA[UTC]]></category>
		<category><![CDATA[webserver]]></category>

		<guid isPermaLink="false">http://www.mattrude.com/?p=703</guid>
		<description><![CDATA[By default Fedora set&#8217;s the timezone to UTC, during the install you may change this. But, if you move a server or forget to set the timezone during install.  You may change it after the fact. Lately I  moved a &#8230; <a href="http://technology.mattrude.com/2009/08/setting-the-time-zone-on-fedora-from-the-shell/">Continue reading <span class="meta-nav">&#8594;</span></a><a href="http://technology.mattrude.com/2009/08/setting-the-time-zone-on-fedora-from-the-shell/">Setting the Time Zone on Fedora from the shell</a> is a post from; <a href="http://technology.mattrude.com/">Matt&#039;s Technology Blog</a> which is not allowed to be copied on other sites.]]></description>
			<content:encoded><![CDATA[<p>By default <a href="http://fedoraproject.org" target="_blank">Fedora</a> set&#8217;s the timezone to UTC, during the install you may change this. But, if you move a server or forget to set the timezone during install.  You may change it after the fact.</p>
<p>Lately I  moved a system from the EST to CST (From Virginia to Minneapolis).  Since this was a webserver, there is no GUI installed (wasting memory).  So I connected to the system via SSH and ran the following command:</p>
<pre>cp /usr/share/zoneinfo/America/Chicago /etc/localtime</pre>
<p>All your really doing is copy the timezone info for Chicago, into the local systems clock.</p>
<p>To get a list of your time zone, on Fedora, go to your &#8220;/usr/share/zoneinfo&#8221; directory and list the contents.</p>
<pre>cd /usr/share/zoneinfo/
ls</pre>
<p>This will give you a list of all the top level regions, find yours and go into it.</p>
<pre>cd America</pre>
<p>Now find the city that&#8217;s closest to you and in your same timezone.</p>
<p>So if your in the Central time zone, copy the Chicago file into your &#8220;/etc/localtime&#8221; file</p>
<pre>cp Chicago /etc/localtime</pre>
<p>now check to make sure it all worked.</p>
<pre>$ date
Sun Aug 23 15:10:03 CDT 2009</pre>
<p>Since this system is  in Minneapolis, and Minneapolis is in the CST/CDT I&#8217;m good to go.</p>
<a href="http://technology.mattrude.com/2009/08/setting-the-time-zone-on-fedora-from-the-shell/">Setting the Time Zone on Fedora from the shell</a> is a post from; <a href="http://technology.mattrude.com/">Matt&#039;s Technology Blog</a> which is not allowed to be copied on other sites.]]></content:encoded>
			<wfw:commentRss>http://technology.mattrude.com/2009/08/setting-the-time-zone-on-fedora-from-the-shell/feed/</wfw:commentRss>
		<slash:comments>5</slash:comments>
		</item>
		<item>
		<title>Adding a native WordPress gallery</title>
		<link>http://technology.mattrude.com/2009/08/adding-a-native-wordpress-gallery/</link>
		<comments>http://technology.mattrude.com/2009/08/adding-a-native-wordpress-gallery/#comments</comments>
		<pubDate>Tue, 18 Aug 2009 01:16:32 +0000</pubDate>
		<dc:creator>Matt Rude</dc:creator>
				<category><![CDATA[How-To's]]></category>
		<category><![CDATA[Cascading Style Sheets]]></category>
		<category><![CDATA[Publishers]]></category>
		<category><![CDATA[Tools]]></category>
		<category><![CDATA[WordPress]]></category>

		<guid isPermaLink="false">http://www.mattrude.com/?p=585</guid>
		<description><![CDATA[I have heard a lot of talk lately of people complaining that they are unable to have image gallery&#8217;s in WordPress 2.8= without adding a plugin.  I assume this assumption comes from how hard it is to see what you &#8230; <a href="http://technology.mattrude.com/2009/08/adding-a-native-wordpress-gallery/">Continue reading <span class="meta-nav">&#8594;</span></a><a href="http://technology.mattrude.com/2009/08/adding-a-native-wordpress-gallery/">Adding a native WordPress gallery</a> is a post from; <a href="http://technology.mattrude.com/">Matt&#039;s Technology Blog</a> which is not allowed to be copied on other sites.]]></description>
			<content:encoded><![CDATA[<p>I have heard a lot of talk lately of people complaining that they are unable to have image gallery&#8217;s in WordPress 2.8= without adding a plugin.  I assume this assumption comes from how hard it is to see what you can do when it comes to the gallery functions built into WordPress.   If you look at my <a href="http://mattrude.com/category/gallery/" target="_blank">gallery page</a>, you will see a simple native WordPress gallery.  This gallery was built threw the theme but uses WordPress as it&#8217;s backend.</p>
<h3>So How do I build a native WordPress gallery?</h3>
<p>Well there&#8217;s two parts to accomplishing this successfully, but I&#8217;m only going to show you the first part in this post.  First you need to create a Category for all your gallery posts to be filed under. This Category may be named anything you would like it to be named.  I&#8217;m going to stick with the simple name of &#8216;Gallery&#8217;.  You will need some posts to be filed under it.  Create a new post as you normally would.  It is best to put some text to tell you readers what this gallery is all about, but that&#8217;s not needed.</p>
<p>Once you are ready to create your gallery, switch the editer from &#8216;Visual&#8217; mode to &#8216;HTML&#8217; mode (on the top right).  Once in &#8216;HTML&#8217; mode, enter:</p>
<pre>[ gallery ]</pre>
<p><em>note: there should be no space between the brackets and the word &#8216;gallery&#8217; (if I were to enter this line on my page, without the spaces, I would create a gallery).</em></p>
<p>Now switch back to the &#8216;Visual&#8217; mode and you should see a new yellow box in your post box with an image of a camera with a photograph behind it.  If you move your mouse over this new yellow box, two new icons will appear.  From this point, just upload photos to your site and save it.</p>
<p>After you have uploaded your images, save the post and check it out on your website.  Depending on your theme, you should see a nice full gallery on your page, or as I have, just a single thumbnail on your index page, but the full gallery on the posts page.</p>
<a href="http://technology.mattrude.com/2009/08/adding-a-native-wordpress-gallery/">Adding a native WordPress gallery</a> is a post from; <a href="http://technology.mattrude.com/">Matt&#039;s Technology Blog</a> which is not allowed to be copied on other sites.]]></content:encoded>
			<wfw:commentRss>http://technology.mattrude.com/2009/08/adding-a-native-wordpress-gallery/feed/</wfw:commentRss>
		<slash:comments>0</slash:comments>
		</item>
		<item>
		<title>Displaying one category on your WordPress main page</title>
		<link>http://technology.mattrude.com/2009/08/displaying-only-one-category-on-your-wordpress-main-page/</link>
		<comments>http://technology.mattrude.com/2009/08/displaying-only-one-category-on-your-wordpress-main-page/#comments</comments>
		<pubDate>Sat, 15 Aug 2009 01:33:20 +0000</pubDate>
		<dc:creator>Matt Rude</dc:creator>
				<category><![CDATA[How-To's]]></category>
		<category><![CDATA[Blog]]></category>
		<category><![CDATA[HTML]]></category>
		<category><![CDATA[Publishers]]></category>
		<category><![CDATA[Tools]]></category>
		<category><![CDATA[Uniform Resource Locator]]></category>
		<category><![CDATA[WordPress]]></category>
		<category><![CDATA[WordPress Plugin Directory]]></category>

		<guid isPermaLink="false">http://www.mattrude.com/?p=624</guid>
		<description><![CDATA[If you would like to only display a single category on your WordPress main page, here&#8217;s how you do it. You will need to start out by getting ID of the category you wish to display.   In WordPress 2.7+,  start &#8230; <a href="http://technology.mattrude.com/2009/08/displaying-only-one-category-on-your-wordpress-main-page/">Continue reading <span class="meta-nav">&#8594;</span></a><a href="http://technology.mattrude.com/2009/08/displaying-only-one-category-on-your-wordpress-main-page/">Displaying one category on your WordPress main page</a> is a post from; <a href="http://technology.mattrude.com/">Matt&#039;s Technology Blog</a> which is not allowed to be copied on other sites.]]></description>
			<content:encoded><![CDATA[<p>If you would like to only display a single category on your WordPress main page, here&#8217;s how you do it.  You will need to start out by getting ID of the category you wish to display.   In WordPress 2.7+,  start out by going to your categories tab under posts(1), then hover over the category you would like to display in your post(2), don&#8217;t click on it, just hover over it.  On the bottom of your screen, you will be shown then URL of the category your hover over(3), remember the ID number that being displayed.   In the below example the number we need to remember is &#8220;23&#8243;.</p>
<p style="text-align: left"><a href="http://tech.mattrude.com/wp-content/uploads/2009/08/Getting-Category-id.jpg"><img class="aligncenter size-full wp-image-629" src="http://tech.mattrude.com/wp-content/uploads/2009/08/Getting-Category-id.jpg" alt="Getting Category id" width="499" height="227" /></a></p>
<p style="text-align: left">After you have gotten your categories ID number, you will next need to change your index.php file.  In your index.php file look for the line with &#8220;have_post&#8221; and add the below code after.</p>
<p style="text-align: left">
<p style="text-align: left">
<p style="text-align: left">
<pre>&lt;?php if (have_posts()) : ?&gt;; Look for this line and add below
&lt;?php query_posts('showposts=10&amp;amp;;cat=23'); ?&gt;;
&lt;?php while (have_posts()) : the_post(); ?&gt;;
</pre>
<p>Last, change &#8220;cat&#8221; to the category id from above. &#8220;showposts&#8221; is the number of posts to display on the page.</p>
<a href="http://technology.mattrude.com/2009/08/displaying-only-one-category-on-your-wordpress-main-page/">Displaying one category on your WordPress main page</a> is a post from; <a href="http://technology.mattrude.com/">Matt&#039;s Technology Blog</a> which is not allowed to be copied on other sites.]]></content:encoded>
			<wfw:commentRss>http://technology.mattrude.com/2009/08/displaying-only-one-category-on-your-wordpress-main-page/feed/</wfw:commentRss>
		<slash:comments>4</slash:comments>
		</item>
		<item>
		<title>Playing with oEmbed</title>
		<link>http://technology.mattrude.com/2009/08/playing-with-oembed/</link>
		<comments>http://technology.mattrude.com/2009/08/playing-with-oembed/#comments</comments>
		<pubDate>Mon, 03 Aug 2009 19:53:23 +0000</pubDate>
		<dc:creator>Matt Rude</dc:creator>
				<category><![CDATA[How-To's]]></category>
		<category><![CDATA[Application programming interface]]></category>
		<category><![CDATA[Cut copy and paste]]></category>
		<category><![CDATA[HTML editor]]></category>
		<category><![CDATA[OEmbed]]></category>
		<category><![CDATA[WordPress]]></category>
		<category><![CDATA[WordPress.com]]></category>

		<guid isPermaLink="false">http://mattrude.com/?p=1458</guid>
		<description><![CDATA[As some of you know, WordPress 2.9 will have oEmbed as one of it&#8217;s core features.  With oEmbed, you are able to add any oEmbed link to a WordPress post by just adding the URL on it&#8217;s own line in &#8230; <a href="http://technology.mattrude.com/2009/08/playing-with-oembed/">Continue reading <span class="meta-nav">&#8594;</span></a><a href="http://technology.mattrude.com/2009/08/playing-with-oembed/">Playing with oEmbed</a> is a post from; <a href="http://technology.mattrude.com/">Matt&#039;s Technology Blog</a> which is not allowed to be copied on other sites.]]></description>
			<content:encoded><![CDATA[<p>As some of you know, WordPress 2.9 will have <a href="http://oembed.com/" target="_blank">oEmbed</a> as one of it&#8217;s core features.  With oEmbed, you are able to add any oEmbed link to a WordPress post by just adding the URL on it&#8217;s own line in your post.  So the below example was added by adding:</p>
<pre>http://vimeo.com/7058755</pre>
<p>When the above link is on it&#8217;s own line you will not see the URL, but you will see the movie. <em>(Note: the above link was added by adding the &lt;pre&gt; tags around the link.)</em></p>
<p><iframe src="http://player.vimeo.com/video/7058755" width="620" height="349" frameborder="0"></iframe></p>
<p>And there you have it, a nicely embedded movie directly in your post.</p>
<a href="http://technology.mattrude.com/2009/08/playing-with-oembed/">Playing with oEmbed</a> is a post from; <a href="http://technology.mattrude.com/">Matt&#039;s Technology Blog</a> which is not allowed to be copied on other sites.]]></content:encoded>
			<wfw:commentRss>http://technology.mattrude.com/2009/08/playing-with-oembed/feed/</wfw:commentRss>
		<slash:comments>0</slash:comments>
		</item>
		<item>
		<title>Importing and Syncing a Subversion Repository with Git</title>
		<link>http://technology.mattrude.com/2009/08/importing-and-syncing-a-subversion-repository-with-git/</link>
		<comments>http://technology.mattrude.com/2009/08/importing-and-syncing-a-subversion-repository-with-git/#comments</comments>
		<pubDate>Sat, 01 Aug 2009 22:20:19 +0000</pubDate>
		<dc:creator>Matt Rude</dc:creator>
				<category><![CDATA[How-To's]]></category>
		<category><![CDATA[Apache Subversion]]></category>
		<category><![CDATA[Git]]></category>
		<category><![CDATA[GitHub]]></category>
		<category><![CDATA[repo]]></category>
		<category><![CDATA[Repository clone]]></category>
		<category><![CDATA[Servers]]></category>
		<category><![CDATA[Tools]]></category>

		<guid isPermaLink="false">http://www.mattrude.com/?p=543</guid>
		<description><![CDATA[Importing a Subversion repository is such a way that you may still sync the changes back in forth, is really just to simple. This how-to assumes you existing repository is running is SVN and you wish to switch it over &#8230; <a href="http://technology.mattrude.com/2009/08/importing-and-syncing-a-subversion-repository-with-git/">Continue reading <span class="meta-nav">&#8594;</span></a><a href="http://technology.mattrude.com/2009/08/importing-and-syncing-a-subversion-repository-with-git/">Importing and Syncing a Subversion Repository with Git</a> is a post from; <a href="http://technology.mattrude.com/">Matt&#039;s Technology Blog</a> which is not allowed to be copied on other sites.]]></description>
			<content:encoded><![CDATA[<p>Importing a Subversion repository is such a way that you may still sync the changes back in forth, is really just to simple.  This how-to assumes you existing repository is running is SVN and you wish to switch it over to git.</p>
<p>Similar to how you may create a new SVN directory from a remote repo with svn, by running a command similar too:</p>
<pre>svn checkout https://svn.example.com/svn/project_name</pre>
<p>You may run the following to command to download the same remote repository, but then create an git repository and import the data from the svn repo.</p>
<pre>git svn clone https://svn.example.com/svn/project_name</pre>
<p>This will create a new directory named project_name with all your svn history.</p>
<p>Git is vary fast, but when it&#8217;s slow, it&#8217;s slow. The above process can take quite a bit of time (wordpress.org&#8217;s current trunk will take hours) to complete on an older (more comments not slower) repository since it checks in each comment at a time. If you don&#8217;t need the all the history of the project but just need a way to keep your self up to date as you code, you may just download the current revision tag.  So to  download SVN version 1234 and clone it into git, run:</p>
<pre>git svn clone -r 1234 https://svn.example.com/svn/project_name</pre>
<p>If you would like some of the history you can get that also, so if you would like say the last 234 commits run:</p>
<pre>git svn clone -r 1000:1234 https://svn.example.com/svn/project_name</pre>
<p>Then, to update your git repo once the SVN repository has been committed to, run</p>
<pre>git svn fetch</pre>
<p>That should ouput something like:</p>
<pre>r1235 = 340621340d856d805714e9bd86fdb11777f710fe (git-svn)
 M    includes/deprecated.php
 M    includes/functions.php</pre>
<p>You may now follow the <a href="http://technology.mattrude.com/2009/07/creating-a-secure-git-repository-server/">Creating a secure git repository</a> how-to and create a remote server.</p>
<a href="http://technology.mattrude.com/2009/08/importing-and-syncing-a-subversion-repository-with-git/">Importing and Syncing a Subversion Repository with Git</a> is a post from; <a href="http://technology.mattrude.com/">Matt&#039;s Technology Blog</a> which is not allowed to be copied on other sites.]]></content:encoded>
			<wfw:commentRss>http://technology.mattrude.com/2009/08/importing-and-syncing-a-subversion-repository-with-git/feed/</wfw:commentRss>
		<slash:comments>1</slash:comments>
		</item>
		<item>
		<title>SSH with no password</title>
		<link>http://technology.mattrude.com/2009/07/ssh-with-no-password/</link>
		<comments>http://technology.mattrude.com/2009/07/ssh-with-no-password/#comments</comments>
		<pubDate>Tue, 28 Jul 2009 04:04:15 +0000</pubDate>
		<dc:creator>Matt Rude</dc:creator>
				<category><![CDATA[How-To's]]></category>
		<category><![CDATA[Clients]]></category>
		<category><![CDATA[Git]]></category>
		<category><![CDATA[IP address]]></category>
		<category><![CDATA[Protocols]]></category>
		<category><![CDATA[Public-key cryptography]]></category>
		<category><![CDATA[Secure Shell]]></category>
		<category><![CDATA[Server]]></category>
		<category><![CDATA[SSH]]></category>

		<guid isPermaLink="false">http://www.mattrude.com/?p=533</guid>
		<description><![CDATA[When working with different Linux/Unix servers, or when working with a Secure GIT repo, life is much easier after you have setup an SSH public &#38; private keys.  Setting up a public &#38; private key is really pretty simple. Start &#8230; <a href="http://technology.mattrude.com/2009/07/ssh-with-no-password/">Continue reading <span class="meta-nav">&#8594;</span></a><a href="http://technology.mattrude.com/2009/07/ssh-with-no-password/">SSH with no password</a> is a post from; <a href="http://technology.mattrude.com/">Matt&#039;s Technology Blog</a> which is not allowed to be copied on other sites.]]></description>
			<content:encoded><![CDATA[<p>When working with different Linux/Unix servers, or when working with a <a href="http://technology.mattrude.com/2009/07/creating-a-secure-git-repository-server/">Secure GIT repo</a>, life is much easier after you have setup an SSH public &amp; private keys.  Setting up a public &amp; private key is really pretty simple.</p>
<p>Start out by create a public &amp; private key.</p>
<pre>ssh-keygen -t dsa</pre>
<p>You will now be prompted for a location and a few other options, the best anwser is the default, so just enter threw these.  You will also be asked to create a password, creating a password at this step will require you to enter the password every time you wish to use the key, so best bet is to just enter threw those questions also.  After you have created your new key, go into your &#8220;.ssh&#8221; folder (note the . before ssh) and copy your public key to remote servers.</p>
<pre>cd .ssh</pre>
<p>Next we want to rename the public key so we wont confuse it after sending it to the world.</p>
<pre>cp id_dsa.pub matt_dsa.pub</pre>
<p>Wonderful, now all we need to do is copy the public key to a remote server</p>
<pre>scp matt_dsa.pub remote_server.example.com:~/.ssh</pre>
<p>Note, the above example copies the public into the remote server&#8217;s .ssh folder, if the server dose not have a .ssh folder, you may need to create it.  After the public key has been copied, we need to put it into the &#8220;authorized_keys&#8221; file.</p>
<pre>cat matt_dsa.pub &amp;amp;gt;&amp;amp;gt; authorized_keys</pre>
<p>and that&#8217;s it, just exit out of your remote server, and try to connect again, it should not ask you for a password, but just now connect.  If you are using this your git account, just copy this key into the git&#8217;s users authorized_keys file.</p>
<a href="http://technology.mattrude.com/2009/07/ssh-with-no-password/">SSH with no password</a> is a post from; <a href="http://technology.mattrude.com/">Matt&#039;s Technology Blog</a> which is not allowed to be copied on other sites.]]></content:encoded>
			<wfw:commentRss>http://technology.mattrude.com/2009/07/ssh-with-no-password/feed/</wfw:commentRss>
		<slash:comments>5</slash:comments>
		</item>
		<item>
		<title>Creating a secure Git repository server</title>
		<link>http://technology.mattrude.com/2009/07/creating-a-secure-git-repository-server/</link>
		<comments>http://technology.mattrude.com/2009/07/creating-a-secure-git-repository-server/#comments</comments>
		<pubDate>Wed, 22 Jul 2009 01:40:32 +0000</pubDate>
		<dc:creator>Matt Rude</dc:creator>
				<category><![CDATA[How-To's]]></category>
		<category><![CDATA[Configuration file]]></category>
		<category><![CDATA[Configuration Management]]></category>
		<category><![CDATA[Git]]></category>
		<category><![CDATA[GitHub]]></category>
		<category><![CDATA[README]]></category>
		<category><![CDATA[repo]]></category>
		<category><![CDATA[Repository clone]]></category>
		<category><![CDATA[Secure Shell]]></category>
		<category><![CDATA[Security]]></category>
		<category><![CDATA[Servers]]></category>
		<category><![CDATA[Tools]]></category>
		<category><![CDATA[User (computing)]]></category>

		<guid isPermaLink="false">http://www.mattrude.com/?p=462</guid>
		<description><![CDATA[Creating a secure git repository server is a pretty simple process.  Basically we will be using SSH to transmit the data over an encrypted channel.  SSH will handle all the authentication and data encryption.  So the first set is creating &#8230; <a href="http://technology.mattrude.com/2009/07/creating-a-secure-git-repository-server/">Continue reading <span class="meta-nav">&#8594;</span></a><a href="http://technology.mattrude.com/2009/07/creating-a-secure-git-repository-server/">Creating a secure Git repository server</a> is a post from; <a href="http://technology.mattrude.com/">Matt&#039;s Technology Blog</a> which is not allowed to be copied on other sites.]]></description>
			<content:encoded><![CDATA[<p>Creating a secure git repository server is a pretty simple process.  Basically we will be using SSH to transmit the data over an encrypted channel.  SSH will handle all the authentication and data encryption.  So the first set is creating a user for git to use and creating the git users ssh key.</p>
<p>On your server, from a privileged account, create a user (were going to use git).</p>
<pre>adduser git
passwd git</pre>
<p>The configuration we will be setting up will store the actual repositories in the git users home directory.  If you don&#8217;t like it&#8217;s current location, you may modify the /etc/passwd file for your user.</p>
<p>Once we have the user setup, in it&#8217;s home directory we need to create our first repository.  Start out by creating the folder, then well go into it and create the git repository files.</p>
<pre>mkdir new-project.git
cd new-project.git
git init --bare</pre>
<p>With the repository now setup go back to your desktop/laptop system (linux/unix).</p>
<p>From your desktop system, create a empty repository or go  to an existing git repo.  If you are going to be adding an existing repo, it may not be connected to any other remote repository.  if you clone it from a remote source (a directory on the same system counts as a remote source) you will need to modify the repository&#8217;s config file and remove those entry&#8217;s, look in the config file under the .git (note the &#8216;dot&#8217;) directory.</p>
<p>To create an empty repository, create a directory for the repository, go into it and init the repo.</p>
<pre>mkdir new-project.git
cd new-project.git
git init</pre>
<p>Since you need something in your repo, and git likes having a readme file (or gitweb dose) let&#8217;s create a readme file and commit it.</p>
<pre>touch README
git add README
git commit -m 'Added README file, first commit'</pre>
<p>Now that we have a commit in our repo, we can add the newly created git repo server and push our new repo to it.</p>
<p>We will start by adding the server to the repo&#8217;s configuration.</p>
<pre>git remote add origin git@new-git-server.example.com:new-project.git</pre>
<p>The above example assumes you&#8217;re server&#8217;s name is &#8220;new-git-server.example.com&#8221; and your using a project named &#8220;new-project.git&#8221; for the user &#8220;git&#8221;.  But it also assumes that your repo is directly in the user git&#8217;s home directory. If you store your repo&#8217;s in a different directory, you will need to add the list folders after the colon.</p>
<p>After you have successfully added the server, push your new repository to the server.</p>
<pre>git push origin master</pre>
<p>You may now be asked for the git user&#8217;s password, enter it, and your repository should be transferred.</p>
<p>Also check out how to <a href="http://technology.mattrude.com/2009/07/ssh-with-no-password/">setup a ssh public/private key</a> where no password is required, only the private key on your client system.</p>
<p>The above may look like a lot, but it&#8217;s really pretty simple to setup.  If you have any problems or questions abut this How-To, please leave a comment or <a href="http://mattrude.com/contact-me/" target="_blank">contact me</a>.</p>
<a href="http://technology.mattrude.com/2009/07/creating-a-secure-git-repository-server/">Creating a secure Git repository server</a> is a post from; <a href="http://technology.mattrude.com/">Matt&#039;s Technology Blog</a> which is not allowed to be copied on other sites.]]></content:encoded>
			<wfw:commentRss>http://technology.mattrude.com/2009/07/creating-a-secure-git-repository-server/feed/</wfw:commentRss>
		<slash:comments>10</slash:comments>
		</item>
		<item>
		<title>wp-Gallery2 Image Block post</title>
		<link>http://technology.mattrude.com/2009/07/wp-gallery2-image-block/</link>
		<comments>http://technology.mattrude.com/2009/07/wp-gallery2-image-block/#comments</comments>
		<pubDate>Mon, 13 Jul 2009 16:13:07 +0000</pubDate>
		<dc:creator>Matt Rude</dc:creator>
				<category><![CDATA[General]]></category>
		<category><![CDATA[Plug-Ins]]></category>
		<category><![CDATA[Plugin]]></category>
		<category><![CDATA[Publishers]]></category>
		<category><![CDATA[Tools]]></category>
		<category><![CDATA[WordPress]]></category>
		<category><![CDATA[ZIP (file format)]]></category>

		<guid isPermaLink="false">http://www.mattrude.com/?p=388</guid>
		<description><![CDATA[The wp-Gallery2 Image Block plugin will allow you to put one of the many Gallery2 Image Blocks on your WordPress site.  You are required to have a running Gallery2 install to use this plugin. This is a complete rewrite of &#8230; <a href="http://technology.mattrude.com/2009/07/wp-gallery2-image-block/">Continue reading <span class="meta-nav">&#8594;</span></a><a href="http://technology.mattrude.com/2009/07/wp-gallery2-image-block/">wp-Gallery2 Image Block post</a> is a post from; <a href="http://technology.mattrude.com/">Matt&#039;s Technology Blog</a> which is not allowed to be copied on other sites.]]></description>
			<content:encoded><![CDATA[<p>The <strong>wp-Gallery2 Image Block </strong>plugin will allow you to put one of the many Gallery2 Image Blocks on your WordPress site.  You are required to have a running <a href="http://gallery.menalto.com/">Gallery2</a> install to use this plugin.</p>
<p>This is a complete rewrite of <a href="http://www.theschierers.net/blog/">Chris Schierer (aka Lentil)</a> Gallery2 Image Block Plugin 0.1.4.  This rewrite uses the new WordPress 2.8 Widget API, so is only compatible with WordPress 2.8+.</p>
<p>All options described in the <a href="http://codex.gallery2.org/Gallery2:Modules:imageblock">Gallery 2 Image Block</a> documentation are included.</p>
<p>User configuration of Image Block options is available through the Widget configuration panel.  Blank (empty) options use the Gallery2 defaults.</p>
<p><strong>Note:</strong> The widget is written using <a href="http://us3.php.net/curl">lib_curl()</a> to avoid url_fopen issues.</p>
<h3>Download</h3>
<ul>
<li>wp-gallery2-image-block &#8211; Version 0.4 (2009-July-16)</li>
<li>wp-gallery2-image-block &#8211; Version 0.3 (2009-July-15)</li>
<li>wp-gallery2-image-block &#8211; Version 0.1 (2009-July-12)</li>
</ul>
<h3>Screen Shots</h3>

<h3>Installation</h3>
<p>Extract the zip file and copy the folder wp=gallery2-image-block into your wp-content/plugins/ directory of your WordPress installation and then activate the Plugin from Plugins page.</p>
<a href="http://technology.mattrude.com/2009/07/wp-gallery2-image-block/">wp-Gallery2 Image Block post</a> is a post from; <a href="http://technology.mattrude.com/">Matt&#039;s Technology Blog</a> which is not allowed to be copied on other sites.]]></content:encoded>
			<wfw:commentRss>http://technology.mattrude.com/2009/07/wp-gallery2-image-block/feed/</wfw:commentRss>
		<slash:comments>6</slash:comments>
		</item>
		<item>
		<title>RoundCube Fail2Ban Plugin</title>
		<link>http://technology.mattrude.com/2009/07/roundcube-fail2ban-plugin/</link>
		<comments>http://technology.mattrude.com/2009/07/roundcube-fail2ban-plugin/#comments</comments>
		<pubDate>Thu, 09 Jul 2009 06:20:48 +0000</pubDate>
		<dc:creator>Matt Rude</dc:creator>
				<category><![CDATA[General]]></category>
		<category><![CDATA[Git]]></category>
		<category><![CDATA[Internet Protocol]]></category>
		<category><![CDATA[Plug-Ins]]></category>
		<category><![CDATA[Plugin]]></category>
		<category><![CDATA[Tools]]></category>
		<category><![CDATA[WordPress]]></category>

		<guid isPermaLink="false">http://www.mattrude.com/?p=370</guid>
		<description><![CDATA[RoundCube Fail2Ban Plugin is a small plugin that will display a failed login attempts to your syslog or userlogins log file. Using this information Fail2Ban be able to block a user for a set amount of time. The best part, &#8230; <a href="http://technology.mattrude.com/2009/07/roundcube-fail2ban-plugin/">Continue reading <span class="meta-nav">&#8594;</span></a><a href="http://technology.mattrude.com/2009/07/roundcube-fail2ban-plugin/">RoundCube Fail2Ban Plugin</a> is a post from; <a href="http://technology.mattrude.com/">Matt&#039;s Technology Blog</a> which is not allowed to be copied on other sites.]]></description>
			<content:encoded><![CDATA[<p><strong>RoundCube Fail2Ban Plugin</strong> is a small plugin that will display a failed login attempts to your syslog or userlogins log file. Using this information <a href="http://www.fail2ban.org/wiki/index.php/Main_Page" target="_blank">Fail2Ban</a> be able to block a user for a set amount of time.  The best part, the block is happing at the IP level and blocks the IP address, not the user they are try to log in as.</p>
<h2>Download</h2>
<ul>
<li>tgz | zip | <a href="https://github.com/mattrude/rc-plugin-fail2ban">git</a> &#8211; Version: 1.0 (2009-Jul-09)</li>
</ul>
<h2>Install</h2>
<ul>
<li>Place this plugin folder into the RoundCube plugins directory (roundcube/plugins/)</li>
<li>Add fail2ban to $rcmail_config['plugins'] in your RoundCube config</li>
</ul>
<p><em><strong>Note:</strong> When downloading this plugin from <a href="https://github.com/mattrude/rc-plugin-fail2ban" target="_blank">http://github.com/mattrude/rc-plugin-fail2ban</a> you will need to create a directory called fail2ban and place fail2ban.php in there, ignoring the root directory in the downloaded archive.  You may also run &#8216;git clone git://github.com/mattrude/rc-plugin-fail2ban.git fail2ban&#8217; from the plugins directory.</em></p>
<h2>Fail2Ban Setup</h2>
<p><strong>fail2ban/jail.conf:</strong></p>
<pre>[roundcube]
enabled  = true
port     = http,https
filter   = roundcube
action   = iptables-multiport[name=roundcube, port=&amp;amp;amp;quot;http,https&amp;amp;amp;quot;]
logpath  = /var/www/html/roundcube/logs/userlogins</pre>
<p><strong>fail2ban/filter.d/roundcube.conf:</strong></p>
<pre>[Definition]
failregex = FAILED login for .*. from &lt;HOST&gt;
ignoreregex =</pre>
<a href="http://technology.mattrude.com/2009/07/roundcube-fail2ban-plugin/">RoundCube Fail2Ban Plugin</a> is a post from; <a href="http://technology.mattrude.com/">Matt&#039;s Technology Blog</a> which is not allowed to be copied on other sites.]]></content:encoded>
			<wfw:commentRss>http://technology.mattrude.com/2009/07/roundcube-fail2ban-plugin/feed/</wfw:commentRss>
		<slash:comments>0</slash:comments>
		</item>
		<item>
		<title>WordPress Themes – Random Image Header</title>
		<link>http://technology.mattrude.com/2009/07/wordpress-themes-random-image-header/</link>
		<comments>http://technology.mattrude.com/2009/07/wordpress-themes-random-image-header/#comments</comments>
		<pubDate>Tue, 07 Jul 2009 01:05:21 +0000</pubDate>
		<dc:creator>Matt Rude</dc:creator>
				<category><![CDATA[How-To's]]></category>
		<category><![CDATA[Languages]]></category>
		<category><![CDATA[List of HTTP header fields]]></category>
		<category><![CDATA[Matt Mullenweg]]></category>
		<category><![CDATA[Programming]]></category>
		<category><![CDATA[WordPress]]></category>

		<guid isPermaLink="false">http://www.mattrude.com/?p=318</guid>
		<description><![CDATA[While working on a theme for WordPress lately.I ran across the problem of wanting a random header image on the top of the page, but how to do it?  After looking around for a simple, fast script, I ran across, &#8230; <a href="http://technology.mattrude.com/2009/07/wordpress-themes-random-image-header/">Continue reading <span class="meta-nav">&#8594;</span></a><a href="http://technology.mattrude.com/2009/07/wordpress-themes-random-image-header/">WordPress Themes – Random Image Header</a> is a post from; <a href="http://technology.mattrude.com/">Matt&#039;s Technology Blog</a> which is not allowed to be copied on other sites.]]></description>
			<content:encoded><![CDATA[<p>While working on a theme for WordPress lately.I ran across the problem of wanting a random header image on the top of the page, but how to do it?  After looking around for a simple, fast script, I ran across, who else, but Matt Mullenweg&#8217;s page.</p>
<p>Matt wrote a small, fast script that will look at the content of a directory, then randomly returns the a image&#8217;s URI.</p>
<p>In Matt&#8217;s own words:</p>
<blockquote><p>This is your standard random image script that takes a slightly different approach than most, namely using standard HTTP headers instead of reading the file through the script.</p></blockquote>
<p>So to integrate this script into your page, all you need to do is change the images name to random.php, see below.</p>
<pre>&lt;img title="&lt;?php bloginfo('name'); ?&gt; Random Header Image" src="&lt;?php bloginfo('template_url'); ?&gt;/header1.jpg" alt=""/&gt;</pre>
<p>Change too:</p>
<pre>&lt;img title="&lt;?php bloginfo('name'); ?&gt; Random Header Image" src="&lt;?php bloginfo('template_url'); ?&gt;/rotate.php" alt=""&gt;</pre>
<p>Matt Mullenweg&#8217;s script may be found at: <a href="http://ma.tt/scripts/randomimage/">http://ma.tt/scripts/randomimage</a></p>
<div style="overflow: hidden;width: 1px;height: 1px">This is your standard random image script that takes a slightly different approach than most, namely using standard HTTP headers instead of reading the file through the script.</div>
<a href="http://technology.mattrude.com/2009/07/wordpress-themes-random-image-header/">WordPress Themes – Random Image Header</a> is a post from; <a href="http://technology.mattrude.com/">Matt&#039;s Technology Blog</a> which is not allowed to be copied on other sites.]]></content:encoded>
			<wfw:commentRss>http://technology.mattrude.com/2009/07/wordpress-themes-random-image-header/feed/</wfw:commentRss>
		<slash:comments>0</slash:comments>
		</item>
		<item>
		<title>Creating Self-signed SSL Certificates for Dovecot &amp; Postfix</title>
		<link>http://technology.mattrude.com/2009/06/creating-self-signed-ssl-certificates-for-dovecot-postfix/</link>
		<comments>http://technology.mattrude.com/2009/06/creating-self-signed-ssl-certificates-for-dovecot-postfix/#comments</comments>
		<pubDate>Mon, 29 Jun 2009 14:42:39 +0000</pubDate>
		<dc:creator>Matt Rude</dc:creator>
				<category><![CDATA[How-To's]]></category>
		<category><![CDATA[Certificate authority]]></category>
		<category><![CDATA[Example.com]]></category>
		<category><![CDATA[OpenSSL]]></category>
		<category><![CDATA[Public key certificate]]></category>
		<category><![CDATA[Public key infrastructure]]></category>
		<category><![CDATA[Server (computing)]]></category>
		<category><![CDATA[Transport Layer Security]]></category>

		<guid isPermaLink="false">http://www.mattrude.com/?p=262</guid>
		<description><![CDATA[Self-signed SSL certificates are the easiest way to get your SSL server working. However unless you take some action to prevent it, this is at the cost of security: The first time the client connects to the server, it sees &#8230; <a href="http://technology.mattrude.com/2009/06/creating-self-signed-ssl-certificates-for-dovecot-postfix/">Continue reading <span class="meta-nav">&#8594;</span></a><a href="http://technology.mattrude.com/2009/06/creating-self-signed-ssl-certificates-for-dovecot-postfix/">Creating Self-signed SSL Certificates for Dovecot &amp; Postfix</a> is a post from; <a href="http://technology.mattrude.com/">Matt&#039;s Technology Blog</a> which is not allowed to be copied on other sites.]]></description>
			<content:encoded><![CDATA[<p>Self-signed <a title="Openssl" href="http://wiki.mattrude.com/Openssl">SSL</a> certificates are the easiest way to get your SSL server working. However unless you take some action to prevent it, this is at the cost of security:</p>
<ul>
<li> The first time the client connects to the server, it sees the certificate and asks the user whether to trust it. The user of course doesn&#8217;t really bother verifying the certificate&#8217;s fingerprint, so a man-in-the-middle attack can easily bypass all the SSL security, steal the user&#8217;s password and so on.</li>
<li> If the client was lucky enough not to get attacked the first time it connected, the following connections will be secure as long as the client had permanently saved the certificate. Some clients do this, while others have to be manually configured to accept the certificate.</li>
</ul>
<p>The only way to be fully secure is to import the SSL certificate to client&#8217;s (or operating system&#8217;s) list of trusted CA certificates prior to first connection. See <a title="http://wiki.dovecot.org/SSL/CertificateClientImporting" rel="nofollow" href="http://wiki.dovecot.org/SSL/CertificateClientImporting">SSL/CertificateClientImporting</a> how to do it for different clients.</p>
<h4>Building Dovcot&#8217;s Self-Signed Certificates</h4>
<p>Dovecot includes a script to build self-signed SSL certificates using OpenSSL. First you need to find the <strong>dovecot-openssl.cnf</strong> file.</p>
<ul>
<li><strong>Configuring the Certificate Config File</strong></li>
</ul>
<p>The best way on <a title="Fedora" href="http://wiki.mattrude.com/Fedora">Fedora</a> to do this is via the <strong>locate</strong> command.</p>
<pre>locate dovecot-openssl.cnf</pre>
<p>Mine was located at <strong>/etc/pki/dovecot/dovecot-openssl.cnf</strong>. Now that you have found the file you need to add your server information to it, like this:</p>
<pre>[ req ]
default_bits = 1024
encrypt_key = yes
distinguished_name = req_dn
x509_extensions = cert_type
prompt = no

[ req_dn ]
# country (2 letter code)
C=US

# State or Province Name (full name)
ST=MN

# Locality Name (eg. city)
L=SaintPaul

# Organization (eg. company)
O=example.com

# Organizational Unit Name (eg. section)
OU=IMAP server

# Common Name (*.example.com is also possible)
CN=*.example.com

# E-mail contact
emailAddress=postmaster@example.com

[ cert_type ]
nsCertType = server</pre>
<ul>
<li><strong>Build the Certificates</strong></li>
</ul>
<pre>/usr/libexec/dovecot/mkcert.sh</pre>
<ul>
<li><strong>Modifying Dovecot</strong></li>
</ul>
<p>You will need to add the following to your <strong>/etc/dovecot.conf</strong> file:</p>
<pre>ssl_listen = 993
ssl_disable = no
ssl_cert_file = /etc/postfix/smtpd.pem
ssl_key_file = /etc/postfix/smtpd.pem
auth_cache_size = 128</pre>
<p>Then restart Dovecot</p>
<pre>/sbin/service dovecot restart</pre>
<div style="overflow: hidden;width: 1px;height: 1px">
<pre>gutter='0'</pre>
</div>
<a href="http://technology.mattrude.com/2009/06/creating-self-signed-ssl-certificates-for-dovecot-postfix/">Creating Self-signed SSL Certificates for Dovecot &amp; Postfix</a> is a post from; <a href="http://technology.mattrude.com/">Matt&#039;s Technology Blog</a> which is not allowed to be copied on other sites.]]></content:encoded>
			<wfw:commentRss>http://technology.mattrude.com/2009/06/creating-self-signed-ssl-certificates-for-dovecot-postfix/feed/</wfw:commentRss>
		<slash:comments>0</slash:comments>
		</item>
		<item>
		<title>Tuning the number of processes on MacOS X</title>
		<link>http://technology.mattrude.com/2009/06/tuning-the-number-of-processes-on-macos-x/</link>
		<comments>http://technology.mattrude.com/2009/06/tuning-the-number-of-processes-on-macos-x/#comments</comments>
		<pubDate>Tue, 09 Jun 2009 12:57:52 +0000</pubDate>
		<dc:creator>Matt Rude</dc:creator>
				<category><![CDATA[How-To's]]></category>
		<category><![CDATA[Apple]]></category>
		<category><![CDATA[Mac OS]]></category>
		<category><![CDATA[Mac OS X]]></category>
		<category><![CDATA[Mac OS X Lion]]></category>
		<category><![CDATA[Net Applications]]></category>
		<category><![CDATA[Operating system]]></category>

		<guid isPermaLink="false">http://www.mattrude.com/?p=231</guid>
		<description><![CDATA[MacOS X will run out of process slots when you increase Postfix process limits. The following works with OSX 10.4 and OSX 10.5. MacOS X kernel parameters can be specified in /etc/sysctl.conf. /etc/sysctl.conf: kern.maxproc=2048kern.maxprocperuid=2048 Unfortunately these can&#8217;t simply be set &#8230; <a href="http://technology.mattrude.com/2009/06/tuning-the-number-of-processes-on-macos-x/">Continue reading <span class="meta-nav">&#8594;</span></a><a href="http://technology.mattrude.com/2009/06/tuning-the-number-of-processes-on-macos-x/">Tuning the number of processes on MacOS X</a> is a post from; <a href="http://technology.mattrude.com/">Matt&#039;s Technology Blog</a> which is not allowed to be copied on other sites.]]></description>
			<content:encoded><![CDATA[<p>MacOS X will run out of process slots when you increase Postfix process limits. The following works with OSX 10.4 and OSX 10.5. MacOS X kernel parameters can be specified in /etc/sysctl.conf.<br />
<strong></strong></p>
<p><strong>/etc/sysctl.conf:</strong></p>
<pre>kern.maxproc=2048kern.maxprocperuid=2048</pre>
<p>Unfortunately these can&#8217;t simply be set on the fly with <strong>sysctl -w</strong>. You also have to set the following in <strong>/etc/launchd.conf</strong> so that the root user after boot will have the right process limit (2048). Otherwise you have to always run <strong>ulimit -u 2048</strong> as root, then start a user shell, and then start processes for things to take effect.</p>
<p><strong>/etc/launchd.conf:</strong></p>
<pre>limit maxproc 2048</pre>
<p>Once these are in place, reboot the system. After that, the<br />
limits will stay in place.</p>
<a href="http://technology.mattrude.com/2009/06/tuning-the-number-of-processes-on-macos-x/">Tuning the number of processes on MacOS X</a> is a post from; <a href="http://technology.mattrude.com/">Matt&#039;s Technology Blog</a> which is not allowed to be copied on other sites.]]></content:encoded>
			<wfw:commentRss>http://technology.mattrude.com/2009/06/tuning-the-number-of-processes-on-macos-x/feed/</wfw:commentRss>
		<slash:comments>0</slash:comments>
		</item>
		<item>
		<title>Postfix: Archiving Mail when sent from or to the outside world</title>
		<link>http://technology.mattrude.com/2009/05/postfix-archiving-mail-when-sent-from-or-to-the-outside-world/</link>
		<comments>http://technology.mattrude.com/2009/05/postfix-archiving-mail-when-sent-from-or-to-the-outside-world/#comments</comments>
		<pubDate>Sat, 30 May 2009 02:56:10 +0000</pubDate>
		<dc:creator>Matt Rude</dc:creator>
				<category><![CDATA[How-To's]]></category>
		<category><![CDATA[BCC]]></category>
		<category><![CDATA[Blind carbon copy]]></category>
		<category><![CDATA[email]]></category>
		<category><![CDATA[MySQL]]></category>
		<category><![CDATA[Postfix]]></category>
		<category><![CDATA[SpamAssassin]]></category>
		<category><![CDATA[SQL]]></category>

		<guid isPermaLink="false">http://www.mattrude.com/?p=221</guid>
		<description><![CDATA[The goal here is to send an BCC message for every email send to or from the outside world, for a group of internal addresses. Use sender_bcc_maps or recipient_bcc_maps. Configure them so that the archive copy is made when the &#8230; <a href="http://technology.mattrude.com/2009/05/postfix-archiving-mail-when-sent-from-or-to-the-outside-world/">Continue reading <span class="meta-nav">&#8594;</span></a><a href="http://technology.mattrude.com/2009/05/postfix-archiving-mail-when-sent-from-or-to-the-outside-world/">Postfix: Archiving Mail when sent from or to the outside world</a> is a post from; <a href="http://technology.mattrude.com/">Matt&#039;s Technology Blog</a> which is not allowed to be copied on other sites.]]></description>
			<content:encoded><![CDATA[<p>The goal here is to send an BCC message for every email send to or from the outside world, for a group of internal addresses.</p>
<p>Use <strong>sender_bcc_maps</strong> or <strong>recipient_bcc_maps</strong>. Configure them so that the archive copy is made when the sender is remote OR the receiver is remote.</p>
<p><strong>/etc/postfix/main.cf:</strong></p>
<pre>sender_bcc_maps = pcre:/etc/postfix/archive-check
recipient_bcc_maps = pcre:/etc/postfix/archive-check</pre>
<p><strong>/etc/postfix/archive-check:</strong></p>
<pre>!/@example.com$/        archive@example.com</pre>
<p>This is a predicate transformation, from (NOT (local AND local)), what you asked for, into ((NOT local) OR (NOT local)), shown above.</p>
<a href="http://technology.mattrude.com/2009/05/postfix-archiving-mail-when-sent-from-or-to-the-outside-world/">Postfix: Archiving Mail when sent from or to the outside world</a> is a post from; <a href="http://technology.mattrude.com/">Matt&#039;s Technology Blog</a> which is not allowed to be copied on other sites.]]></content:encoded>
			<wfw:commentRss>http://technology.mattrude.com/2009/05/postfix-archiving-mail-when-sent-from-or-to-the-outside-world/feed/</wfw:commentRss>
		<slash:comments>1</slash:comments>
		</item>
		<item>
		<title>Postfix: reject an address before queue</title>
		<link>http://technology.mattrude.com/2009/05/postfix-reject-an-address-before-queue/</link>
		<comments>http://technology.mattrude.com/2009/05/postfix-reject-an-address-before-queue/#comments</comments>
		<pubDate>Wed, 20 May 2009 13:58:28 +0000</pubDate>
		<dc:creator>Matt Rude</dc:creator>
				<category><![CDATA[How-To's]]></category>
		<category><![CDATA[Algorithm]]></category>
		<category><![CDATA[Mail]]></category>
		<category><![CDATA[Postfix]]></category>
		<category><![CDATA[Sendmail]]></category>
		<category><![CDATA[Servers]]></category>
		<category><![CDATA[SpamAssassin]]></category>
		<category><![CDATA[SQL]]></category>

		<guid isPermaLink="false">http://www.mattrude.com/?p=213</guid>
		<description><![CDATA[First start out by creating a file named /etc/postfix/rejected_addresses then add the following to it bad_sender@example.com REJECT This will be an hashed map table, so we need to create the hash postmap /etc/postfix/rejected_addresses Next we need to add the map &#8230; <a href="http://technology.mattrude.com/2009/05/postfix-reject-an-address-before-queue/">Continue reading <span class="meta-nav">&#8594;</span></a><a href="http://technology.mattrude.com/2009/05/postfix-reject-an-address-before-queue/">Postfix: reject an address before queue</a> is a post from; <a href="http://technology.mattrude.com/">Matt&#039;s Technology Blog</a> which is not allowed to be copied on other sites.]]></description>
			<content:encoded><![CDATA[<p>First start out by creating a file named <strong>/etc/postfix/rejected_addresses</strong> then  add the following to it</p>
<pre>bad_sender@example.com    REJECT</pre>
<p>This will be an hashed map table, so we need to create the hash</p>
<pre>postmap /etc/postfix/rejected_addresses</pre>
<p>Next we need to add the map to our <strong>/etc/postfix/main.cf</strong>file.  We will be adding this to the <strong>smtpd_recipient_restrictions</strong> section.</p>
<pre>smtpd_recipient_restrictions =
  ...
  check_sender_access hash:/etc/postfix/rejected_addresses,
  ...
  reject_unauth_destination</pre>
<p>Once complete reload postfix</p>
<pre>postfix reload</pre>
<a href="http://technology.mattrude.com/2009/05/postfix-reject-an-address-before-queue/">Postfix: reject an address before queue</a> is a post from; <a href="http://technology.mattrude.com/">Matt&#039;s Technology Blog</a> which is not allowed to be copied on other sites.]]></content:encoded>
			<wfw:commentRss>http://technology.mattrude.com/2009/05/postfix-reject-an-address-before-queue/feed/</wfw:commentRss>
		<slash:comments>0</slash:comments>
		</item>
		<item>
		<title>Restoring a Windows 2000 Profile</title>
		<link>http://technology.mattrude.com/2009/05/restoring-a-windows-2000-profile/</link>
		<comments>http://technology.mattrude.com/2009/05/restoring-a-windows-2000-profile/#comments</comments>
		<pubDate>Wed, 20 May 2009 13:57:57 +0000</pubDate>
		<dc:creator>Matt Rude</dc:creator>
				<category><![CDATA[How-To's]]></category>
		<category><![CDATA[Microsoft Windows]]></category>
		<category><![CDATA[User (computing)]]></category>
		<category><![CDATA[User profile]]></category>
		<category><![CDATA[Windows]]></category>
		<category><![CDATA[Windows 2000]]></category>
		<category><![CDATA[Windows Registry]]></category>

		<guid isPermaLink="false">http://www.mattrude.com/?p=211</guid>
		<description><![CDATA[If a user logs into a Windows 2000 system, and there profile is missing, the following will help you restore it. In the below how to, you will need to copy the bad profile to a new location, then tell &#8230; <a href="http://technology.mattrude.com/2009/05/restoring-a-windows-2000-profile/">Continue reading <span class="meta-nav">&#8594;</span></a><a href="http://technology.mattrude.com/2009/05/restoring-a-windows-2000-profile/">Restoring a Windows 2000 Profile</a> is a post from; <a href="http://technology.mattrude.com/">Matt&#039;s Technology Blog</a> which is not allowed to be copied on other sites.]]></description>
			<content:encoded><![CDATA[<p>If a user logs into a Windows 2000 system, and there profile is missing, the following will help you restore it.  In the below how to, you will need to copy the bad profile to a new location, then tell Windows to look there via the registry.</p>
<table class="prettytable" border="0">
<tbody>
<tr>
<td>1.</td>
<td>Log on to the computer with the user profile that you want to restore.</td>
</tr>
<tr>
<td>2.</td>
<td>Click <strong>Start</strong>, and then click <strong>Run</strong>.</td>
</tr>
<tr>
<td>3.</td>
<td>Type regedit, and then click <strong>OK</strong>.</td>
</tr>
<tr>
<td>4.</td>
<td>In Registry Editor, navigate to the following registry key:<strong>HKEY_LOCAL_MACHINESoftwareMicrosoftWindows NTCurrentVersionProfileList</strong></td>
</tr>
<tr>
<td>5.</td>
<td>Locate your user profile folder.<strong>NOTE</strong>: When you open the ProfileList folder, you see several folders, each of which belongs to a different user. These folders are named according to the user security IDs (SIDs) and not according to the user names.To locate your user profile folder, use one of the following options:</p>
<table class="prettytable" border="0">
<tbody>
<tr>
<td>•</td>
<td>For each folder, click the folder, and then look for the <strong>ProfileImagePath</strong> value that contains the path to your user profile (such as %SystemDrive%Documents and Settings<em>username</em>).-or-</td>
</tr>
<tr>
<td>•</td>
<td>In Registry Editor, press CTRL+F to start the Find tool. Type your user name in the <strong>Find what</strong> box, click to select the <strong>Data</strong> check box under <strong>Look at</strong>, and then click <strong>Find</strong>.</td>
</tr>
</tbody>
</table>
</td>
</tr>
<tr>
<td>6.</td>
<td>After you locate the subkey folder for your user profile, double-click the <strong>ProfileImagePath</strong> value.</td>
</tr>
<tr>
<td>7.</td>
<td>In the <strong>Value data</strong> box, change the path so that it points to the profile folder that you are restoring, and then and click <strong>OK</strong>.</td>
</tr>
<tr>
<td>8.</td>
<td>Quit Registry Editor.</td>
</tr>
</tbody>
</table>
<p>The next time that you log on to the computer, Windows will use your restored user profile.</p>
<a href="http://technology.mattrude.com/2009/05/restoring-a-windows-2000-profile/">Restoring a Windows 2000 Profile</a> is a post from; <a href="http://technology.mattrude.com/">Matt&#039;s Technology Blog</a> which is not allowed to be copied on other sites.]]></content:encoded>
			<wfw:commentRss>http://technology.mattrude.com/2009/05/restoring-a-windows-2000-profile/feed/</wfw:commentRss>
		<slash:comments>0</slash:comments>
		</item>
		<item>
		<title>Postfix: allow select users permission to send to a cretin address</title>
		<link>http://technology.mattrude.com/2009/05/postfix-allow-select-users-permission-to-send-to-a-cretin-address/</link>
		<comments>http://technology.mattrude.com/2009/05/postfix-allow-select-users-permission-to-send-to-a-cretin-address/#comments</comments>
		<pubDate>Wed, 20 May 2009 13:56:06 +0000</pubDate>
		<dc:creator>Matt Rude</dc:creator>
				<category><![CDATA[How-To's]]></category>
		<category><![CDATA[email]]></category>
		<category><![CDATA[Email address]]></category>
		<category><![CDATA[Example.com]]></category>
		<category><![CDATA[Postfix]]></category>
		<category><![CDATA[Servers]]></category>
		<category><![CDATA[SpamAssassin]]></category>

		<guid isPermaLink="false">http://www.mattrude.com/?p=209</guid>
		<description><![CDATA[So the idea here is to have an email address that you would only like a select few to have access to email to, for example, a everyone or all address. In this example we will be locking down the &#8230; <a href="http://technology.mattrude.com/2009/05/postfix-allow-select-users-permission-to-send-to-a-cretin-address/">Continue reading <span class="meta-nav">&#8594;</span></a><a href="http://technology.mattrude.com/2009/05/postfix-allow-select-users-permission-to-send-to-a-cretin-address/">Postfix: allow select users permission to send to a cretin address</a> is a post from; <a href="http://technology.mattrude.com/">Matt&#039;s Technology Blog</a> which is not allowed to be copied on other sites.]]></description>
			<content:encoded><![CDATA[<p>So the idea here is to have an email address that you would only like a select few to have access to email to, for example, a everyone or all address. In this example we will be locking down the email address <strong>all@example.com</strong> and only allow the address <strong>abc@example.com</strong> to send to it.</p>
<p>In <strong>/etc/postfix/main.cf</strong> add the following:</p>
<pre>smtpd_restrictions_classes =  restricted_recipient</pre>
<ul>
<li><strong>note:</strong> This is in smtpd_SENDER_restrictions to avoid becoming an open relay because of the &#8220;OK&#8221; below.</li>
</ul>
<pre>smtpd_sender_restrictions =
  check_recipient_access hash:/etc/postfix/restricted_recipient

restricted_recipient =
  check_sender_access hash:/etc/postfix/privileged_sender
  reject</pre>
<p><strong>restricted_recipient:</strong></p>
<pre>all@example.com         restricted_recipient</pre>
<p><strong>privileged_sender:</strong></p>
<pre>abc@example.com         OK</pre>
<a href="http://technology.mattrude.com/2009/05/postfix-allow-select-users-permission-to-send-to-a-cretin-address/">Postfix: allow select users permission to send to a cretin address</a> is a post from; <a href="http://technology.mattrude.com/">Matt&#039;s Technology Blog</a> which is not allowed to be copied on other sites.]]></content:encoded>
			<wfw:commentRss>http://technology.mattrude.com/2009/05/postfix-allow-select-users-permission-to-send-to-a-cretin-address/feed/</wfw:commentRss>
		<slash:comments>0</slash:comments>
		</item>
		<item>
		<title>Fail2Ban Setup with RoundCube</title>
		<link>http://technology.mattrude.com/2009/05/fail2ban-setup-with-roundcube/</link>
		<comments>http://technology.mattrude.com/2009/05/fail2ban-setup-with-roundcube/#comments</comments>
		<pubDate>Wed, 20 May 2009 13:55:10 +0000</pubDate>
		<dc:creator>Matt Rude</dc:creator>
				<category><![CDATA[Plugins]]></category>
		<category><![CDATA[RoundCube]]></category>
		<category><![CDATA[Authentication]]></category>
		<category><![CDATA[fail2ban]]></category>
		<category><![CDATA[IP address]]></category>
		<category><![CDATA[Protocols]]></category>

		<guid isPermaLink="false">http://www.mattrude.com/?p=207</guid>
		<description><![CDATA[In order for Fail2Ban to be able to ban IP addresses from computers trying to break into RoundCube. RoundCube needs to write the IP address of the offending system in it&#8217;s logs. To accomplish this, run the following patch from &#8230; <a href="http://technology.mattrude.com/2009/05/fail2ban-setup-with-roundcube/">Continue reading <span class="meta-nav">&#8594;</span></a><a href="http://technology.mattrude.com/2009/05/fail2ban-setup-with-roundcube/">Fail2Ban Setup with RoundCube</a> is a post from; <a href="http://technology.mattrude.com/">Matt&#039;s Technology Blog</a> which is not allowed to be copied on other sites.]]></description>
			<content:encoded><![CDATA[<p>In order for Fail2Ban to be able to ban IP addresses from computers trying to break into RoundCube.  RoundCube needs to write the IP address of the offending system in it&#8217;s logs.  To accomplish this,  run the following patch from the root of your RoundCube directory, or modify the program/lib/imap.inc file directly.</p>
<p><strong>program/lib/imap.inc</strong></p>
<pre>Index: program/lib/imap.inc
============================================================
--- program/lib/imap.inc        (revision 2446)
+++ program/lib/imap.inc        (working copy)
@@ -428,7 +428,7 @@
&amp;amp;amp;lt;br /&amp;amp;amp;gt;
if ($result == -3) fclose($conn-&amp;amp;amp;gt;fp); // BYE response
&amp;amp;amp;lt;br /&amp;amp;amp;gt;
-    $conn-&amp;amp;amp;gt;error    .= 'Authentication for ' . $user . ' failed (AUTH): &amp;amp;amp;quot;';
+    $conn-&amp;amp;amp;gt;error    .= 'Authentication for ' . $user . ' (' . getenv(&amp;amp;amp;quot;REMOTE_ADDR&amp;amp;amp;quot;) . ') failed (AUTH): &amp;amp;amp;quot;';
$conn-&amp;amp;amp;gt;error    .= htmlspecialchars($line) . '&amp;amp;amp;quot;';
$conn-&amp;amp;amp;gt;errorNum  = $result;</pre>
<p>Once you have RoundCube patched, you may use the below config and filter in Fail2Ban to block the IP address from RoundCube&#8217;s logs.</p>
<p><strong>/etc/fail2ban/jail.conf:</strong></p>
<pre>[roundcube]
enabled  = true
port     = http,https
filter   = roundcube
action   = iptables-multiport[name=roundcube, port=&amp;amp;amp;quot;http,https&amp;amp;amp;quot;]
logpath  = /var/logs/httpd/errors</pre>
<p><strong>/etc/fail2ban/filter.d/roundcube.conf:</strong></p>
<pre>[Definition]
failregex = IMAP Error: Authentication for .* (&amp;amp;amp;lt;HOST&amp;amp;amp;amp;lg;) failed ((?:LOGIN|AUTH)):
ignoreregex =</pre>
<a href="http://technology.mattrude.com/2009/05/fail2ban-setup-with-roundcube/">Fail2Ban Setup with RoundCube</a> is a post from; <a href="http://technology.mattrude.com/">Matt&#039;s Technology Blog</a> which is not allowed to be copied on other sites.]]></content:encoded>
			<wfw:commentRss>http://technology.mattrude.com/2009/05/fail2ban-setup-with-roundcube/feed/</wfw:commentRss>
		<slash:comments>4</slash:comments>
		</item>
	</channel>
</rss>

