<?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>Elfstone</title>
	<atom:link href="http://elfstone.nl/feed/" rel="self" type="application/rss+xml" />
	<link>http://elfstone.nl</link>
	<description>Don't believe the hype</description>
	<lastBuildDate>Sun, 06 May 2012 14:13:02 +0000</lastBuildDate>
	<language>en</language>
	<sy:updatePeriod>hourly</sy:updatePeriod>
	<sy:updateFrequency>1</sy:updateFrequency>
	<generator>http://wordpress.org/?v=3.3.2</generator>
		<item>
		<title>Gaki no Tsukai&#8217;s: No Laughing Spy</title>
		<link>http://elfstone.nl/2012/05/06/gaki-no-tsukai-s-no-laughing-spy/</link>
		<comments>http://elfstone.nl/2012/05/06/gaki-no-tsukai-s-no-laughing-spy/#comments</comments>
		<pubDate>Sun, 06 May 2012 14:13:02 +0000</pubDate>
		<dc:creator>michiel</dc:creator>
				<category><![CDATA[Comedy]]></category>
		<category><![CDATA[Japan]]></category>

		<guid isPermaLink="false">http://elfstone.nl/?p=463</guid>
		<description><![CDATA[It&#8217;s been a while since I&#8217;ve seen a Gaku no Tsukai &#8220;No Laughing&#8221; Batsu game, a New Year&#8217;s eve special made by Japanese comedians. I saw the &#8220;No laughing spy&#8221; (aired on the New Year&#8217;s eve of 2010-2011) recently and &#8230; <a href="http://elfstone.nl/2012/05/06/gaki-no-tsukai-s-no-laughing-spy/">Continue reading <span class="meta-nav">&#8594;</span></a>]]></description>
			<content:encoded><![CDATA[<p>It&#8217;s been a while since I&#8217;ve seen a Gaku no Tsukai &#8220;No Laughing&#8221; <a href="http://en.wikipedia.org/wiki/Downtown_no_Gaki_no_Tsukai_ya_Arahende!!#Batsu_Games" title="Batsu games" target="_blank">Batsu game</a>, a New Year&#8217;s eve special made by Japanese comedians. I saw the &#8220;No laughing spy&#8221; (aired on the New Year&#8217;s eve of 2010-2011) recently and wanted to share this happiness.</p>
<p>For those of you who haven&#8217;t heard about this: the comedians that lost a bet (not shown, but aired before) have to reside for 24 hours in a setting where they are confronted with strange situations designed to make them laugh. Each time they laugh, &#8220;punishers&#8221; come out to hit them on the buttocks with an object.</p>
<p>The situations are often funny, sometimes not so, sometimes hilarious, but the thing I like the most is when the comedians make each other laugh (and often themselves too), resulting in even more punishment.</p>
<p>The &#8220;<a href="http://www.veoh.com/find/?query=gnt+no+laughing+spy" title="No Laughing Spy" target="_blank">No laughing spy</a>&#8221; broadcast is almost 5 hours long. It is split up in &#8220;episodes&#8221; of 30 minutes, so you do not have to watch it all in one run (I did). Hope you enjoy!</p>
]]></content:encoded>
			<wfw:commentRss>http://elfstone.nl/2012/05/06/gaki-no-tsukai-s-no-laughing-spy/feed/</wfw:commentRss>
		<slash:comments>0</slash:comments>
		</item>
		<item>
		<title>5.1 audio through Airport Express</title>
		<link>http://elfstone.nl/2012/03/04/5-1-audio-through-airport-express/</link>
		<comments>http://elfstone.nl/2012/03/04/5-1-audio-through-airport-express/#comments</comments>
		<pubDate>Sun, 04 Mar 2012 22:45:06 +0000</pubDate>
		<dc:creator>michiel</dc:creator>
				<category><![CDATA[Audio]]></category>
		<category><![CDATA[Hardware]]></category>

		<guid isPermaLink="false">http://elfstone.nl/?p=389</guid>
		<description><![CDATA[I&#8217;ve always wondered if it is possible to have 5.1 audio through my Airport Express. So is it? Yes it is. How? Once you know it, it&#8217;s deceptively simple: you need three things: 5.1 audio source 5.1 audio capable cable &#8230; <a href="http://elfstone.nl/2012/03/04/5-1-audio-through-airport-express/">Continue reading <span class="meta-nav">&#8594;</span></a>]]></description>
			<content:encoded><![CDATA[<p>I&#8217;ve always wondered if it is possible to have 5.1 audio through my Airport Express. So is it? Yes it is. How? Once you know it, it&#8217;s deceptively simple: you need three things:</p>
<ol>
<li>5.1 audio source</li>
<li>5.1 audio capable cable (e.g. optic fibre)</li>
<li>iTunes (or something else that can output to AirTunes/AirPlay)</li>
</ol>
<p>I used <a href="http://www.diatonis.com/surround_sound_music.html">http://www.diatonis.com/surround_sound_music.html</a> or <a href="http://www.kellyindustries.com/sounds.html">http://www.kellyindustries.com/sounds.html</a> for the 5.1 audio sources (WAV files, iTunes wouldn&#8217;t play the .ac3 files). I borrowed an optic cable (thanks Michele!) with a TOSLINK plug on one side (goes into the receiver) and a Mini-TOSLINK plug on the other side (goes into the Airport Express). The important thing is <strong>to put the volume of iTunes to 100%</strong>.</p>
<p>If the volume of iTunes is not set to a 100%, the receiver will not detect that your source is DTS or DD5.1 (whatever your source is), and will output noise. I guess this is because DTS and DD5.1 should be passed through the receiver unchanged (volume control is done at the very last). I think iTunes doesn&#8217;t handle this gracefully (in my opinion it should output it unchanged no matter what the volume control is set to).</p>
<p>Anyway it does work, so enjoy!</p>
]]></content:encoded>
			<wfw:commentRss>http://elfstone.nl/2012/03/04/5-1-audio-through-airport-express/feed/</wfw:commentRss>
		<slash:comments>0</slash:comments>
		</item>
		<item>
		<title>PSU power usage</title>
		<link>http://elfstone.nl/2010/10/18/psu-power-usage/</link>
		<comments>http://elfstone.nl/2010/10/18/psu-power-usage/#comments</comments>
		<pubDate>Mon, 18 Oct 2010 21:22:04 +0000</pubDate>
		<dc:creator>michiel</dc:creator>
				<category><![CDATA[Hardware]]></category>
		<category><![CDATA[PowerSaving]]></category>

		<guid isPermaLink="false">http://elfstone.nl/?p=354</guid>
		<description><![CDATA[When I was swapping my motherboard in for a different one, I found something interesting. I used my kill-a-watt to measure how much my old motherboard + CPU + memory was using compared to my new (used) one. The hardware &#8230; <a href="http://elfstone.nl/2010/10/18/psu-power-usage/">Continue reading <span class="meta-nav">&#8594;</span></a>]]></description>
			<content:encoded><![CDATA[<p>When I was swapping my motherboard in for a different one, I found something interesting. I used my kill-a-watt to measure how much my old motherboard + CPU + memory was using compared to my new (used) one.</p>
<p><strong>The hardware</strong><br />
I swapped out a Pentium D 930 (yes, I know, old hardware, but it served its purpose) with a Core2Duo T5500. Impressive! The motherboards are nothing impressive (read: I forgot the brand and model), and the only thing noting was the difference in memory: from 2 GB to 4 GB. Other than that, they are pretty similar in performance (I measured with 3DMark2006: 6500-ish vs 7100-ish, respectively).</p>
<p><strong>Interesting!</strong><br />
The interesting thing wasn&#8217;t the power usage difference between them (well, I expected a drop in power usage and got it), <em>but the difference in power usage when I used a 400 W PSU with the new setup compared to a 500 W PSU</em>. For the record, the only thing I changed was the PSU. No settings changed, no other hardware changed. I didn&#8217;t even run windows updates in between them. Unfortunately, I don&#8217;t have the numbers for the D930 with the 500W PSU, because I already swapped it for the other motherboard when I thought about trying that.</p>
<p><strong>The details</strong><br />
In the table below you can see power usage that I measured (it was oscillating a bit sometimes (a few percentage of the total), I took a number that looked average). The activities are: Busy (Battlefield: Bad Company 2, ingame), Idle (Windows desktop, no programs running), Windows Standby (as the name implies), Off (shutdown, cable plugged in).</p>
<style>
#tabel {
 border: 1px solid black;
 border-collapse:collapse;
}
#tabel tr td, #tabel tr th {
 border: 1px solid black;
}
</style>
<p>Anyway, the measurements:</p>
<table id="tabel">
<tr>
<th>Activity</th>
<th>Pentium D 930 400W</th>
<th>C2D T5500 500W</th>
<th>C2D T5500 400W</th>
</tr>
<tr>
<td>Busy</td>
<td>210 W</td>
<td>145 W</td>
<td>120 W</td>
</tr>
<tr>
<td>Idle</td>
<td>133 W</td>
<td>85 W</td>
<td>69 W</td>
</tr>
<tr>
<td>Windows Standby</td>
<td>121 W</td>
<td>6 W</td>
<td>4 W</td>
</tr>
<tr>
<td>Off</td>
<td>3 W</td>
<td>6 W</td>
<td>3 W</td>
</tr>
</table>
<p>As expected, there is some difference between the Pentium D930 and the C2D T5500 (max 115 W, min 3 W), even forget that the D930 is terrible at being Standby (I mean: 121 W? really?) but look at the difference between the same C2D with a 400 W and 500 W PSU (max 25 W, min 2 W). I guess the 400 W PSU I have is more power efficient. By the way, I rechecked 3DMark2006 for both the 400 W and 500 W PSU, both are around 7100-ish, so no big change there.</p>
<p>Update: 400 W PSU is FSP Group Inc, 500 W PSU is Coolermaster</p>
]]></content:encoded>
			<wfw:commentRss>http://elfstone.nl/2010/10/18/psu-power-usage/feed/</wfw:commentRss>
		<slash:comments>3</slash:comments>
		</item>
		<item>
		<title>Debian packages: debugging postinst</title>
		<link>http://elfstone.nl/2010/06/02/debian-packages-debugging-postinst/</link>
		<comments>http://elfstone.nl/2010/06/02/debian-packages-debugging-postinst/#comments</comments>
		<pubDate>Wed, 02 Jun 2010 12:37:16 +0000</pubDate>
		<dc:creator>michiel</dc:creator>
				<category><![CDATA[Programming]]></category>
		<category><![CDATA[Sysadmin]]></category>

		<guid isPermaLink="false">http://elfstone.nl/?p=348</guid>
		<description><![CDATA[When writing debian packages, sometimes things go wrong in the postinst stage. An error like &#8220;the postinstallation script returned an error code of 1&#8243; will occur. This is not very informative. If you want to debug postinst scripts, you can &#8230; <a href="http://elfstone.nl/2010/06/02/debian-packages-debugging-postinst/">Continue reading <span class="meta-nav">&#8594;</span></a>]]></description>
			<content:encoded><![CDATA[<p>When writing debian packages, sometimes things go wrong in the postinst stage. An error like &#8220;the postinstallation script returned an error code of 1&#8243; will occur. This is not very informative.</p>
<p>If you want to debug postinst scripts, you can easily do this on the machine where you (half) installed the package. Normally you can execute /var/lib/dpkg/info/foo.postinst like this:<br />
<code><br />
sh -x /var/lib/dpkg/info/foo.postinst configure<br />
</code></p>
<p>However, if you use debconf, the output will be like this:<br />
<code>+ . /usr/share/debconf/confmodule<br />
+ [ !  ]<br />
+ PERL_DL_NONLAZY=1<br />
+ export PERL_DL_NONLAZY<br />
+ [  ]<br />
+ exec /usr/share/debconf/frontend /var/lib/dpkg/info/foo.postinst<br />
</code></p>
<p>Which is not helpful either. However, you can add &#8220;set -x&#8221; in /var/lib/dpkg/info/foo.postinst and then just execute it, it will give you the full output.</p>
<p><code><br />
sh /var/lib/dpkg/info/foo.postinst configure<br />
</code></p>
<p>Now the debugging process can begin!</p>
]]></content:encoded>
			<wfw:commentRss>http://elfstone.nl/2010/06/02/debian-packages-debugging-postinst/feed/</wfw:commentRss>
		<slash:comments>0</slash:comments>
		</item>
		<item>
		<title>Debian packaging: multiple packages</title>
		<link>http://elfstone.nl/2009/11/25/debian-packaging-multiple-packages/</link>
		<comments>http://elfstone.nl/2009/11/25/debian-packaging-multiple-packages/#comments</comments>
		<pubDate>Wed, 25 Nov 2009 12:08:52 +0000</pubDate>
		<dc:creator>michiel</dc:creator>
				<category><![CDATA[Programming]]></category>
		<category><![CDATA[Sysadmin]]></category>

		<guid isPermaLink="false">http://elfstone.nl/?p=224</guid>
		<description><![CDATA[For different projects, I&#8217;ve made debian packages before, but I&#8217;ve never had a project where multiple packages were created from one control file. Today, I had to work on a project where I had to do this. Everything went as &#8230; <a href="http://elfstone.nl/2009/11/25/debian-packaging-multiple-packages/">Continue reading <span class="meta-nav">&#8594;</span></a>]]></description>
			<content:encoded><![CDATA[<p>For different projects, I&#8217;ve made debian packages before, but I&#8217;ve never had a project where multiple packages were created from one control file. Today, I had to work on a project where I had to do this. Everything went as normal, except that I could not find out where to install the files so dh_builddeb could include them in their respective packages.</p>
<p>When only one package is made, this is easy: just install the files in debian/tmp as you would when installing on the system. For multiple packages, each package has its own directory: debian/&lt;package-name&gt;. How does dh_builddeb figure out which directory to use?</p>
<p><strong>Apparently, the default behaviour is to let the first package use the debian/tmp dir, and the other packages use the debian/&lt;package-name&gt; directory.<br />
</strong></p>
<p>I would rather have them all using the debian/&lt;package-name&gt; directory, but I could not find an option to do this.</p>
<p><em>Update:</em><br />
It seems that setting the compatibility level to 7 fixes this behaviour (echo &#8220;7&#8243; &gt; debian/compat), see man debhelper (section &#8220;Compatibility levels&#8221; for more info.</p>
]]></content:encoded>
			<wfw:commentRss>http://elfstone.nl/2009/11/25/debian-packaging-multiple-packages/feed/</wfw:commentRss>
		<slash:comments>0</slash:comments>
		</item>
		<item>
		<title>Munin plugin bind9</title>
		<link>http://elfstone.nl/2009/11/01/munin-plugin-bind9/</link>
		<comments>http://elfstone.nl/2009/11/01/munin-plugin-bind9/#comments</comments>
		<pubDate>Sun, 01 Nov 2009 14:42:38 +0000</pubDate>
		<dc:creator>michiel</dc:creator>
				<category><![CDATA[Sysadmin]]></category>

		<guid isPermaLink="false">http://elfstone.nl/?p=219</guid>
		<description><![CDATA[Today, I was trying to get the &#8216;bind9&#8242; plugin to work, but it didn&#8217;t work out-of-the-box. So I debugged and I found out that the standard bind9 plugin does not consider &#8216;views&#8217;. My bind9 setup has an &#8216;internal&#8217; as well &#8230; <a href="http://elfstone.nl/2009/11/01/munin-plugin-bind9/">Continue reading <span class="meta-nav">&#8594;</span></a>]]></description>
			<content:encoded><![CDATA[<p>Today, I was trying to get the &#8216;bind9&#8242; plugin to work, but it didn&#8217;t work out-of-the-box. So I debugged and I found out that the standard bind9 plugin does not consider &#8216;views&#8217;. My bind9 setup has an &#8216;internal&#8217; as well as an &#8216;external&#8217; view. In the bind9 query log, this adds a &#8216;view internal: &#8216; for each line, so the plugin didn&#8217;t see it as a valid query line:</p>
<pre>
client 192.168.1.1#37242: view internal: query: www.apple.com IN A +
</pre>
<p>I changed the regexp and I archive it here in case anyone else (or future-me) wants to use this:</p>
<pre>
--- bind9.orig	2009-11-01 15:06:16.000000000 +0100
+++ bind9.new	2009-11-01 15:06:07.000000000 +0100
@@ -73,9 +73,9 @@
     open(Q,"< $QUERYLOG") or die "$!";
     while (&lt;Q&gt;) {
 	chomp;
-	if (/client \d+\.\d+.\d+.\d+\#\d+: query\: \S+ (\w+) (\w+)/) {
-	    if ($1 eq 'IN' and $2 !~ /^TYPE/) {
-		$IN{$2}++;
+	if (/client \d+\.\d+.\d+.\d+\#\d+: (view \w+: )?query\: \S+ (\w+) (\w+)/) {
+	    if ($2 eq 'IN' and $3 !~ /^TYPE/) {
+		$IN{$3}++;
 	    } else {
 		$OTHER++;
 	    }
</pre>
<p>By the way, I also found out that there is a program called 'munin-run' which can be used to run the plugin as munin would, this saves a lot of hassle with sudo and environment settings!</p>
]]></content:encoded>
			<wfw:commentRss>http://elfstone.nl/2009/11/01/munin-plugin-bind9/feed/</wfw:commentRss>
		<slash:comments>0</slash:comments>
		</item>
		<item>
		<title>kjoradsatn. omtitra  eod</title>
		<link>http://elfstone.nl/2009/10/08/kjoradsatn-omtitra-eod/</link>
		<comments>http://elfstone.nl/2009/10/08/kjoradsatn-omtitra-eod/#comments</comments>
		<pubDate>Thu, 08 Oct 2009 07:35:58 +0000</pubDate>
		<dc:creator>michiel</dc:creator>
				<category><![CDATA[Sysadmin]]></category>

		<guid isPermaLink="false">http://elfstone.nl/?p=208</guid>
		<description><![CDATA[Today, I found this in the mail. I&#8217;m not sure if I should keep this kernel (it&#8217;s a stock Debian kernel: linux-image-2.6.26-2-vserver-amd64, 2.6.26-15). Google does not give any results, seems like a corruption of log messages. Oct 8 03:32:08 hoshi &#8230; <a href="http://elfstone.nl/2009/10/08/kjoradsatn-omtitra-eod/">Continue reading <span class="meta-nav">&#8594;</span></a>]]></description>
			<content:encoded><![CDATA[<p>Today, I found this in the mail. I&#8217;m not sure if I should keep this kernel (it&#8217;s a stock Debian kernel: linux-image-2.6.26-2-vserver-amd64, 2.6.26-15). Google does not give any results, seems like a corruption of log messages.</p>
<pre>
Oct  8 03:32:08 hoshi kernel: [145430.434977]kjoradsatn. omtitra  eod</pre>
<p><em>edit: Oct 9</em><br />
Today, I got this one, this is getting scary:</p>
<pre>
Oct  9 03:32:08 hoshi kernel: >99873]koradsatn. omtitra  eod
</pre>
<p>The only link I could find was this one: http://forums.gentoo.org/viewtopic-t-245137-start-0.html But it does not help me a lot.</p>
<p>When comparing the output of dmesg to the one in /var/log/kern.log (which is the source of the garbled messages), the only thing that is missing in the kern.log is this:</p>
<pre>
[236989.877537] kjournald starting.  Commit interval 5 seconds
</pre>
<p>It looks like this is the source from the garbled message: If you start from &#8216;k&#8217; and take only every other character, you&#8217;ll see. So apparently, this is not a kernel problem (because the message appears ungarbled in dmesg) but rather a problem with syslogd.</p>
<p>Now things get really strange, as I have an rsyslogd daemon running, but I could not find the binary on the disk. It seems that I accidentally started a syslog daemon in a chroot (I did play around with that certain chroot, because I was fixing a computer that was booting via nfs-root from this machine).</p>
<p>The funny thing is that the rsyslogd that was running, was actually a 32-bit executable (the nfsroot is a 32-bits install), while the host is a 64-bit system. So I&#8217;ve been running a 32-bit syslogd on a 64-bit for two days :)</p>
<p>I&#8217;ll see if I get another garbled message tomorrow, but I think the problem is solved now :)</p>
]]></content:encoded>
			<wfw:commentRss>http://elfstone.nl/2009/10/08/kjoradsatn-omtitra-eod/feed/</wfw:commentRss>
		<slash:comments>0</slash:comments>
		</item>
		<item>
		<title>apc usb-cable pinout</title>
		<link>http://elfstone.nl/2009/08/11/apc-usb-cable-pinout/</link>
		<comments>http://elfstone.nl/2009/08/11/apc-usb-cable-pinout/#comments</comments>
		<pubDate>Tue, 11 Aug 2009 16:59:55 +0000</pubDate>
		<dc:creator>michiel</dc:creator>
				<category><![CDATA[Hardware]]></category>

		<guid isPermaLink="false">http://elfstone.nl/?p=200</guid>
		<description><![CDATA[Just before I cut the cable for something else, I wanted to check if the pinout was the same as described in http://pinouts.ru/DevicesCables/apc_usb_cable_pinout.shtml. It was!]]></description>
			<content:encoded><![CDATA[<p>Just before I cut the cable for something else, I wanted to check if the pinout was the same as described in <a href="http://pinouts.ru/DevicesCables/apc_usb_cable_pinout.shtml">http://pinouts.ru/DevicesCables/apc_usb_cable_pinout.shtml</a>. It was!</p>
]]></content:encoded>
			<wfw:commentRss>http://elfstone.nl/2009/08/11/apc-usb-cable-pinout/feed/</wfw:commentRss>
		<slash:comments>0</slash:comments>
		</item>
		<item>
		<title>New iPhone/iPod touch wireless profile (RuG-FN2)</title>
		<link>http://elfstone.nl/2009/07/08/new-iphoneipod-touch-wireless-profile-rug-fn2/</link>
		<comments>http://elfstone.nl/2009/07/08/new-iphoneipod-touch-wireless-profile-rug-fn2/#comments</comments>
		<pubDate>Wed, 08 Jul 2009 13:37:01 +0000</pubDate>
		<dc:creator>michiel</dc:creator>
				<category><![CDATA[Mac]]></category>
		<category><![CDATA[Sysadmin]]></category>

		<guid isPermaLink="false">http://elfstone.nl/?p=186</guid>
		<description><![CDATA[A few weeks ago, my profile stopped working. It seems that mark has found a solution. I changed the profile and it can be downloaded here.]]></description>
			<content:encoded><![CDATA[<p>A few weeks ago, my <a href="http://elfstone.nl/2009/06/10/wireless-profile-for-ipodiphone-for-university-of-groningen/">profile</a> stopped working. It seems that <a href="http://mark.weblog.tudelft.nl/">mark</a> has found a solution. I changed the profile and it can be downloaded <a href="http://supermind.nl/rug.mobileconfig">here</a>.</p>
]]></content:encoded>
			<wfw:commentRss>http://elfstone.nl/2009/07/08/new-iphoneipod-touch-wireless-profile-rug-fn2/feed/</wfw:commentRss>
		<slash:comments>0</slash:comments>
		</item>
		<item>
		<title>Weird characters in bash</title>
		<link>http://elfstone.nl/2009/06/29/weird-characters-in-bash/</link>
		<comments>http://elfstone.nl/2009/06/29/weird-characters-in-bash/#comments</comments>
		<pubDate>Mon, 29 Jun 2009 17:16:48 +0000</pubDate>
		<dc:creator>michiel</dc:creator>
				<category><![CDATA[Sysadmin]]></category>

		<guid isPermaLink="false">http://elfstone.nl/?p=177</guid>
		<description><![CDATA[A friend of mine had a problem with his terminal today. Most people will encounter this one day or another. He asked me how to fix it. I told him to do &#8216;cat /bin/bash&#8217; and press ^C at one point &#8230; <a href="http://elfstone.nl/2009/06/29/weird-characters-in-bash/">Continue reading <span class="meta-nav">&#8594;</span></a>]]></description>
			<content:encoded><![CDATA[<div id="attachment_178" class="wp-caption alignright" style="width: 391px"><img src="http://elfstone.nl/uploads/2009/06/picture-187.png" alt="Scrambled character set" title="Scrambled character set" width="381" height="77" class="size-full wp-image-178" /><p class="wp-caption-text">Scrambled character set</p></div>
<p>A friend of mine had a problem with his terminal today. Most people will encounter this one day or another. He asked me how to fix it. I told him to do &#8216;cat /bin/bash&#8217; and press ^C at one point and repeat this until it worked. He was surprised that worked and asked me why. I told him I didn&#8217;t know exactly, but that it had to do with control characters that are often found in binary files but I was curious myself to so I did some research.</p>
<p>Apparently there is an ANSI escape sequence to select character sets. To select one of these character sets, the ANSI code &#8216;ESC(0&#8242; is used. Because terminals will catch the escape character, we have to do some extra to get a literal ESC: type ^V ESC. The character will be displayed as: &#8216;^[&#8216;. Typing this will result in a terminal that looks like the image above:</p>
<p><code><br />
bash$ echo '^[(0'<br />
</code></p>
<p>You can get the correct character set back by typing &#8216;ESC(B&#8217;, but maybe a better idea is to reset the terminal (the program &#8216;reset&#8217; will not always reset the character set) with the following ANSI code: &#8216;ESCc&#8217;. For this command we don&#8217;t have to use single quotes to avoid the parenthesis from being interpreted, so this easier to remember:</p>
<p><code><br />
bash$ echo ^[c<br />
</code></p>
<p>So whenever you get this problem, remember to press these 4 keys (ok, I count a control character as one key): ^V ESC c ENTER</p>
]]></content:encoded>
			<wfw:commentRss>http://elfstone.nl/2009/06/29/weird-characters-in-bash/feed/</wfw:commentRss>
		<slash:comments>0</slash:comments>
		</item>
	</channel>
</rss>

