<?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>Insane Theory - The blog of James Netherton</title>
	<atom:link href="http://www.jamesnetherton.com/blog/feed/" rel="self" type="application/rss+xml" />
	<link>http://www.jamesnetherton.com/blog</link>
	<description>My view on web technology, programming and life</description>
	<lastBuildDate>Thu, 29 Apr 2010 20:24:15 +0000</lastBuildDate>
	<generator>http://wordpress.org/?v=2.9.2</generator>
	<language>en</language>
	<sy:updatePeriod>hourly</sy:updatePeriod>
	<sy:updateFrequency>1</sy:updateFrequency>
			<item>
		<title>Ant filterset breaks binary files</title>
		<link>http://www.jamesnetherton.com/blog/2010/04/29/ant-filterset-breaks-binary-files/</link>
		<comments>http://www.jamesnetherton.com/blog/2010/04/29/ant-filterset-breaks-binary-files/#comments</comments>
		<pubDate>Thu, 29 Apr 2010 20:21:50 +0000</pubDate>
		<dc:creator>James Netherton</dc:creator>
				<category><![CDATA[Ant]]></category>

		<guid isPermaLink="false">http://www.jamesnetherton.com/blog/?p=180</guid>
		<description><![CDATA[I encountered a problem with an Ant build that was some how corrupting a bunch of war files that were being copied into a working directory in order to build an RPM package. I couldn&#8217;t work out how this was happening until I noticed the &#60;filterset&#62; ant tag was being used.
Filtersets allow special tokens in [...]]]></description>
			<content:encoded><![CDATA[<p>I encountered a problem with an Ant build that was some how corrupting a bunch of war files that were being copied into a working directory in order to build an RPM package. I couldn&#8217;t work out how this was happening until I noticed the &lt;filterset&gt; ant tag was being used.</p>
<p>Filtersets allow special tokens in text files to be replaced with a specified value. The Ant documentation on filtersets contains the following note:</p>
<p><em>When a filterset is used in an operation, the files are processed in text mode and the filters applied line by line.<strong> This means that the copy operations will typically corrupt binary files</strong>.</em></p>
<p>Here&#8217;s an example which demonstrates the problem&#8230;&#8230;</p>
<p>A basic directory structure with a mixture of text and binary files:</p>
<p><img src="http://www.jamesnetherton.com/blog/wp-content/uploads/anttest.png" alt="Example Directory Structure" /></p>
<p>The myText.txt file contains some tokens that we&#8217;ll get Ant to replace at build time using a filterset:</p>
<pre class="syntax-highlight:py">
@FOO@
@BAR@
</pre>
<p>Now for the Ant script:</p>
<pre class="syntax-highlight:xml">
&lt;?xml version=&quot;1.0&quot;?&gt;
&lt;project default=&quot;init&quot;&gt;
	&lt;property name=&quot;sourcedir&quot; value=&quot;source&quot;/&gt;
	&lt;property name=&quot;targetdir&quot; value=&quot;target&quot;/&gt;

	&lt;target name=&quot;init&quot; depends=&quot;clean&quot;&gt;
		&lt;mkdir dir=&quot;${targetdir}&quot;/&gt;
		&lt;copy todir=&quot;${targetdir}&quot;&gt;
			&lt;fileset dir=&quot;${sourcedir}&quot;/&gt;
			&lt;filterset&gt;
				&lt;filter token=&quot;FOO&quot; value=&quot;Foo&quot;/&gt;
				&lt;filter token=&quot;BAR&quot; value=&quot;Bar&quot;/&gt;
			&lt;/filterset&gt;
		&lt;/copy&gt;
	&lt;/target&gt;

	&lt;target name=&quot;clean&quot;&gt;
		&lt;delete dir=&quot;${targetdir}&quot;/&gt;
	&lt;/target&gt;
&lt;/project&gt;
</pre>
<p>Simple stuff here. I copy the contents of one directory (source) to another (target) whilst using a filterset to replace tokens FOO and BAR.</p>
<p>Run the script and as expected the tokens in myText.txt have been replaced with the text Foo and Bar. Now I try to extract the contents of any of my war files and I get a message like the one described below, proving that it has been corrupted:<br />
<em><br />
missing 3232546307 bytes in zipfile</em></p>
<p>The simple fix for this is to apply the filterset only to the specific files that require it.  </p>
]]></content:encoded>
			<wfw:commentRss>http://www.jamesnetherton.com/blog/2010/04/29/ant-filterset-breaks-binary-files/feed/</wfw:commentRss>
		<slash:comments>0</slash:comments>
		</item>
		<item>
		<title>Problem mounting cfis share with ubuntu : cifs_mount failed w/return code = -22</title>
		<link>http://www.jamesnetherton.com/blog/2010/03/31/problem-mounting-cfis-share-with-ubuntu-cifs_mount-failed-wreturn-code-22/</link>
		<comments>http://www.jamesnetherton.com/blog/2010/03/31/problem-mounting-cfis-share-with-ubuntu-cifs_mount-failed-wreturn-code-22/#comments</comments>
		<pubDate>Wed, 31 Mar 2010 20:13:02 +0000</pubDate>
		<dc:creator>James Netherton</dc:creator>
				<category><![CDATA[Linux]]></category>

		<guid isPermaLink="false">http://www.jamesnetherton.com/blog/?p=177</guid>
		<description><![CDATA[I was trying to mount a network share in Ubuntu but it kept failing. dmesg was reporting:
CIFS VFS: cifs_mount failed w/return code = -22 
Return code 22 is &#8216;Bad Argument&#8217; which was weird since my mount command syntax seemed fine. In the end I fixed the problem by installing the smbfs package:
sudo apt-get install smbfs
I&#8217;m [...]]]></description>
			<content:encoded><![CDATA[<p>I was trying to mount a network share in Ubuntu but it kept failing. dmesg was reporting:</p>
<p><strong>CIFS VFS: cifs_mount failed w/return code = -22 </strong></p>
<p>Return code 22 is &#8216;Bad Argument&#8217; which was weird since my mount command syntax seemed fine. In the end I fixed the problem by installing the smbfs package:</p>
<p><strong>sudo apt-get install smbfs</strong></p>
<p>I&#8217;m not entirely sure how this fixed the problem, I guess I was missing something on my setup&#8230;..</p>
]]></content:encoded>
			<wfw:commentRss>http://www.jamesnetherton.com/blog/2010/03/31/problem-mounting-cfis-share-with-ubuntu-cifs_mount-failed-wreturn-code-22/feed/</wfw:commentRss>
		<slash:comments>0</slash:comments>
		</item>
		<item>
		<title>Windows Vista wireless network configuration with hidden SSID</title>
		<link>http://www.jamesnetherton.com/blog/2010/01/17/windows-vista-wireless-network-configuration-with-hidden-ssid/</link>
		<comments>http://www.jamesnetherton.com/blog/2010/01/17/windows-vista-wireless-network-configuration-with-hidden-ssid/#comments</comments>
		<pubDate>Sun, 17 Jan 2010 12:58:32 +0000</pubDate>
		<dc:creator>James Netherton</dc:creator>
				<category><![CDATA[Windows]]></category>

		<guid isPermaLink="false">http://www.jamesnetherton.com/blog/?p=174</guid>
		<description><![CDATA[I&#8217;ve been spending some time trying to get a Laptop running Windows Vista connected to a wireless network where the SSID is not being broadcast. I tried all kinds of different security settings but nothing was working. I then stumbled across the solution in this article:
Non-broadcast Wireless Networks with Microsoft Windows 
When configuring the network [...]]]></description>
			<content:encoded><![CDATA[<p>I&#8217;ve been spending some time trying to get a Laptop running Windows Vista connected to a wireless network where the SSID is not being broadcast. I tried all kinds of different security settings but nothing was working. I then stumbled across the solution in this article:</p>
<p><a href="http://technet.microsoft.com/en-us/library/bb726942.aspx">Non-broadcast Wireless Networks with Microsoft Windows </a></p>
<p>When configuring the network ensure that the &#8216;Connect even if the network is not broadcasting&#8217; option is checked. Can&#8217;t believe that I never thought of trying that &#8211; seems so obvious in hindsight!</p>
]]></content:encoded>
			<wfw:commentRss>http://www.jamesnetherton.com/blog/2010/01/17/windows-vista-wireless-network-configuration-with-hidden-ssid/feed/</wfw:commentRss>
		<slash:comments>0</slash:comments>
		</item>
		<item>
		<title>Tomcat shutdown.sh leaves server running</title>
		<link>http://www.jamesnetherton.com/blog/2010/01/12/tomcat-shutdown-sh-leaves-server-running/</link>
		<comments>http://www.jamesnetherton.com/blog/2010/01/12/tomcat-shutdown-sh-leaves-server-running/#comments</comments>
		<pubDate>Tue, 12 Jan 2010 19:21:45 +0000</pubDate>
		<dc:creator>James Netherton</dc:creator>
				<category><![CDATA[Java]]></category>

		<guid isPermaLink="false">http://www.jamesnetherton.com/blog/?p=170</guid>
		<description><![CDATA[If you&#8217;ve been using Tomcat&#8217;s shutdown.sh script and find that Tomcat hasn&#8217;t stopped, it&#8217;s probably because there are some non daemon threads still running. The JVM will not shut down until there are no active non daemon threads.
Try the following to diagnose and resolve the problem&#8230;.
Find Tomcat&#8217;s process id:
ps -ef &#124; grep tomcat
Now kill the [...]]]></description>
			<content:encoded><![CDATA[<p>If you&#8217;ve been using Tomcat&#8217;s shutdown.sh script and find that Tomcat hasn&#8217;t stopped, it&#8217;s probably because there are some non daemon threads still running. The JVM will not shut down until there are no active non daemon threads.</p>
<p>Try the following to diagnose and resolve the problem&#8230;.</p>
<p>Find Tomcat&#8217;s process id:</p>
<p><code>ps -ef | grep tomcat</code></p>
<p>Now kill the Tomcat process using the -3 flag (SIGQUIT signal) to force a thread dump:</p>
<p><code>kill -3 tomcat process id number goes here</code></p>
<p>Once the process has stopped take a look at the tomcat log file. You should see some thread dumps which will help to identify the application and code that is hanging on to threads.</p>
]]></content:encoded>
			<wfw:commentRss>http://www.jamesnetherton.com/blog/2010/01/12/tomcat-shutdown-sh-leaves-server-running/feed/</wfw:commentRss>
		<slash:comments>0</slash:comments>
		</item>
		<item>
		<title>Ubuntu Ant FTP task NoClassDefFoundError</title>
		<link>http://www.jamesnetherton.com/blog/2010/01/02/ubuntu-ant-ftp-task-noclassdeffounderror/</link>
		<comments>http://www.jamesnetherton.com/blog/2010/01/02/ubuntu-ant-ftp-task-noclassdeffounderror/#comments</comments>
		<pubDate>Sat, 02 Jan 2010 13:10:04 +0000</pubDate>
		<dc:creator>James Netherton</dc:creator>
				<category><![CDATA[Ant]]></category>
		<category><![CDATA[Java]]></category>

		<guid isPermaLink="false">http://www.jamesnetherton.com/blog/?p=167</guid>
		<description><![CDATA[I came across a problem when trying to use the Ant FTP task on Ubuntu. Whenever I tried executing my build file I kept getting:
java.lang.ClassNotFoundException: org.apache.commons.net.ftp.FTPClientConfig
The simple fix is to make sure Ant can find the Apache commons-net Jar, either from under the Ant lib directory or in a custom location.
I installed Ant using Aptitude [...]]]></description>
			<content:encoded><![CDATA[<p>I came across a problem when trying to use the Ant FTP task on Ubuntu. Whenever I tried executing my build file I kept getting:</p>
<p><code>java.lang.ClassNotFoundException: org.apache.commons.net.ftp.FTPClientConfig</code></p>
<p>The simple fix is to make sure Ant can find the Apache commons-net Jar, either from under the Ant lib directory or in a custom location.</p>
<p>I installed Ant using Aptitude which places all of the shared Ant jars in /usr/share/ant/lib. I was confused because there was a symbolic link to ant-commons-net.jar which I thought should contain the missing classes. Turns out this Jar is actually the Ant FTP task library, you still need to <a href="http://commons.apache.org/net/">download the commons-net</a> Jar file.</p>
]]></content:encoded>
			<wfw:commentRss>http://www.jamesnetherton.com/blog/2010/01/02/ubuntu-ant-ftp-task-noclassdeffounderror/feed/</wfw:commentRss>
		<slash:comments>1</slash:comments>
		</item>
		<item>
		<title>When should I use kill -9 ?</title>
		<link>http://www.jamesnetherton.com/blog/2009/11/11/when-should-i-use-kill-9/</link>
		<comments>http://www.jamesnetherton.com/blog/2009/11/11/when-should-i-use-kill-9/#comments</comments>
		<pubDate>Wed, 11 Nov 2009 21:05:23 +0000</pubDate>
		<dc:creator>James Netherton</dc:creator>
				<category><![CDATA[Linux]]></category>

		<guid isPermaLink="false">http://www.jamesnetherton.com/blog/?p=162</guid>
		<description><![CDATA[When should I use kill -9 ?
The answer is &#8211; Rarely! Or at least only in exceptional circumstances&#8230;..
The -9 signal is the KILL signal which forces a process to immediately terminate. Many processes perform clean up operations when they terminate, perhaps to close open files, remove temporary files &#038; directories etc. Using the -9 signal [...]]]></description>
			<content:encoded><![CDATA[<p>When should I use kill -9 ?</p>
<p>The answer is &#8211; Rarely! Or at least only in exceptional circumstances&#8230;..</p>
<p>The -9 signal is the KILL signal which forces a process to immediately terminate. Many processes perform clean up operations when they terminate, perhaps to close open files, remove temporary files &#038; directories etc. Using the -9 signal prevents a process from executing any of its shut down hooks and could potentially leave your application / system in an inconsistent state.</p>
<p>If a process needs to be killed, it&#8217;s often better to use the kill command on its own or use kill -15 (-15 is usually the default signal) which sends the TERM signal to the process. The TERM signal tells a process to gracefully terminate which means it will be able to run any shut down hooks and thus leave your system in a potentially nicer state than it would have been if you&#8217;d have used kill -9.</p>
<p>I see kill -9 used in so many inappropriate circumstances, such as in scripts to stop some service or application. Kill -9 should never be used in such cases.</p>
<p>The *nix man pages have a good overview of the kill command. You can also get a list of all kill signals by executing kill -l.</p>
]]></content:encoded>
			<wfw:commentRss>http://www.jamesnetherton.com/blog/2009/11/11/when-should-i-use-kill-9/feed/</wfw:commentRss>
		<slash:comments>1</slash:comments>
		</item>
		<item>
		<title>Upgrade to Ubuntu 9.10 leaves Hue setting at -1000</title>
		<link>http://www.jamesnetherton.com/blog/2009/10/30/upgrade-to-ubuntu-9-10-leaves-hue-setting-at-1000/</link>
		<comments>http://www.jamesnetherton.com/blog/2009/10/30/upgrade-to-ubuntu-9-10-leaves-hue-setting-at-1000/#comments</comments>
		<pubDate>Fri, 30 Oct 2009 20:46:17 +0000</pubDate>
		<dc:creator>James Netherton</dc:creator>
				<category><![CDATA[Linux]]></category>

		<guid isPermaLink="false">http://www.jamesnetherton.com/blog/?p=158</guid>
		<description><![CDATA[After a few Google searches on this, it seems like this issue is cropping up for people with Nvidia cards&#8230;..
I upgraded Ubuntu to 9.10 and found that all of my video content was being displayed with many of the colours totally messed up &#8211; pink sky and green skins on people!
For some reason the Hue [...]]]></description>
			<content:encoded><![CDATA[<p>After a few Google searches on this, it seems like this issue is cropping up for people with Nvidia cards&#8230;..</p>
<p>I upgraded Ubuntu to 9.10 and found that all of my video content was being displayed with many of the colours totally messed up &#8211; pink sky and green skins on people!</p>
<p>For some reason the Hue graphics setting was set to -1000. To fix it, I corrected the setting via the graphics preferences in the Totem media player and everything looked fine afterwards.</p>
]]></content:encoded>
			<wfw:commentRss>http://www.jamesnetherton.com/blog/2009/10/30/upgrade-to-ubuntu-9-10-leaves-hue-setting-at-1000/feed/</wfw:commentRss>
		<slash:comments>0</slash:comments>
		</item>
		<item>
		<title>Fixing Firefox Problem &#8211; Firefox is already running but is not responding</title>
		<link>http://www.jamesnetherton.com/blog/2009/09/01/fixing-firefox-problem-firefox-is-already-running-but-is-not-responding/</link>
		<comments>http://www.jamesnetherton.com/blog/2009/09/01/fixing-firefox-problem-firefox-is-already-running-but-is-not-responding/#comments</comments>
		<pubDate>Tue, 01 Sep 2009 19:02:47 +0000</pubDate>
		<dc:creator>James Netherton</dc:creator>
				<category><![CDATA[FireFox]]></category>

		<guid isPermaLink="false">http://www.jamesnetherton.com/blog/?p=155</guid>
		<description><![CDATA[If you start Firefox and you&#8217;re presented with the message &#8220;Firefox is already running, but is not responding. To open a new window, you must first close the existing Firefox process, or restart your system&#8221; don&#8217;t panic!
I found the simple solution was to start Firefox via the profile manager which prevented the message from showing [...]]]></description>
			<content:encoded><![CDATA[<p>If you start Firefox and you&#8217;re presented with the message &#8220;<em>Firefox is already running, but is not responding. To open a new window, you must first close the existing Firefox process, or restart your system</em>&#8221; don&#8217;t panic!</p>
<p>I found the simple solution was to start Firefox via the profile manager which prevented the message from showing up again. To start Firefox from the profile manager simply execute the command below and choose your default browsing profile.</p>
<p><em>firefox -profilemanager</em></p>
]]></content:encoded>
			<wfw:commentRss>http://www.jamesnetherton.com/blog/2009/09/01/fixing-firefox-problem-firefox-is-already-running-but-is-not-responding/feed/</wfw:commentRss>
		<slash:comments>0</slash:comments>
		</item>
		<item>
		<title>Connecting JConsole To Eclipse</title>
		<link>http://www.jamesnetherton.com/blog/2009/08/17/connecting-jconsole-to-eclipse/</link>
		<comments>http://www.jamesnetherton.com/blog/2009/08/17/connecting-jconsole-to-eclipse/#comments</comments>
		<pubDate>Mon, 17 Aug 2009 19:43:51 +0000</pubDate>
		<dc:creator>James Netherton</dc:creator>
				<category><![CDATA[Java]]></category>

		<guid isPermaLink="false">http://www.jamesnetherton.com/blog/?p=153</guid>
		<description><![CDATA[Ever wanted to connect JConsole to an application that has been launched by Eclipse???
It&#8217;s quite simple to do. Just ensure you pass the following JVM argument when launching the application&#8230;..
-Dcom.sun.management.jmxremote
Start JConsole and you should get the option of connecting the the application you launched from Eclipse.
]]></description>
			<content:encoded><![CDATA[<p>Ever wanted to connect JConsole to an application that has been launched by Eclipse???</p>
<p>It&#8217;s quite simple to do. Just ensure you pass the following JVM argument when launching the application&#8230;..</p>
<p>-Dcom.sun.management.jmxremote</p>
<p>Start JConsole and you should get the option of connecting the the application you launched from Eclipse.</p>
]]></content:encoded>
			<wfw:commentRss>http://www.jamesnetherton.com/blog/2009/08/17/connecting-jconsole-to-eclipse/feed/</wfw:commentRss>
		<slash:comments>0</slash:comments>
		</item>
		<item>
		<title>ColdFusion 9 ORM Problem &#8211; java.lang.NoClassDefFoundError: javax/transaction/Synchronization</title>
		<link>http://www.jamesnetherton.com/blog/2009/07/21/coldfusion-9-orm-problem-javalangnoclassdeffounderror-javaxtransactionsynchronization/</link>
		<comments>http://www.jamesnetherton.com/blog/2009/07/21/coldfusion-9-orm-problem-javalangnoclassdeffounderror-javaxtransactionsynchronization/#comments</comments>
		<pubDate>Tue, 21 Jul 2009 19:59:43 +0000</pubDate>
		<dc:creator>James Netherton</dc:creator>
				<category><![CDATA[ColdFusion]]></category>

		<guid isPermaLink="false">http://www.jamesnetherton.com/blog/?p=150</guid>
		<description><![CDATA[I have the CF9 Beta deployed as a WAR file under Tomcat 6. I was trying to test out the ORM stuff and hit a strange problem. Whenever I tried to call any of the CF ORM functions, the request would suddenly die. Looking at the application server logs I noticed lots of entries like:
java.lang.NoClassDefFoundError: [...]]]></description>
			<content:encoded><![CDATA[<p>I have the CF9 Beta deployed as a WAR file under Tomcat 6. I was trying to test out the ORM stuff and hit a strange problem. Whenever I tried to call any of the CF ORM functions, the request would suddenly die. Looking at the application server logs I noticed lots of entries like:</p>
<p>java.lang.NoClassDefFoundError: javax/transaction/Synchronization </p>
<p>For some reason I didn&#8217;t seem to have jta.jar (required library for Hibernate), so I added it manually to the CF lib directory and everything started working properly.</p>
<p>Wonder if anyone else has had this problem???</p>
]]></content:encoded>
			<wfw:commentRss>http://www.jamesnetherton.com/blog/2009/07/21/coldfusion-9-orm-problem-javalangnoclassdeffounderror-javaxtransactionsynchronization/feed/</wfw:commentRss>
		<slash:comments>0</slash:comments>
		</item>
	</channel>
</rss>
