<?xml version="1.0" encoding="UTF-8"?>
<?xml-stylesheet href="http://feeds.feedburner.com/~d/styles/rss2full.xsl" type="text/xsl" media="screen"?><?xml-stylesheet href="http://feeds.feedburner.com/~d/styles/itemcontent.css" type="text/css" media="screen"?><rss 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:feedburner="http://rssnamespace.org/feedburner/ext/1.0" version="2.0">

<channel>
	<title>Journal of Tormod Haugen</title>
	
	<link>http://journal.tormodh.net</link>
	<description>Thoughts on life, work and technology</description>
	<pubDate>Wed, 03 Dec 2008 10:21:20 +0000</pubDate>
	<generator>http://wordpress.org/?v=2.5</generator>
	<language>en</language>
			<atom10:link xmlns:atom10="http://www.w3.org/2005/Atom" rel="self" href="http://feeds.feedburner.com/tormodh" type="application/rss+xml" /><item>
		<title>Is coffee its own religion?</title>
		<link>http://feeds.feedburner.com/~r/tormodh/~3/473463796/</link>
		<comments>http://journal.tormodh.net/2008/12/03/is-coffee-its-own-religion/#comments</comments>
		<pubDate>Wed, 03 Dec 2008 10:21:20 +0000</pubDate>
		<dc:creator>tormodh</dc:creator>
		
		<category><![CDATA[Life]]></category>

		<category><![CDATA[coffee]]></category>

		<category><![CDATA[haugesund]]></category>

		<category><![CDATA[pioneer church]]></category>

		<category><![CDATA[religion]]></category>

		<category><![CDATA[totalen]]></category>

		<guid isPermaLink="false">http://journal.tormodh.net/?p=141</guid>
		<description><![CDATA[
Today the local newspaper wrote a piece about my favorite local coffee bar. It was really positive, as it well as it should be.
The coffee bar is run by the Pioneer church, a liberal Christian congregation. They have a passion for God, coffee and culture, and is something I as an agnostic really appreciate in [...]]]></description>
			<content:encoded><![CDATA[<p style="display:block;float:right;padding:0 0 .5em .5em;"><a href="http://picasaweb.google.no/lh/photo/gKEZcPVvsRZnmZpq1XCv0g"><img src="http://lh3.ggpht.com/_VnK2G6RKkZc/SAw575FXQ1I/AAAAAAAAAPs/Qevd2zm7h_k/s288/DSC00318.jpg" alt="" title="Black coffee at Totalen" width="216" height="288" class="aligncenter size-medium wp-image-125" /></a></p>
<p>Today the local newspaper <a href="http://www.haugesunds-avis.no/apps/pbcs.dll/article?AID=/20081202/PULS/31481153/1058/AKTUELT&#038;nocache=1">wrote a piece</a> about my <a href="http://cafe.totalen.no/">favorite local coffee bar</a>. It was really positive, as it well as it should be.</p>
<p>The coffee bar is run by the <a href="http://pionerkirken.totalen.no/">Pioneer church</a>, a liberal Christian congregation. They have a passion for God, coffee and culture, and is something I as an agnostic really appreciate in a church. <q>Not sure what you belive? Come to us, we won&#8217;t pressure you.</q> is what they say, and even then the coffee bar is even more open. It&#8217;s just a regular place with jazz, pop, rock and classical music in the air, mingling with the sweet smell of coffees and food.</p>
<p><q cite="http://pionerkirken.totalen.no/" title="Translated fairly verbatim">Not all who seek are comfortable with the brand of <q>Christian</q>, and that&#8217;s ok; it isn&#8217;t really the point. You choose your own way when seeking God. Call yourself whatever you want!</q></p>
<p>But then again; (almost) all who meet at <a href="http://totalen.no/">Totalen</a>, for that is the name of the building of old, love and enjoy coffee. Or the company. Isn&#8217;t then coffee almost it&#8217;s own religion? Or just a gateway leading to people that seek the same as you do?</p>
<p>If you drop by Haugesund and have time for a cup, why not drop by? Just ask anyone <a href="http://maps.google.com/maps?f=q&#038;hl=en&#038;geocode=&#038;q=Haraldsgt+173.,+Haugesund,+Norway&#038;sll=37.0625,-95.677068&#038;sspn=55.060677,114.257812&#038;ie=UTF8&#038;z=16&#038;iwloc=addr">where Totalen lies</a>. They&#8217;ll know.</p>
]]></content:encoded>
			<wfw:commentRss>http://journal.tormodh.net/2008/12/03/is-coffee-its-own-religion/feed/</wfw:commentRss>
		<feedburner:origLink>http://journal.tormodh.net/2008/12/03/is-coffee-its-own-religion/</feedburner:origLink></item>
		<item>
		<title>The hardware race in computers</title>
		<link>http://feeds.feedburner.com/~r/tormodh/~3/468671436/</link>
		<comments>http://journal.tormodh.net/2008/11/28/the-hardware-race-in-computers/#comments</comments>
		<pubDate>Fri, 28 Nov 2008 20:19:47 +0000</pubDate>
		<dc:creator>tormodh</dc:creator>
		
		<category><![CDATA[Life]]></category>

		<category><![CDATA[ati]]></category>

		<category><![CDATA[computer]]></category>

		<category><![CDATA[crashes]]></category>

		<category><![CDATA[dust]]></category>

		<category><![CDATA[graphics]]></category>

		<category><![CDATA[trouble]]></category>

		<guid isPermaLink="false">http://journal.tormodh.net/?p=140</guid>
		<description><![CDATA[I&#8217;ve had my computer crash a lot on me recently. More and more often, and I finally caved in, pulled it out on the floor and opened it. Two questions hit me:

What is the cause of these crashed?
Is that a used vacuum cleaner filter, or the fan of my graphics card?

&#8230;
Right. At least I hope [...]]]></description>
			<content:encoded><![CDATA[<p>I&#8217;ve had my computer crash a lot on me recently. More and more often, and I finally caved in, pulled it out on the floor and opened it. Two questions hit me:</p>
<ol>
<li>What is the cause of these crashed?</li>
<li>Is that a used vacuum cleaner filter, or the fan of my graphics card?</li>
</ol>
<p>&#8230;</p>
<p>Right. At least I hope that was the problem. I guess the next few days will show if it was that or still is a problem. My new card is a big, fanless monster I inherited. It&#8217;s better than the one I picked out of the computer. Really looking forward to see if it changes my experience in games.</p>
<p>Beaut of an ATI 9800 pro; it even required a separate power chord.</p>
<p>I really should think about adopting a new box.</p>
]]></content:encoded>
			<wfw:commentRss>http://journal.tormodh.net/2008/11/28/the-hardware-race-in-computers/feed/</wfw:commentRss>
		<feedburner:origLink>http://journal.tormodh.net/2008/11/28/the-hardware-race-in-computers/</feedburner:origLink></item>
		<item>
		<title>November</title>
		<link>http://feeds.feedburner.com/~r/tormodh/~3/468232075/</link>
		<comments>http://journal.tormodh.net/2008/11/28/november/#comments</comments>
		<pubDate>Fri, 28 Nov 2008 10:48:18 +0000</pubDate>
		<dc:creator>tormodh</dc:creator>
		
		<category><![CDATA[Life]]></category>

		<category><![CDATA[blog]]></category>

		<category><![CDATA[hiatus]]></category>

		<category><![CDATA[irc]]></category>

		<guid isPermaLink="false">http://journal.tormodh.net/?p=139</guid>
		<description><![CDATA[
Then again; there probably should be a better title for this blog post. I was hooked into irc with some Norwegian bloggers today, and I realized that I didn&#8217;t have a blog post since early October, and that time was running out.
I promise to blog more this evening. Promise! 
]]></description>
			<content:encoded><![CDATA[<p style="display:block;float:right;padding:0 0 .5em .5em;"><a href="http://picasaweb.google.no/lh/photo/aeH07mMBMUGnND30--DOuw"><img src="http://lh3.ggpht.com/_VnK2G6RKkZc/SS-vbkclLrI/AAAAAAAABFY/N3BJ8nu8PbQ/s144/irssi-som-klient.jpg" alt="" title="irssi as irc client" width="254" height="124" class="aligncenter size-medium wp-image-125" /></a></p>
<p>Then again; there probably should be a better title for this blog post. I was hooked into irc with some Norwegian bloggers today, and I realized that I didn&#8217;t have a blog post since early October, and that time was running out.</p>
<p>I promise to blog more this evening. Promise! <img src='http://journal.tormodh.net/wp-includes/images/smilies/icon_smile.gif' alt=':)' class='wp-smiley' /></p>
]]></content:encoded>
			<wfw:commentRss>http://journal.tormodh.net/2008/11/28/november/feed/</wfw:commentRss>
		<feedburner:origLink>http://journal.tormodh.net/2008/11/28/november/</feedburner:origLink></item>
		<item>
		<title>What I learned from playing Fallout</title>
		<link>http://feeds.feedburner.com/~r/tormodh/~3/414111836/</link>
		<comments>http://journal.tormodh.net/2008/10/07/what-i-learned-from-playing-fallout/#comments</comments>
		<pubDate>Tue, 07 Oct 2008 19:58:23 +0000</pubDate>
		<dc:creator>tormodh</dc:creator>
		
		<category><![CDATA[Games]]></category>

		<category><![CDATA[fallout]]></category>

		<category><![CDATA[fallout 2]]></category>

		<category><![CDATA[rope]]></category>

		<guid isPermaLink="false">http://journal.tormodh.net/?p=137</guid>
		<description><![CDATA[I got through Fallout, ready to start on Fallout 2. During the game, which I played as a intelligent person with a knack for hitting where it hurts, I learned (or re-learned) some things:

As in all RPG&#8217;s, carry a 10 foot pole and 50 feet worth of rope at all times.

Since Fallout hasn&#8217;t got a [...]]]></description>
			<content:encoded><![CDATA[<p>I got through Fallout, ready to start on Fallout 2. During the game, which I played as a intelligent person with a knack for hitting where it hurts, I learned (or re-learned) some things:</p>
<ol>
<li>As in all RPG&#8217;s, carry a 10 foot pole and 50 feet worth of rope at all times.
<ul>
<li>Since Fallout hasn&#8217;t got a 10 foot pole, carry two pieces of rope.</li>
</ul>
</li>
<li>Don&#8217;t turn your back to anyone wielding a automatic weapon. Ever. Just run.
<ul>
<li>Unless your enemies are the ones wielding the hardware, and you are exceptionally well insulated against lead. Then go stand by those less likely to survive the hailstorm.</li>
</ul>
</li>
<li>Don&#8217;t play too much chess, it is bad for your health</li>
<li>Don&#8217;t let out the prisoners under the Cathedral. Please. Please&#8230;</li>
</ol>
<p>Anything worth adding?</p>
]]></content:encoded>
			<wfw:commentRss>http://journal.tormodh.net/2008/10/07/what-i-learned-from-playing-fallout/feed/</wfw:commentRss>
		<feedburner:origLink>http://journal.tormodh.net/2008/10/07/what-i-learned-from-playing-fallout/</feedburner:origLink></item>
		<item>
		<title>Revisiting Fallout - install</title>
		<link>http://feeds.feedburner.com/~r/tormodh/~3/403035190/</link>
		<comments>http://journal.tormodh.net/2008/09/25/revisiting-fallout-install/#comments</comments>
		<pubDate>Thu, 25 Sep 2008 18:34:10 +0000</pubDate>
		<dc:creator>tormodh</dc:creator>
		
		<category><![CDATA[Games]]></category>

		<category><![CDATA[640x480]]></category>

		<category><![CDATA[caves]]></category>

		<category><![CDATA[fallout]]></category>

		<category><![CDATA[fallout2]]></category>

		<category><![CDATA[gog]]></category>

		<category><![CDATA[good old games]]></category>

		<category><![CDATA[high res]]></category>

		<category><![CDATA[nma]]></category>

		<category><![CDATA[patch]]></category>

		<category><![CDATA[radscorpion]]></category>

		<category><![CDATA[radscorpions]]></category>

		<category><![CDATA[shady sands]]></category>

		<category><![CDATA[tim cain]]></category>

		<category><![CDATA[timothy cain]]></category>

		<guid isPermaLink="false">http://journal.tormodh.net/?p=126</guid>
		<description><![CDATA[It is that time again. I delve back into the oasis of great games from the past, looking to find my childhood. Silly, isn&#8217;t it? I carry my childhood with me, hoping to be as good a parent as mine before me.
Spurred by people talking about GOG.com, I managed to get my hands on Fallout [...]]]></description>
			<content:encoded><![CDATA[<p>It is that time again. I delve back into the oasis of great games from the past, looking to find my childhood. Silly, isn&#8217;t it? I carry my childhood with me, hoping to be as good a parent as mine before me.</p>
<p>Spurred by people talking about <a href="http://gog.com" title="Good Old Games">GOG.com</a>, I managed to get my hands on Fallout and Fallout 2, for the price of a cup of coffee and a light lunch at my favorite coffee bar.</p>
<p style="display:block;float:right;padding:0 0 .5em .5em;"><a href='http://journal.tormodh.net/wp-content/uploads/2008/09/timcain.png'><img src="http://journal.tormodh.net/wp-content/uploads/2008/09/timcain.png" alt="Tim Cain as the Fallout icon" title="Timothy Cain in 2304 pixels" width="325" height="54" class="alignnone size-medium wp-image-127" /></a></p>
<p>Download and install went as well as it should, though I was a bit shocked to <a href="http://www.mobygames.com/developer/sheet/view/developerId,2720/" title="Timothy Cain's bio at MobyGames">see Tim Cain</a> as the Fallout icon. This happens for both Fallout and Fallout 2, as his image is hidden in the 48&#215;48 pixel version of the icon. Phew.</p>
<p>I went on the net finding <a href="http://www.nma-fallout.com/forum/viewtopic.php?t=42386" title="Fallout2 High Resolution Patch">high resolution patches</a> for both Fallout and Fallout 2 at <a href="http://www.nma-fallout.com/" title="No Mutants Allowed">NMA</a>. Reading the <em>Readme</em> I installed the patch, knowing I could get it uninstalled by running the patcher again.</p>
<p>I changed the patch&#8217;s ini file to set my resolution to 1280&#215;1024, and started the game. Which crashed with a message that it couldn&#8217;t set resolution to 640&#215;480. A bit of research put the blame on the file <q>ddraw.dll</q> in the game directory. I removed it (by renaming it to <q>ddraw.dll</q>), making the game revert to Windows&#8217; version (installed with DirectX and/or the gfx card drivers?), then it worked just nice. <em>I also read that this was due to ATI drivers - and since <strong>the game works without the high res patch, with the supplied ddraw.dll</strong>, I guess it is supplied to avoid the problem in the first part. Possibly the packaged <q>ddraw.dll</q> allows 640&#215;480 res, breaking the high res patch.</em></p>
<p>A fix sets the color (bit depth) to 16 bits, avoiding a screen blackout bug - this might or might not have been fixed in GOG&#8217;s version of Fallout, but with this set in the patch&#8217;s ini file you won&#8217;t get the loading screens.</p>
<p><strong>Edit:</strong> I also had some problems in the Rad Scorpion caves outside of Shady Sands. When I entered the map, I couldn&#8217;t scroll around, and even the exit area was outside of the screen. <strong>efin</strong> says in the GOG forums:</p>
<blockquote><p>
Also, I don&#8217;t know if anyone else has had this problem, but with the hi-res pack I couldn&#8217;t go anywhere in the radscorpion cave. I could move around the screen, but I couldn&#8217;t scroll to go anywhere else other than the first bit you c an see. It appears to be wrong numbers put into an .ini file.</p>
<p>If you have this problem, go to the &#8220;f1_res&#8221; folder and open &#8220;map_edges_F1.ini&#8221; - in it you&#8217;ll see the edges mapped out by number for each section of the game. Here is what I have for the Caves section:</p>
<p>NAME = CAVES<br />
ELEVATION = 1<br />
LEFT_EDGE = 1568<br />
RIGHT_EDGE = 2540<br />
TOP_EDGE = 1840<br />
BOTTOM_EDGE = 1532</p>
<p>I&#8217;m not sure if these are accurate, but they worked for me. Have fun!
</p></blockquote>
<p>So, now it is time to start the fun.</p>
]]></content:encoded>
			<wfw:commentRss>http://journal.tormodh.net/2008/09/25/revisiting-fallout-install/feed/</wfw:commentRss>
		<feedburner:origLink>http://journal.tormodh.net/2008/09/25/revisiting-fallout-install/</feedburner:origLink></item>
		<item>
		<title>One GOG.com invite code to give away</title>
		<link>http://feeds.feedburner.com/~r/tormodh/~3/402549169/</link>
		<comments>http://journal.tormodh.net/2008/09/25/one-gogcom-invite-code-to-give-away/#comments</comments>
		<pubDate>Thu, 25 Sep 2008 07:06:29 +0000</pubDate>
		<dc:creator>tormodh</dc:creator>
		
		<category><![CDATA[Games]]></category>

		<category><![CDATA[gog]]></category>

		<category><![CDATA[good old games]]></category>

		<category><![CDATA[invite]]></category>

		<category><![CDATA[mart]]></category>

		<guid isPermaLink="false">http://journal.tormodh.net/?p=124</guid>
		<description><![CDATA[
I was so lucky to receive a code from a random passer by, and as I was told I could give one on myself, I thought I&#8217;d pass it on.
Therefore, if anyone would like to try and buy some Good Old Games from GOG.com, feel free to ask me for a invite code. First come, [...]]]></description>
			<content:encoded><![CDATA[<p style="display:block;float:right;padding:0 0 .5em .5em;"><a href='http://journal.tormodh.net/wp-content/uploads/2008/09/gog_special_invite_code.jpg'><img src="http://journal.tormodh.net/wp-content/uploads/2008/09/gog_special_invite_code.jpg" alt="" title="gog_special_invite_code" width="254" height="124" class="aligncenter size-medium wp-image-125" /></a></p>
<p>I was so lucky to receive a code from <a href="http://relek1corner.org/2008/09/24/one-gogcom-invite-code-to-give-away/">a random passer by</a>, and as I was told I could give one on myself, I thought I&#8217;d pass it on.</p>
<p><del datetime="2008-09-25T08:22:52+00:00">Therefore, if anyone would like to try and buy some Good Old Games from GOG.com, feel free to ask me for a invite code. First come, first served.</del> My email address is made up from my handle &#8220;tormodh&#8221; and the domain of Google&#8217;s popular email client - &#8220;gmail.com&#8221;, or you could drop a line in the comments below. Email entered in the field (for email) will not be shown to others than me.</p>
<p><ins datetime="2008-09-25T08:22:52+00:00"><strong>Update: It is given away.</strong></ins></p>
<p>More info (same links as supplied by Mart):</p>
<ul>
<li><a href="http://www.gog.com/">The main Good Old Games site</a></li>
<li><a href="http://www.gamesindustry.biz/articles/old-s-cool">Old’s Cool at gamesindustry.biz</a></li>
<li><a href="http://www.gamesindustry.biz/articles/cd-projekt-publishers-scared-to-go-drm-free">CD Projekt: Publishers “scared” to go DRM-Free</a></li>
</ul>
]]></content:encoded>
			<wfw:commentRss>http://journal.tormodh.net/2008/09/25/one-gogcom-invite-code-to-give-away/feed/</wfw:commentRss>
		<feedburner:origLink>http://journal.tormodh.net/2008/09/25/one-gogcom-invite-code-to-give-away/</feedburner:origLink></item>
		<item>
		<title>Executing native processes from Java</title>
		<link>http://feeds.feedburner.com/~r/tormodh/~3/395199210/</link>
		<comments>http://journal.tormodh.net/2008/09/17/executing-native-processes-from-java/#comments</comments>
		<pubDate>Wed, 17 Sep 2008 13:31:34 +0000</pubDate>
		<dc:creator>tormodh</dc:creator>
		
		<category><![CDATA[Java]]></category>

		<category><![CDATA[coincidence]]></category>

		<category><![CDATA[exec]]></category>

		<category><![CDATA[execute]]></category>

		<category><![CDATA[howto]]></category>

		<category><![CDATA[kua]]></category>

		<category><![CDATA[native process]]></category>

		<category><![CDATA[ProcessBuilder]]></category>

		<category><![CDATA[Runtime]]></category>

		<category><![CDATA[windows]]></category>

		<guid isPermaLink="false">http://journal.tormodh.net/?p=116</guid>
		<description><![CDATA[This is kind of a coincidence. Today I got contacted by a friend, wondering how to run a native Windows program from within Java. I said as I usually do: Google it. Not liking to get that served myself, I did follow up with some real information. I don&#8217;t like being a RTFM slinging jerk, [...]]]></description>
			<content:encoded><![CDATA[<p>This is kind of a coincidence. Today I got contacted by a friend, wondering how to run a native Windows program from within Java. I said as I usually do: <q>Google it</q>. Not liking to get that served myself, I did follow up with some real information. I don&#8217;t like being a <acronym title="Read The Fu..Fine Manual">RTFM</acronym> slinging jerk, but it is fun to sting people you know. <img src='http://journal.tormodh.net/wp-includes/images/smilies/icon_wink.gif' alt=';-)' class='wp-smiley' /> </p>
<p>Googling turned up a <a href="http://www.rgagnon.com/javadetails/java-0014.html" title="Real HowTos: Execute an external program">useful guide</a> to how you can do this, both using <q>Runtime.getRuntime().exec(&#8221;command&#8221;);</q> and with 1.5&#8217;s <q>ProcessBuilder</q>.</p>
<p>Then comes the coincidence; just as I&#8217;m about to leave for home, I scan my feeds - at the top of my <q>Programming</q> folder, Patrick Kua has the following entry: <a href="http://www.thekua.com/atwork/2008/09/17/executing-native-processes-in-java-on-windows/">Executing native processes in Java on Windows</a>.</p>
]]></content:encoded>
			<wfw:commentRss>http://journal.tormodh.net/2008/09/17/executing-native-processes-from-java/feed/</wfw:commentRss>
		<feedburner:origLink>http://journal.tormodh.net/2008/09/17/executing-native-processes-from-java/</feedburner:origLink></item>
		<item>
		<title>Managing Memory in Java</title>
		<link>http://feeds.feedburner.com/~r/tormodh/~3/383593289/</link>
		<comments>http://journal.tormodh.net/2008/09/04/managing-memory-in-java/#comments</comments>
		<pubDate>Thu, 04 Sep 2008 20:50:51 +0000</pubDate>
		<dc:creator>tormodh</dc:creator>
		
		<category><![CDATA[Java]]></category>

		<category><![CDATA[garbage collector]]></category>

		<category><![CDATA[heap]]></category>

		<category><![CDATA[jconsole]]></category>

		<category><![CDATA[leak]]></category>

		<category><![CDATA[memory]]></category>

		<category><![CDATA[OutOfMemoryError]]></category>

		<category><![CDATA[profiler]]></category>

		<guid isPermaLink="false">http://journal.tormodh.net/?p=105</guid>
		<description><![CDATA[
Getting memory management to play along in Java is a whole other chapter than it was in C and C++. And by that I mean simpler and better. Though a few people would still like to allocate and deallocate memory themselves, most agree that garbage collectors are a step forward (afaik). Whatever your stance on [...]]]></description>
			<content:encoded><![CDATA[<p style="display:block;float:right;padding:0 0 .5em .5em;"><a href="http://picasaweb.google.com/tormodh/Doodles#5241310916147375874" title="Fiddling with bugs"><img src="http://lh6.ggpht.com/tormodh/SLzggjJXbwI/AAAAAAAAAx0/9_zUWA8eUbE/s288/DSC00467.jpg" alt="Doodle of a beetle with a fiddle."/></a></p>
<p>Getting memory management to play along in Java is a whole other chapter than it was in C and C++. And by that I mean simpler and better. Though a few people would still like to allocate and deallocate memory themselves, most agree that garbage collectors are a step forward (<acronym title="as far as I know">afaik</acronym>). Whatever your stance on the case, GC is in Java, that&#8217;s the way it is. There are tweaks, and even replacement collectors, to get the garbage collecting to be done in tune with your code.</p>
<p>I&#8217;ll have a look on simpler aspects of managing memory in Java. For one - adding more available (heap) memory for your application. You&#8217;ll usually have need of this if you are writing big, memory hungry programs. Anything gathering and working on large amounts of data. Your hint will come from a thrown exception blaming <q>java.lang.OutOfMemoryError: Java heap space</q>.</p>
<p>Assigning more memory to Java is as easy as supplying one or two parameters to java when starting your program. There is <q>-Xmx=</q> for maximum heap size in bytes, and <q>-Xms=</q> for initial heap size. Since increasing the heap take some resources, it is suggested setting the initial size at something that should be enough for use, and maximum to something that should be enough - period.</p>
<p>These values are specified in bytes, but you could do it in kB or MB by adding a suffix, like this: <q>java -Xms=64m -Xmx=256m MyProgram</q>.</p>
<p>A crash citing the <acronym title="Java Virtual Machine">JVM</acronym> out of memory could also easily be a (dire) warning about you having a memory leak or two in your code. Java isn&#8217;t invulnerable to those, though they are harder to get by accident. One usual suspect are Listeners, setting up a listener and then forgetting about it when the work is done could spell an early end to the session. Misbehaving (self-coded) collections are also a common way of stopping the garbage collectors from doing their work.</p>
<p>Detecting memory leaks are not that easy in Java. Since your program runs in a <acronym>JVM</acronym>, task managers in your OS will not report on your program, but on the virtual machine it is running in. To have a look at how your memory consumption is, you are in need of a <a href="http://www.google.com/search?q=java%20profiler" title="google: java profiler">Java profiler</a> of some kind. An easy alternative is to fire up your program with <q>java -Dcom.sun.management.jmxremote MyProgram</q>, and then running the tool Sun supplies with Java (from 1.5 up): jconsole. This program is located where you have the <acronym title="Java Developement Kit">JDK</acronym> installed - usually <q>C:\Program Files\Java\jdk[version]\bin</q> on Windows.</p>
<p>Happy hunting.</p>
]]></content:encoded>
			<wfw:commentRss>http://journal.tormodh.net/2008/09/04/managing-memory-in-java/feed/</wfw:commentRss>
		<feedburner:origLink>http://journal.tormodh.net/2008/09/04/managing-memory-in-java/</feedburner:origLink></item>
		<item>
		<title>Public Transport</title>
		<link>http://feeds.feedburner.com/~r/tormodh/~3/361783115/</link>
		<comments>http://journal.tormodh.net/2008/08/11/public-transport/#comments</comments>
		<pubDate>Mon, 11 Aug 2008 08:56:55 +0000</pubDate>
		<dc:creator>tormodh</dc:creator>
		
		<category><![CDATA[Life]]></category>

		<category><![CDATA[bergen]]></category>

		<category><![CDATA[bike]]></category>

		<category><![CDATA[bus]]></category>

		<category><![CDATA[fuzzy]]></category>

		<category><![CDATA[fuzzy hair]]></category>

		<category><![CDATA[hair]]></category>

		<category><![CDATA[haugesund]]></category>

		<category><![CDATA[kolumbus]]></category>

		<category><![CDATA[plane]]></category>

		<category><![CDATA[rain]]></category>

		<category><![CDATA[rant]]></category>

		<category><![CDATA[stavanger]]></category>

		<category><![CDATA[train]]></category>

		<category><![CDATA[wait]]></category>

		<category><![CDATA[waiting]]></category>

		<guid isPermaLink="false">http://journal.tormodh.net/?p=78</guid>
		<description><![CDATA[
I feel different about different types of public transport. It all starts with the bus. The bus is something that might or might not be on time. If I am early, it will probably be late, and if I&#8217;m a bit late it will be on time, disappearing down the road as I&#8217;m running for [...]]]></description>
			<content:encoded><![CDATA[<p style="display:block;float:right;padding:0 0 .5em .5em;"><a href="http://picasaweb.google.no/tormodh/Random/photo#5233168166654274546" title="Funky bus hair"><img src="http://lh3.ggpht.com/tormodh/SJ_yuJdPa_I/AAAAAAAAAoM/2-vZuKNQS90/s144/DSC00389.jpg" alt="Hair that is short, fuzzy and bleached. Taken on a bus"/></a></p>
<p>I feel different about different types of public transport. It all starts with the bus. The bus is something that might or might not be on time. If I am early, it will probably be late, and if I&#8217;m a bit late it will be on time, disappearing down the road as I&#8217;m running for the &#8217;stop.</p>
<p>The bus to Bergen is different. It is relaxed. It only goes every other hour, and takes three hours to reach it&#8217;s destination. I have to plan ahead to get on it, because I probably need to sleep over before heading home again. Well, I don&#8217;t take it much now, and earlier it was the other way around. I mean, I took it down to Haugesund, then back (home) to Bergen later - over the weekend or something.</p>
<p>I can read on that bus. When going downtown, a 15 minutes ride, I have to look out for my stop so I don&#8217;t overshoot it. It doesn&#8217;t matter that much, distances aren&#8217;t that great once I arrive, but I don&#8217;t trust those buses. It is easier now; there is a loudspeaker and a sign informing of the next stop in almost every city bus.</p>
<p>The bus company is called Kolumbus, and are based in Stavanger. Stavanger is the next city south of Haugesund, and thus the loudspeaker woman has got an accent (She says <q>Gadå</q> instead of <q>Gata</q> - street). The woman on the picture was spotted on the bus this weekend. She was probably heading downtown to listen to the jazz - Haugesund hosts the <a href="http://en.wikipedia.org/wiki/Sildajazz">Sildajazz</a> festival each year (celebrating the herring. Nope, not the red one&#8230;).</p>
<p>Trains are better. Night trains between Bergen and Hønefoss(Hen (water)Falls - don&#8217;t ask me why) is nice. In the same way as the Express busses, these are plannable, and forces you to be on time. And they are even more precisely on time when you are at (or near) one of the ends. Lots of time to read or work if you take the train by day, and not so much time lost if you sleep on it by night.</p>
<p>Planes on the third hand are a hassle. You have to get to the airport. Check in luggage an get through the security station. Wait. Actually, wait some more - because you had to wait earlier as a consequence of being early. The airways companies require you to be there earlier than you want to. And then you board. And find your seat. And wait. And wait. And you&#8217;ll probably have to switch planes at the next airport; and if one of your flights were international you&#8217;ll collect your luggage and check it in again. And wait. And get away from the airport.</p>
<p>I like trains, but we doesn&#8217;t have one here.</p>
<p>My bike is better than all - for shorter distances. Don&#8217;t want to use it for international travels, though. And it isn&#8217;t much fun in the rain. Or strong headwinds. And it hasn&#8217;t got fuzzy hair in front of me.</p>
]]></content:encoded>
			<wfw:commentRss>http://journal.tormodh.net/2008/08/11/public-transport/feed/</wfw:commentRss>
		<feedburner:origLink>http://journal.tormodh.net/2008/08/11/public-transport/</feedburner:origLink></item>
		<item>
		<title>iTunes stole my podcasts</title>
		<link>http://feeds.feedburner.com/~r/tormodh/~3/358290149/</link>
		<comments>http://journal.tormodh.net/2008/08/07/itunes-stole-my-podcasts/#comments</comments>
		<pubDate>Thu, 07 Aug 2008 10:42:19 +0000</pubDate>
		<dc:creator>tormodh</dc:creator>
		
		<category><![CDATA[Technology]]></category>

		<category><![CDATA[damaged]]></category>

		<category><![CDATA[iPod]]></category>

		<category><![CDATA[itunes]]></category>

		<category><![CDATA[library]]></category>

		<category><![CDATA[podcast]]></category>

		<category><![CDATA[podcasts]]></category>

		<category><![CDATA[troubleshoot]]></category>

		<category><![CDATA[windows]]></category>

		<guid isPermaLink="false">http://journal.tormodh.net/?p=73</guid>
		<description><![CDATA[
Starting my computer to sync my iPod this morning brought on instant Apple hatred. iTunes told me that my iTunes Library were damaged, and just like that my podcast subscriptions were gone. Pffft - not there any more.
I then vented at twitter, being rewarded by someone else having that same problem. iTunes complaining about library [...]]]></description>
			<content:encoded><![CDATA[<p style="display:block;float:right;padding:0 0 .5em .5em;"><a href="http://picasaweb.google.no/tormodh/Havelist/photo?authkey=hDjVUPB5-ok#5166771526471297554" title="This is my iPod. There are many like it, this one is mine"><img src="http://lh5.ggpht.com/tormodh/R7QPVB7sqhI/AAAAAAAAAM4/CWGYiZPXExs/s144/DSC00290.jpg" alt="Black iPod Nano 8GB" /></a></p>
<p>Starting my computer to sync my iPod this morning brought on instant Apple hatred. iTunes told me that my iTunes Library were damaged, and just like that my podcast subscriptions were gone. Pffft - not there any more.</p>
<p>I then <a href="http://twitter.com/tormodh/statuses/880190397">vented at twitter</a>, being rewarded by someone else having that same problem. iTunes complaining about library file on Windows, and podcast subscriptions being lost.</p>
<p>With a flash of insight and a bit of luck, I browsed to where my iTunes library file were located. Taking backup of the new (empty) file, I renamed the one marked with <q>(Damaged)</q> back to it&#8217;s original name, and it all looked just like before when I restarted iTunes.</p>
<p>The files was located in the <q>My Music/iTunes</q> folder - actually <q>/Users/MYNAME/Music/iTunes/</q> on Vista. The relevant file is the one named something with <q>(Damaged)</q>. <small>don&#8217;t blame me if it doesn&#8217;t work.</small> Backup the defunct file first.</p>
<p>Still, I am more and more inclined to try and get my iPod updated without iTunes. Next time, perhaps.</p>
]]></content:encoded>
			<wfw:commentRss>http://journal.tormodh.net/2008/08/07/itunes-stole-my-podcasts/feed/</wfw:commentRss>
		<feedburner:origLink>http://journal.tormodh.net/2008/08/07/itunes-stole-my-podcasts/</feedburner:origLink></item>
	</channel>
</rss><!-- Dynamic Page Served (once) in 2.343 seconds -->
