<?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"
	>

<channel>
	<title>freebsdguy</title>
	<atom:link href="http://www.freebsdguy.co.uk/feed/" rel="self" type="application/rss+xml" />
	<link>http://www.freebsdguy.co.uk</link>
	<description>freebsd guides from freebsd users</description>
	<pubDate>Thu, 16 Oct 2008 13:42:16 +0000</pubDate>
	<generator>http://wordpress.org/?v=2.5</generator>
	<language>en</language>
			<item>
		<title>R.I.P. CVSup</title>
		<link>http://www.freebsdguy.co.uk/2008/10/16/rip-cvsup/</link>
		<comments>http://www.freebsdguy.co.uk/2008/10/16/rip-cvsup/#comments</comments>
		<pubDate>Thu, 16 Oct 2008 13:16:05 +0000</pubDate>
		<dc:creator>james</dc:creator>
		
		<category><![CDATA[cvsup]]></category>

		<category><![CDATA[freebsd]]></category>

		<category><![CDATA[ports]]></category>

		<category><![CDATA[portsnap]]></category>

		<guid isPermaLink="false">http://www.freebsdguy.co.uk/?p=38</guid>
		<description><![CDATA[<div class="postavatar"><img src="http://www.freebsdguy.co.uk/wp-content/uploads/2008/10/update_avatar.jpg" style="width:128px; height:128px; border:none;" alt="rip-cvsup" /></div>
CVSup - slow, painful, annoying (imho, prove me wrong!).
For the last year or so I&#8217;ve exclusively used Portsnap.  From the handbook:
Portsnap is a system for securely distributing the FreeBSD ports tree. Approximately once an hour, a “snapshot” of the ports tree is generated, repackaged, and cryptographically signed. The resulting files are then distributed via HTTP.

Portsnap [...]]]></description>
			<content:encoded><![CDATA[<div class="postavatar"><img src="http://www.freebsdguy.co.uk/wp-content/uploads/2008/10/update_avatar.jpg" style="width:128px; height:128px; border:none;" alt="rip-cvsup" /></div>
<p>CVSup - slow, painful, annoying (imho, prove me wrong!).</p>
<p>For the last year or so I&#8217;ve exclusively used Portsnap.  From the handbook:</p>
<blockquote><p><strong class="APPLICATION">Portsnap</strong> is a system for securely distributing the FreeBSD ports tree. Approximately once an hour, a “snapshot” of the ports tree is generated, repackaged, and cryptographically signed. The resulting files are then distributed via HTTP.</p></blockquote>
<p><span id="more-38"></span></p>
<p>Portsnap is VERY easy to use and requires practically no configuration, unlike cvsup.  It is included with FreeBSD 6+ (earlier versions of FreeBSD will need to have portsnap installed).</p>
<p>If you are installing Portsnap from ports, you&#8217;ll need to do 1 thing prior to use, and that is copy the configuration file to the correct location:</p>
<pre>cp /usr/local/etc/portsnap.conf.sample /usr/local/etc/portsnap.conf</pre>
<p>Also, if you&#8217;re running FreeBSD 6 and don&#8217;t have a ports collection already:</p>
<pre>mkdir /usr/ports</pre>
<p>Now we can get down to business!  First we fetch the portsnap image:</p>
<pre>portsnap fetch</pre>
<p>.. and then we extract the portsnap image:</p>
<pre>portsnap extract</pre>
<p>In the future, if we want to update the ports tree (which you WILL), issue the following commands:</p>
<pre>portsnap fetch
portsnap update</pre>
<p>If you&#8217;re lazy (I hope you are!), add a crontab line to execute:</p>
<pre>portsnap cron &amp;&amp; portsnap -I update</pre>
<p>portsnap cron does the same as fetch, but adds a random wait time up to an hour to ensure that not everybody is hitting the servers at midnight or whatever.</p>
]]></content:encoded>
			<wfw:commentRss>http://www.freebsdguy.co.uk/2008/10/16/rip-cvsup/feed/</wfw:commentRss>
		</item>
		<item>
		<title>Sharing Media via iTunes &#038; Daapd</title>
		<link>http://www.freebsdguy.co.uk/2008/04/07/sharing-media-via-itunes-daapd/</link>
		<comments>http://www.freebsdguy.co.uk/2008/04/07/sharing-media-via-itunes-daapd/#comments</comments>
		<pubDate>Mon, 07 Apr 2008 08:40:59 +0000</pubDate>
		<dc:creator>james</dc:creator>
		
		<category><![CDATA[OSX]]></category>

		<category><![CDATA[Windows]]></category>

		<category><![CDATA[firefox]]></category>

		<category><![CDATA[freebsd]]></category>

		<category><![CDATA[mysql]]></category>

		<category><![CDATA[network]]></category>

		<category><![CDATA[apple]]></category>

		<category><![CDATA[daapd]]></category>

		<category><![CDATA[iTunes]]></category>

		<category><![CDATA[mdnsresponder]]></category>

		<category><![CDATA[media]]></category>

		<category><![CDATA[mp3]]></category>

		<category><![CDATA[share]]></category>

		<guid isPermaLink="false">http://www.freebsdguy.co.uk/?p=37</guid>
		<description><![CDATA[<div class="postavatar"><img src="http://www.freebsdguy.co.uk/wp-content/uploads/2008/03/network-avatar.gif" style="width:100px; height:100px; border:none;" alt="sharing-media-via-itunes-daapd" /></div>
Sharing media over the network using iTunes media sharing is easy, but it&#8217;s even better when you can set up FreeBSD as  your backend media library server.  We can achieve this by using mt-daapd and mDNSResponder.

Start with my favorite 2 commands:
portsnap fetch
portsnap update
Install daapd:
cd /usr/ports/audio/mt-daapd/
make install clean
cp /usr/local/etc/mt-daapd.conf.sample /usr/local/etc/mt-daapd.conf
Edit /usr/local/etc/daapd.conf to configure the service.  Change [...]]]></description>
			<content:encoded><![CDATA[<div class="postavatar"><img src="http://www.freebsdguy.co.uk/wp-content/uploads/2008/03/network-avatar.gif" style="width:100px; height:100px; border:none;" alt="sharing-media-via-itunes-daapd" /></div>
<p>Sharing media over the network using iTunes media sharing is easy, but it&#8217;s even better when you can set up FreeBSD as  your backend media library server.  We can achieve this by using mt-daapd and mDNSResponder.</p>
<p><span id="more-37"></span></p>
<p>Start with my favorite 2 commands:</p>
<pre>portsnap fetch
portsnap update</pre>
<p>Install daapd:</p>
<pre><tt>cd /usr/ports/audio/mt-daapd/</tt><tt>
make install clean
cp /usr/local/etc/mt-daapd.conf.sample /usr/local/etc/mt-daapd.conf</tt></pre>
<p>Edit /usr/local/etc/daapd.conf to configure the service.  Change Root to the location of your music and ServerName/DBName to whatever you like. It&#8217;s quite clear what you can/should edit, the least of which are these two lines:</p>
<pre>ServerName      Shared Library
Root            /media/warehouse/audio</pre>
<p>There&#8217;s also a line art_filename in which you can specfy your album art.  It&#8217;s experimental at best but occasionally works <img src='http://www.freebsdguy.co.uk/wp-includes/images/smilies/icon_smile.gif' alt=':)' class='wp-smiley' /> </p>
<p>Install mDNSResponder:</p>
<pre>cd /usr/ports/net/mDNSResponder/
make install clean</pre>
<p>Create the file /usr/local/etc/mDNSResponder.conf and edit it to look like this (the blank line in intentional):</p>
<pre>FreeBSDGuy iTunes server
_daap._tcp.

3689</pre>
<p>Add these two lines to /etc/rc.conf:</p>
<pre>mt_daapd_enable=YES
mdnsd_enable=YES</pre>
<p>Fire up the services:</p>
<pre>/usr/local/etc/rc.d/mt-daapd start
/usr/local/etc/rc.d/mdnsd start</pre>
<p>Hopefully when you start iTunes you should see your new shared library!</p>
]]></content:encoded>
			<wfw:commentRss>http://www.freebsdguy.co.uk/2008/04/07/sharing-media-via-itunes-daapd/feed/</wfw:commentRss>
		</item>
		<item>
		<title>Share files with OS X using NFS</title>
		<link>http://www.freebsdguy.co.uk/2008/03/22/share-files-with-os-x-using-nfs/</link>
		<comments>http://www.freebsdguy.co.uk/2008/03/22/share-files-with-os-x-using-nfs/#comments</comments>
		<pubDate>Sat, 22 Mar 2008 12:54:23 +0000</pubDate>
		<dc:creator>james</dc:creator>
		
		<category><![CDATA[NFS]]></category>

		<category><![CDATA[OSX]]></category>

		<category><![CDATA[freebsd]]></category>

		<category><![CDATA[network]]></category>

		<guid isPermaLink="false">http://www.freebsdguy.co.uk/2008/03/22/share-files-with-os-x-using-nfs/</guid>
		<description><![CDATA[<div class="postavatar"><img src="http://www.freebsdguy.co.uk/wp-content/uploads/2008/03/network-avatar.gif" style="width:100px; height:100px; border:none;" alt="share-files-with-os-x-using-nfs" /></div>
Last year I bought a Mac Mini with the intention of using it as the front end for a media centre solution.
For my plan to work, I needed to share my media from the FreeBSD server to the Mac.  Considering both of these operating systems are *nix based, I decided to go with the [...]]]></description>
			<content:encoded><![CDATA[<div class="postavatar"><img src="http://www.freebsdguy.co.uk/wp-content/uploads/2008/03/network-avatar.gif" style="width:100px; height:100px; border:none;" alt="share-files-with-os-x-using-nfs" /></div>
<p>Last year I bought a Mac Mini with the intention of using it as the front end for a media centre solution.</p>
<p>For my plan to work, I needed to share my media from the FreeBSD server to the Mac.  Considering both of these operating systems are *nix based, I decided to go with the triied-and-tested <a href="http://www.freebsd.org/doc/en_US.ISO8859-1/books/handbook/network-nfs.html">NFS</a> to do the sharing.<span id="more-35"></span></p>
<p>So, on the BSD machine, edit the file /etc/rc.conf to include these lines:<br />
<code>rpcbind_enable="YES"<br />
nfs_server_enable="YES"<br />
mountd_flags="-r"<br />
nfs_reserved_port_only="NO"<br />
</code><br />
This will enable the NFS server on boot.  The nfs_reserved_port_only line is especially for OSX that likes to use ports above 1024 for NFS!</p>
<p>Next, edit /etc/exports to list the shares and also who is allowed to mount them:<br />
<code>/store/media -ro 192.168.1.0</code><br />
This line configures /store/media to be mountable by clients, allows them to access it ReadOnly and allows access from anybody within the given address range 192.168.1.x.</p>
<p>If you change your exports file, you need to run the following command to allow the system to re-read the file:<br />
<code>/etc/rc.d/mountd onereload</code></p>
<p>There are several other options you can use (-maproot etc), which you can find from the <a href="http://www.freebsd.org/doc/en_US.ISO8859-1/books/handbook/network-nfs.html">FreeBSD handbook NFS</a> page.</p>
<p>On the Mac it was quite simple to mount the share.  Open finder and from the top menu Click Go > Connect To Server&#8230;.</p>
<p>In the dialog that appears, type in the location of the share.  In my example this would be:<br />
<code>nfs://192.168.1.1/store/media</code><br />
OS X should make a pretty icon on your desktop for the share (and you can find it mounted in /Volumes too).</p>
]]></content:encoded>
			<wfw:commentRss>http://www.freebsdguy.co.uk/2008/03/22/share-files-with-os-x-using-nfs/feed/</wfw:commentRss>
		</item>
		<item>
		<title>Xming Server - Bring Xorg to Windows</title>
		<link>http://www.freebsdguy.co.uk/2007/12/29/xming-server-bring-xorg-to-windows/</link>
		<comments>http://www.freebsdguy.co.uk/2007/12/29/xming-server-bring-xorg-to-windows/#comments</comments>
		<pubDate>Sat, 29 Dec 2007 15:47:54 +0000</pubDate>
		<dc:creator>james</dc:creator>
		
		<category><![CDATA[Windows]]></category>

		<category><![CDATA[Xorg]]></category>

		<category><![CDATA[authentication]]></category>

		<category><![CDATA[freebsd]]></category>

		<category><![CDATA[network]]></category>

		<category><![CDATA[putty]]></category>

		<category><![CDATA[ssh]]></category>

		<category><![CDATA[x11]]></category>

		<guid isPermaLink="false">http://www.freebsdguy.co.uk/2007/12/29/xming-server-bring-xorg-to-windows/</guid>
		<description><![CDATA[<div class="postavatar"><img src="http://www.freebsdguy.co.uk/wp-content/uploads/2007/12/xorg_avatar.png" style="width:100px; height:100px; border:none;" alt="xming-server-bring-xorg-to-windows" /></div>
Last night a friend (on right) of mine tipped me off about an excellent X server for Windows. I got fed up using the cygwin so decided to try it out. Xming is a cool name too!
Here is what you need to get:

Root Access
Xorg installed
SSH Access to the FreeBSD machine from the Windows machine
Putty on [...]]]></description>
			<content:encoded><![CDATA[<div class="postavatar"><img src="http://www.freebsdguy.co.uk/wp-content/uploads/2007/12/xorg_avatar.png" style="width:100px; height:100px; border:none;" alt="xming-server-bring-xorg-to-windows" /></div>
<p>Last night a <a href="http://www.edinatl.com/IMG0055.JPG">friend (on right)</a> of mine tipped me off about an excellent X server for Windows. I got fed up using the cygwin so decided to try it out. Xming is a cool name too!</p>
<p>Here is what you need to get:</p>
<ul>
<li>Root Access</li>
<li>Xorg installed</li>
<li>SSH Access to the FreeBSD machine from the Windows machine</li>
<li>Putty on the Windows machine</li>
<li>Download Xming to the Windows machine</li>
</ul>
<p><span id="more-25"></span><br />
Xming can be downloaded from the <a href="http://sourceforge.net/projects/xming">Xming project homepage at Sourceforge</a>.<br />
Execute this after download and do a full install.  It&#8217;s very straightforward and will just leave you with a small icon in the Windows system tray:</p>
<p><a title="Xming Tray Icon" href="http://www.freebsdguy.co.uk/wp-content/uploads/2007/12/xmingicon.png"><img src="http://www.freebsdguy.co.uk/wp-content/uploads/2007/12/xmingicon.thumbnail.png" alt="Xming Tray Icon" /></a></p>
<p>On the FreeBSD machine, if you&#8217;ve not got Xorg installed, quickly do a<br />
<code>pkg_add -r xorg</code><br />
and you&#8217;ll have it soon enough.</p>
<p>You will need to update the sshd configuration:<br />
<code>edit /etc/ssh/sshd_config</code><br />
adding the line:<br />
<code>X11Forwarding yes</code><br />
to the end and saving.<br />
Follow this up with a restart of the sshd daemon:<br />
<code>kill -HUP `cat /var/run/sshd.pid`</code></p>
<p>Then, on the Windows machine, load up your putty and change the connection settings to they have the X11 forwarding enabled:</p>
<p><a title="Putty with X11 Forwarding" href="http://www.freebsdguy.co.uk/wp-content/uploads/2007/12/putty_x11.png"><img src="http://www.freebsdguy.co.uk/wp-content/uploads/2007/12/putty_x11.thumbnail.png" alt="Putty with X11 Forwarding" /></a><br />
Fire up your putty connection now.  Once connected,  become root and add an X application from packages and then exit back to normal user level:<br />
<code>su root</code><br />
and then type your password&#8230;<br />
<code>pkg_add -r thunderbird<br />
exit</code><br />
Now we start the application:<br />
<code>thunderbird</code><br />
Notice that it starts up on your Windows desktop.  Try this out with loads of other applications too, it&#8217;s a doddle.  I currently use it for email, web and xfce4 as a launcher of my unix apps.  I&#8217;m also thinking of having Eclipse IDE installed centrally on a server and then connecting remotely every time I want to do some development - this one is ultra handy since that&#8217;s where my Tomcat server is too <img src='http://www.freebsdguy.co.uk/wp-includes/images/smilies/icon_wink.gif' alt=';)' class='wp-smiley' /></p>
]]></content:encoded>
			<wfw:commentRss>http://www.freebsdguy.co.uk/2007/12/29/xming-server-bring-xorg-to-windows/feed/</wfw:commentRss>
		</item>
		<item>
		<title>OpenFire - Jabber Server and IM Gateway</title>
		<link>http://www.freebsdguy.co.uk/2007/12/13/openfire-jabber-server-and-im-gateway/</link>
		<comments>http://www.freebsdguy.co.uk/2007/12/13/openfire-jabber-server-and-im-gateway/#comments</comments>
		<pubDate>Thu, 13 Dec 2007 14:42:11 +0000</pubDate>
		<dc:creator>james</dc:creator>
		
		<category><![CDATA[Mobile]]></category>

		<category><![CDATA[freebsd]]></category>

		<category><![CDATA[jabber]]></category>

		<category><![CDATA[mysql]]></category>

		<category><![CDATA[network]]></category>

		<category><![CDATA[pf]]></category>

		<guid isPermaLink="false">http://www.freebsdguy.co.uk/2007/12/13/openfire-jabber-server-and-im-gateway/</guid>
		<description><![CDATA[<div class="postavatar"><img src="http://www.freebsdguy.co.uk/wp-content/uploads/2007/12/chat_avatar.png" style="width:100px; height:100px; border:none;" alt="openfire-jabber-server-and-im-gateway" /></div>
As I work in a large corporation who have all their satellite offices (like my own) connect to the Internet through a central structure, I decided I didn&#8217;t want some IT nerd reading all my IM&#8217;s.  SSH wasn&#8217;t good enough - I wanted a robust solution that didn&#8217;t take much tinkering and would support [...]]]></description>
			<content:encoded><![CDATA[<div class="postavatar"><img src="http://www.freebsdguy.co.uk/wp-content/uploads/2007/12/chat_avatar.png" style="width:100px; height:100px; border:none;" alt="openfire-jabber-server-and-im-gateway" /></div>
<p>As I work in a large corporation who have all their satellite offices (like my own) connect to the Internet through a central structure, I decided I didn&#8217;t want some IT nerd reading all my IM&#8217;s.  SSH wasn&#8217;t good enough - I wanted a robust solution that didn&#8217;t take much tinkering and would support all the protocols I use  (MSN, Yahoo, AIM, Gtalk, soon SIP).<br />
<span id="more-22"></span><br />
That&#8217;s when I came across Jabber, mentioned by a friend of mine on his <a href="http://art.csoft.net/">blog</a>.</p>
<p>There&#8217;s a good list of Jabber components on <a href="http://en.wikipedia.org/wiki/List_of_Jabber_server_software">Wikipedia</a>, but for ease of install and use, I went with OpenFire.  OpenFire has a free version and a commercial version.  No guessing which version I chose to run <img src='http://www.freebsdguy.co.uk/wp-includes/images/smilies/icon_wink.gif' alt=';)' class='wp-smiley' /> </p>
<p>OpenFire can be found in ports (/usr/ports/net-im/openfire/) so is pretty easy to install.</p>
<p>Anyway, lets get cracking.  First make sure you have these things:</p>
<ul>
<li>Up to date ports tree</li>
<li>root</li>
<li>Full firewall control (if needed)</li>
<li>MySQL</li>
</ul>
<p>Lets start:</p>
<blockquote><p>cd /usr/ports/net-im/openfire<br />
make install clean</p></blockquote>
<p>then:</p>
<blockquote><p>edit /etc/rc.conf</p></blockquote>
<p>and insert this line:</p>
<blockquote><p>openfire_enable=&#8221;YES&#8221;</p></blockquote>
<p>Manually start the server</p>
<blockquote><p>/usr/local/etc/rc.d/openfire.sh start</p></blockquote>
<p>This should start the web interface.  This interface runs on port 9090 (open your firewall if you need to!) and will guide you through the setup of OpenFire jabber server.  You will need to have created a MySQL database and a user to authenticate against the database.</p>
<p>You also are given the option to use LDAP for users, this isn&#8217;t covered here because I don&#8217;t use LDAP.</p>
<p>Finally set the admin email and wait for it to complete the setup.  Once that&#8217;s done it&#8217;ll take you to a login form for admin.</p>
<p>Login using the username AND password admin</p>
<p>You&#8217;ll get the gist of things from there.</p>
]]></content:encoded>
			<wfw:commentRss>http://www.freebsdguy.co.uk/2007/12/13/openfire-jabber-server-and-im-gateway/feed/</wfw:commentRss>
		</item>
		<item>
		<title>Java JDK 1.5</title>
		<link>http://www.freebsdguy.co.uk/2007/12/13/java-jdk-15/</link>
		<comments>http://www.freebsdguy.co.uk/2007/12/13/java-jdk-15/#comments</comments>
		<pubDate>Thu, 13 Dec 2007 13:22:46 +0000</pubDate>
		<dc:creator>james</dc:creator>
		
		<category><![CDATA[freebsd]]></category>

		<category><![CDATA[java]]></category>

		<category><![CDATA[pita]]></category>

		<guid isPermaLink="false">http://www.freebsdguy.co.uk/2007/12/13/java-jdk-15/</guid>
		<description><![CDATA[<div class="postavatar"><img src="http://www.freebsdguy.co.uk/wp-content/uploads/2007/09/java.jpg" style="width:99px; height:99px; border:none;" alt="java-jdk-15" /></div>
Installing Java can be a pain in the ass.  You have to download the files manually for licensing purposes 

cd /usr/ports/java/diablo-jdk15
make install clean

You&#8217;ll see the notes regarding downloading the files.  Access the urls with a browser, accept the agreements and download the two files it wants.
Note: you need an account at Sun.com for [...]]]></description>
			<content:encoded><![CDATA[<div class="postavatar"><img src="http://www.freebsdguy.co.uk/wp-content/uploads/2007/09/java.jpg" style="width:99px; height:99px; border:none;" alt="java-jdk-15" /></div>
<p>Installing Java can be a pain in the ass.  You have to download the files manually for licensing purposes <img src='http://www.freebsdguy.co.uk/wp-includes/images/smilies/icon_sad.gif' alt=':(' class='wp-smiley' /><br />
<span id="more-24"></span></p>
<blockquote><p>cd /usr/ports/java/diablo-jdk15<br />
make install clean
</p></blockquote>
<p>You&#8217;ll see the notes regarding downloading the files.  Access the urls with a browser, accept the agreements and download the two files it wants.<br />
Note: you need an account at Sun.com for one of the files - a further pain in the ass.<br />
<strong>diablo-caffe-freebsd5-i386-1.5.0_07-b01.tar.bz2</strong> is the source, <strong>tzupdater-1_3_0-2007h.zip</strong> is the timezone update.</p>
<p>When that&#8217;s done, move them into your /usr/ports/distfiles directory.</p>
<blockquote><p>cd /usr/ports/java/diablo-jdk15<br />
make install clean
</p></blockquote>
<p>This time you should see the farmiliar port install config page.  Make sure the timezone update is selected and continue.</p>
<p>Take a break, this takes a while.  When it&#8217;s done, test it out by typing:</p>
<blockquote><p>rehash<br />
java -version</p></blockquote>
<p>and you should see something similar to this:</p>
<blockquote><p>Java(TM) 2 Runtime Environment, Standard Edition (build diablo-1.5.0-b01)<br />
Java HotSpot(TM) Client VM (build diablo-1.5.0_07-b01, mixed mode)
</p></blockquote>
]]></content:encoded>
			<wfw:commentRss>http://www.freebsdguy.co.uk/2007/12/13/java-jdk-15/feed/</wfw:commentRss>
		</item>
		<item>
		<title>RTIR: Request Tracker Incident Response</title>
		<link>http://www.freebsdguy.co.uk/2007/12/12/rtir-request-tracker-incident-response/</link>
		<comments>http://www.freebsdguy.co.uk/2007/12/12/rtir-request-tracker-incident-response/#comments</comments>
		<pubDate>Wed, 12 Dec 2007 23:33:16 +0000</pubDate>
		<dc:creator>james</dc:creator>
		
		<category><![CDATA[apache]]></category>

		<category><![CDATA[freebsd]]></category>

		<category><![CDATA[mail]]></category>

		<category><![CDATA[mysql]]></category>

		<category><![CDATA[perl]]></category>

		<category><![CDATA[rt]]></category>

		<category><![CDATA[rtir]]></category>

		<category><![CDATA[aliases]]></category>

		<guid isPermaLink="false">http://www.freebsdguy.co.uk/2007/12/12/rtir-request-tracker-incident-response/</guid>
		<description><![CDATA[<div class="postavatar"><img src="http://www.freebsdguy.co.uk/wp-content/uploads/2007/12/www_avatar.gif" style="width:100px; height:100px; border:none;" alt="rtir-request-tracker-incident-response" /></div>
RTIR is an incident response module for RT, so clearly we had to take a little peek at the goods.  This is really meant for incident responmse / network operations teams.
RTIR is built on RT, but provides different functionality.  Read here for more information regarding the usefulness of RT and RTIR.

Lets start by [...]]]></description>
			<content:encoded><![CDATA[<div class="postavatar"><img src="http://www.freebsdguy.co.uk/wp-content/uploads/2007/12/www_avatar.gif" style="width:100px; height:100px; border:none;" alt="rtir-request-tracker-incident-response" /></div>
<p>RTIR is an incident response module for RT, so clearly we had to take a little peek at the goods.  This is really meant for incident responmse / network operations teams.</p>
<p>RTIR is built on RT, but provides different functionality.  Read <a href="http://www.bestpractical.com/rtir/comparison.html">here </a>for more information regarding the usefulness of RT and RTIR.<br />
<span id="more-23"></span><br />
Lets start by installing the needed Perl modules:</p>
<blockquote><p>perl -MCPAN -e &#8216;install Business::Hours&#8217;<br />
perl -MCPAN -e &#8216;install Net::Whois::RIPE&#8217;</p></blockquote>
<p>and downloading rtir and extracting it:</p>
<blockquote><p>wget http://download.bestpractical.com/pub/rt/release/rtir.tar.gz<br />
tar xfzv rtir.tar.gz</p></blockquote>
<p>Now we need to configure the Makefile so that it points to our installed RT, otherwise it&#8217;ll have no clue where to install.  So we will use the path from our earlier install of RT.</p>
<blockquote><p>
cd rtir-1.0.5/<br />
edit Makefile</p></blockquote>
<p>Change the RT_ROOT to the location of your rt install.  Mine happens to be /usr/local/RT<br />
I did change the group rt to www also, since RT doesn&#8217;t install its own group in FreeBSD <img src='http://www.freebsdguy.co.uk/wp-includes/images/smilies/icon_wink.gif' alt=';)' class='wp-smiley' /> </p>
<p>Save the file and exit.</p>
<blockquote><p>make install</p></blockquote>
<p>This next step ensures that RT will not work unless the RTIR config is present.</p>
<blockquote><p>edit /usr/local/RT/etc/RT_SiteConfig.pm</p></blockquote>
<p>and add this:</p>
<blockquote><p>   # The RTIR config file<br />
   $RTIR_CONFIG_FILE = &#8220;/usr/local/RT/etc/RTIR_Config.pm&#8221;;<br />
   require $RTIR_CONFIG_FILE<br />
     || die (&#8221;Couldn&#8217;t load RTIR config file &#8216;$RTIR_CONFIG_FILE&#8217;\n$@&#8221;);</p></blockquote>
<p>Save the file and exit.</p>
<blockquote><p>make initdb</p></blockquote>
<p>This will request your root password.  Enter it and hit enter.  10 seconds later the process is complete. Restart Apache for good luck!</p>
<blockquote><p>apachectl restart</p></blockquote>
<p>That&#8217;s the hard bit out of the way.</p>
<p>Browse RT and login as your root user.</p>
<p>Browse to: <strong>Configuration </strong>-> <strong>Queues </strong>-> <strong>Blocks </strong>-> <strong>Watchers</strong><br />
Add your network operations team email address to the &#8216;Administrative Cc:&#8217; field.</p>
<p>Configure your default emails sent when an Investigation or Block is logged by:<br />
Browse to: <strong>Configuration </strong>-> <strong>Queues </strong>-> <strong>Blocks </strong>-> <strong>Templates </strong>-> <strong>NewMessage</strong><br />
and customise the email.</p>
<p>Browse to: <strong>Configuration </strong>-> <strong>Queues </strong>-> <strong>Investigations </strong>-> <strong>Templates </strong>-> <strong>LaunchMessage</strong><br />
and customise the email.</p>
<p>Here are some other tips from the RTIR Readme:</p>
<ul>
<li>By default, RT3 has certain global Scrips.  You should look through them, and disable any that don&#8217;t want.</li>
<li>Staff members who handle incidents should be added to the DutyTeam group.</li>
</ul>
<p>Incident reports need a mail alias, so again:</p>
<blockquote><p>edit /etc/aliases</p></blockquote>
<p>Add the following line:</p>
<blockquote><p>rtir:         &#8220;|/usr/local/RT/bin/rt-mailgate &#8211;queue &#8216;Incident Reports&#8217; &#8211;action correspond &#8211;url http://yourhostname:81/&#8221;</p></blockquote>
<p>Remember to change the hostname to match your install!</p>
<p>This should be RTIR installed.  It worked for me.  Remember to follow each step logically.  If you get no luck, it might be a good plan to look in /var/log/httpd-error.log before getting worked up about it.</p>
]]></content:encoded>
			<wfw:commentRss>http://www.freebsdguy.co.uk/2007/12/12/rtir-request-tracker-incident-response/feed/</wfw:commentRss>
		</item>
		<item>
		<title>RT: Request Tracker</title>
		<link>http://www.freebsdguy.co.uk/2007/12/12/rt-request-tracker/</link>
		<comments>http://www.freebsdguy.co.uk/2007/12/12/rt-request-tracker/#comments</comments>
		<pubDate>Wed, 12 Dec 2007 12:20:45 +0000</pubDate>
		<dc:creator>james</dc:creator>
		
		<category><![CDATA[apache]]></category>

		<category><![CDATA[freebsd]]></category>

		<category><![CDATA[mail]]></category>

		<category><![CDATA[mysql]]></category>

		<category><![CDATA[perl]]></category>

		<category><![CDATA[rt]]></category>

		<guid isPermaLink="false">http://www.freebsdguy.co.uk/2007/12/12/rt-request-tracker/</guid>
		<description><![CDATA[<div class="postavatar"><img src="http://www.freebsdguy.co.uk/wp-content/uploads/2007/12/www_avatar.gif" style="width:100px; height:100px; border:none;" alt="rt-request-tracker" /></div>
A friend of mine is installing RT for use in the company he works for.  I thought I&#8217;d give it a spin to see what the fuss was about.  Here&#8217;s what happened!
This was based on http://wiki.bestpractical.com/index.cgi?InstallationGuides and the README distributed with RT.
What we need:

root
Perl
MySQL (Although you can use Oracle, Sqlite, Postgres)
Apache

Download and extract [...]]]></description>
			<content:encoded><![CDATA[<div class="postavatar"><img src="http://www.freebsdguy.co.uk/wp-content/uploads/2007/12/www_avatar.gif" style="width:100px; height:100px; border:none;" alt="rt-request-tracker" /></div>
<p>A friend of mine is installing RT for use in the company he works for.  I thought I&#8217;d give it a spin to see what the fuss was about.  Here&#8217;s what happened!<span id="more-21"></span></p>
<p>This was based on http://wiki.bestpractical.com/index.cgi?InstallationGuides and the README distributed with RT.</p>
<p>What we need:</p>
<ul>
<li>root</li>
<li>Perl</li>
<li>MySQL (Although you can use Oracle, Sqlite, Postgres)</li>
<li>Apache</li>
</ul>
<p>Download and extract RT:</p>
<blockquote><p>wget http://download.bestpractical.com/pub/rt/release/rt-3.6.5.tar.gz<br />
tar xzvf rt-3.6.5.tar.gz
</p></blockquote>
<p>Configure RT:</p>
<blockquote><p>cd rt-3.6.5<br />
./configure &#8211;help<br />
./configure (with the flags you want)</p></blockquote>
<p>Mine looked like this:</p>
<blockquote><p>./configure &#8211;prefix=/usr/local/RT &#8211;with-db-type=mysql &#8211;with-db-database=rt &#8211;with-db-rt-user=rt &#8211;with-db-rt-pass=rtpass</p></blockquote>
<p>Now we must fix dependancies as required with these commands:</p>
<blockquote><p>make testdeps<br />
make fixdeps</p></blockquote>
<p>Sometimes you might have to run fixdeps several times to make sure all of the required Perl modules get installed!<br />
&#8230;and eventually install:</p>
<blockquote><p>make install</p></blockquote>
<p>My install returned the following:</p>
<blockquote><p>Congratulations. RT has been installed.<br />
You must now configure RT by editing /usr/local/RT/etc/RT_SiteConfig.pm.</p></blockquote>
<p>When I looked in /usr/local/RT/etc/ there  is a file called RT_Config.pm which contains all the settings as specified in the configure command line.  Looking in here I saw the line:</p>
<blockquote><p>Set($DatabasePassword , &#8216;rtpass&#8217;);</p></blockquote>
<p>So I added this line to the RT_SiteConfig.pm file.<br />
Next step:</p>
<blockquote><p>make initialize-database</p></blockquote>
<p>Now that&#8217;s done, it&#8217;s time to get our web interface running since that&#8217;s what we want our users to use!  This command installes a Perl/Apache module that&#8217;s needed for database integration:</p>
<blockquote><p>perl -MCPAN -e&#8217;install Apache::DBI&#8217;</p></blockquote>
<p>Now we need to edit our Apache configs so that we can see RT in our browsers.  In this simple config, we get Apache to listen to requests on port 81, and serve RT from there.  You should be able to modify this for your needs and will al little imagination, get RT served from any url you want.</p>
<blockquote><p>
edit /usr/local/etc/apache22/extra/httpd-vhosts.conf
</p></blockquote>
<p>&#8230;and add these lines&#8230;</p>
<blockquote><p>
NameVirtualHost *:81<br />
<VirtualHost *:81><br />
#    ServerName your.rt.server.hostname<br />
    DocumentRoot /usr/local/RT/share/html<br />
    AddDefaultCharset UTF-8</p>
<p>    PerlModule Apache::DBI<br />
    PerlRequire /usr/local/RT3/bin/webmux.pl</p>
<p>    < Location /><br />
     SetHandler perl-script<br />
     PerlHandler RT::Mason<br />
    Order allow,deny<br />
    Allow from all<br />
    < /Location ></p>
<p>RedirectMatch permanent (.*)/$ http://10.151.102.40:81$1/index.html
</p></blockquote>
<p>..and for good measure&#8230;</p>
<blockquote><p>edit /usr/local/etc/apache22/httpd.conf</p></blockquote>
<p>&#8230;and add this line&#8230;</p>
<blockquote><p>Listen 10.151.102.40:81</p></blockquote>
<p>Restart Apache:</p>
<blockquote><p>apachectl restart</p></blockquote>
<p>Configure mail:</p>
<blockquote><p>edit /etc/aliases</p></blockquote>
<p>and add these lines:</p>
<blockquote><p>#rt stuff<br />
rt:         &#8220;|/usr/local/RT/bin/rt-mailgate &#8211;queue general &#8211;action correspond &#8211;url http://yourhostname:81&#8243;<br />
rt-comment: &#8220;|/usr/local/RT/rt-mailgate &#8211;queue general &#8211;action comment &#8211;url http://yourhostname:81&#8243;</p></blockquote>
<p>The www interface seems to work nicely and I get mails when work is assigned to me, edited etc.  If this machine could accept external mail, I could reply and add to the tickets too <img src='http://www.freebsdguy.co.uk/wp-includes/images/smilies/icon_wink.gif' alt=';)' class='wp-smiley' /> </p>
<p>Remember that the default login is root and the default password is password</p>
<p>Have fun, RTIR coming soon&#8230;</p>
]]></content:encoded>
			<wfw:commentRss>http://www.freebsdguy.co.uk/2007/12/12/rt-request-tracker/feed/</wfw:commentRss>
		</item>
		<item>
		<title>Replacing Apache with lighttpd</title>
		<link>http://www.freebsdguy.co.uk/2007/10/21/replacing-apache-with-lighttpd/</link>
		<comments>http://www.freebsdguy.co.uk/2007/10/21/replacing-apache-with-lighttpd/#comments</comments>
		<pubDate>Sun, 21 Oct 2007 23:18:17 +0000</pubDate>
		<dc:creator>james</dc:creator>
		
		<category><![CDATA[apache]]></category>

		<category><![CDATA[freebsd]]></category>

		<category><![CDATA[lighthttpd]]></category>

		<category><![CDATA[network]]></category>

		<guid isPermaLink="false">http://www.freebsdguy.co.uk/2007/10/21/replacing-apache-with-lighttpd/</guid>
		<description><![CDATA[<div class="postavatar"><img src="http://www.freebsdguy.co.uk/wp-content/uploads/2007/09/apache.jpg" style="width:100px; height:100px; border:none;" alt="replacing-apache-with-lighttpd" /></div>
As a precursor to researching Apache replacements for work, I decided to look at lighttpd at home.  I already have php5 installed (incluing fast-cgi support).  Here is how I installed lighttpd in my setup.  These steps were carried out as root.
cd /usr/ports/www/lighttpd
make install clean
I had to make sure mysql support was included, [...]]]></description>
			<content:encoded><![CDATA[<div class="postavatar"><img src="http://www.freebsdguy.co.uk/wp-content/uploads/2007/09/apache.jpg" style="width:100px; height:100px; border:none;" alt="replacing-apache-with-lighttpd" /></div>
<p>As a precursor to researching Apache replacements for work, I decided to look at lighttpd at home.  I already have php5 installed (incluing fast-cgi support).  Here is how I installed lighttpd in my setup.  These steps were carried out as root.<span id="more-20"></span></p>
<blockquote><p>cd /usr/ports/www/lighttpd<br />
make install clean</p></blockquote>
<p>I had to make sure mysql support was included, and dropped ipv6 support (Serisouly, I&#8217;m not going to see v6 for years).  Didn&#8217;t take long to compile, so straight to configuring:</p>
<p>Edit the file /usr/local/etc/lighttpd.conf and uncomment the line &#8220;mod_cgi&#8221;, &#8220;mod_fastcgi&#8221; and uncomment the entire section under #### fastcgi module.   This enables php to work.  Save the file and exit.</p>
<p>Lighttpd logs to /var/log/, so lets create the files now to avoid problems later:</p>
<blockquote><p>cd /var/log<br />
touch lighttpd.error.log<br />
touch lighttpd.access.log<br />
chown www:www lighttpd.error.log<br />
chown www:www lighttpd.access.log</p></blockquote>
<p>and for good measure create the folder for the pid file and make www the owner and group:</p>
<blockquote><p>/var/run/lighttpd/ and<br />
chown www:www /var/run/lighttpd/</p></blockquote>
<p>Configuring the server to start on boot is as simple as editing /etc/rc.conf, but we also need to specify the location of the configuration file in another parameter.  Add these lines to /etc/rc.conf:</p>
<blockquote><p>lighttpd_enable=yes<br />
lighttpd_conf=/usr/local/etc/lighttpd.conf
</p></blockquote>
<p>and now start it up with something like:</p>
<blockquote><p>/usr/local/etc/rc.d/lighttpd.sh start</p></blockquote>
<p>Mine started flawlessly.</p>
]]></content:encoded>
			<wfw:commentRss>http://www.freebsdguy.co.uk/2007/10/21/replacing-apache-with-lighttpd/feed/</wfw:commentRss>
		</item>
		<item>
		<title>JBoss 4 Application Server &#038; FreeBSD 6</title>
		<link>http://www.freebsdguy.co.uk/2007/09/19/jboss-4-application-server-freebsd-6/</link>
		<comments>http://www.freebsdguy.co.uk/2007/09/19/jboss-4-application-server-freebsd-6/#comments</comments>
		<pubDate>Wed, 19 Sep 2007 11:37:01 +0000</pubDate>
		<dc:creator>james</dc:creator>
		
		<category><![CDATA[apache]]></category>

		<category><![CDATA[freebsd]]></category>

		<category><![CDATA[java]]></category>

		<guid isPermaLink="false">http://www.freebsdguy.co.uk/2007/09/19/jboss-4-application-server-freebsd-6/</guid>
		<description><![CDATA[<div class="postavatar"><img src="http://www.freebsdguy.co.uk/wp-content/uploads/2007/09/java.jpg" style="width:99px; height:99px; border:none;" alt="jboss-4-application-server-freebsd-6" /></div>
At work, we currently have deployed apps that run on JBoss under Windows 2003.  No big deal really, apart from other services on the Windows servers tend to kill the entire box now and again - quite a pain in the backside.  So I&#8217;m trying to convince them to move to a more [...]]]></description>
			<content:encoded><![CDATA[<div class="postavatar"><img src="http://www.freebsdguy.co.uk/wp-content/uploads/2007/09/java.jpg" style="width:99px; height:99px; border:none;" alt="jboss-4-application-server-freebsd-6" /></div>
<p>At work, we currently have deployed apps that run on JBoss under Windows 2003.  No big deal really, apart from other services on the Windows servers tend to kill the entire box now and again - quite a pain in the backside.  So I&#8217;m trying to convince them to move to a more stable OS, that being FreeBSD.</p>
<p>I documented the whole thing (as you should), so here is my guide to installing and configuing JBoss4 on a fresh install of FreeBSD <img src='http://www.freebsdguy.co.uk/wp-includes/images/smilies/icon_smile.gif' alt=':-)' class='wp-smiley' /> <span id="more-19"></span> Before we start, we&#8217;d better check we have all the requirements:</p>
<ul>
<li>FreeBSD 6.2 installed and ready to rock</li>
<li>A root login account</li>
<li>SFTP / FTP access to the server</li>
</ul>
<p>First we&#8217;d better update our ports quickly.  We need to make sure we&#8217;re getting the most up to date sources:</p>
<blockquote><p>portsnap fetch<br />
portsnap update</p></blockquote>
<p>Obviously JBoss is a Java application server, so common sense would say we need to install Java first.  According to RedHat, the latest JBoss releases (4.2) only need the JRE (runtime environment) to run, but on FreeBSD that isn&#8217;t the case - it still wants to JDK (development kit) so lets install that:</p>
<blockquote><p>cd /usr/ports/java/diablo-jdk15 &amp;&amp; make install clean</p></blockquote>
<p>But you&#8217;ll find that complains:</p>
<blockquote><p> ===&gt;  diablo-jdk-1.5.0.07.01_7 :<br />
Because of licensing restrictions, you must fetch the distribution<br />
manually.<br />
Please access</p>
<p>http://www.FreeBSDFoundation.org/cgi-bin/download?download=diablo-caffe-freebsd6-i386-</p>
<p>1.5.0_07-b01.tar.bz2</p>
<p>with a web browser and &#8220;Accept&#8221; the End User License Agreement for<br />
&#8220;Caffe Diablo 1.5.0&#8243;.  Please place the downloaded<br />
diablo-caffe-freebsd6-i386-1.5.0_07-b01.tar.bz2 in /usr/ports/distfiles.</p>
<p>Please open http://java.sun.com/javase/downloads/index.jsp<br />
in a web browser and follow the &#8220;Download&#8221; link for<br />
&#8220;JDK US DST Timezone Update Tool - 1.2.2&#8243; to obtain the<br />
time zone update file, tzupdater-1_2_2-2007g.zip.</p>
<p>.*** Error code 1</p>
<p>Stop in /usr/ports/java/diablo-jdk15.</p></blockquote>
<p>Ok, so we need to get the files manually.  The first file is easy to pick up.  The Timezone update is not as you are forced to register an account with Sun.  No biggie really, just a bit of a pain.</p>
<p>FTP/SFTP these two files to your /usr/ports/distfiles and we&#8217;re ready to continue:</p>
<blockquote><p> cd /usr/ports/java/diablo-jdk15 &amp;&amp; make install clean</p></blockquote>
<p>Make sure you enable the TZUPDATE option.  This took about 15 minutes on my box, but might take longer on yours.  Go get something to eat or get a coffee.</p>
<p>If that suceeded, then you&#8217;re already half way there!  Now it&#8217;s time to actually install JBoss itself&#8230;&#8230;</p>
<blockquote><p> cd /usr/ports/java/jboss4 &amp;&amp; make install clean</p></blockquote>
<p>Wait for that to build.</p>
<p>There&#8217;s a couple of configuration changes you&#8217;ll need to make if you want it to a.Work b.Work on the network.</p>
<p>Edit /usr/local/jboss4/bin/run.conf and setup the JAVA_HOME variable to equal &#8220;/usr/local/diablo-jdk1.5.0/&#8221; so it can find Java where FreeBSD installs it.  In this file you can also add extra classpaths, configure memory allocations etc.</p>
<p>Out of the box, JBoss uses port 8080.  To change that, edit the file  /usr/local/jboss4/server/default/deploy/http-invoker.sar/META-INF/jboss-service.xml<br />
Search for 8080 and replace it with whatever port number you want to use.</p>
<p>Starting JBoss is simple:</p>
<blockquote><p>/usr/local/jboss4/bin/run.sh</p></blockquote>
<p>Starting JBoss binded to an ip other that 127.0.0.1 is simple also:</p>
<blockquote><p>/usr/local/jboss4/bin/run.sh -b 192.168.0.1 (or whatever ip you&#8217;re using)</p></blockquote>
]]></content:encoded>
			<wfw:commentRss>http://www.freebsdguy.co.uk/2007/09/19/jboss-4-application-server-freebsd-6/feed/</wfw:commentRss>
		</item>
	</channel>
</rss>
