<?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>Krzysztof Burghardt’s blog &#187; English</title>
	<atom:link href="http://blog.burghardt.pl/category/english/feed/" rel="self" type="application/rss+xml" />
	<link>http://blog.burghardt.pl</link>
	<description>Create. Break. Fix. Repeat.</description>
	<lastBuildDate>Mon, 05 Jul 2010 07:35:52 +0000</lastBuildDate>
	<language>en</language>
	<sy:updatePeriod>hourly</sy:updatePeriod>
	<sy:updateFrequency>1</sy:updateFrequency>
	<generator>http://wordpress.org/?v=abc</generator>
		<item>
		<title>ESE Key Daemon 1.2.7 released</title>
		<link>http://blog.burghardt.pl/2010/07/ese-key-daemon-1-2-7-released/</link>
		<comments>http://blog.burghardt.pl/2010/07/ese-key-daemon-1-2-7-released/#comments</comments>
		<pubDate>Mon, 05 Jul 2010 07:35:52 +0000</pubDate>
		<dc:creator>Krzysztof Burghardt</dc:creator>
				<category><![CDATA[English]]></category>
		<category><![CDATA[Hardware]]></category>
		<category><![CDATA[Linux]]></category>
		<category><![CDATA[Software]]></category>
		<category><![CDATA[daemon]]></category>
		<category><![CDATA[event]]></category>
		<category><![CDATA[input]]></category>
		<category><![CDATA[key]]></category>
		<category><![CDATA[keyboard]]></category>
		<category><![CDATA[multimedia]]></category>

		<guid isPermaLink="false">http://blog.burghardt.pl/?p=432</guid>
		<description><![CDATA[<p>New version of ESE Key Daemon was released today.</p>
<p>New features include the ability to handle multiple key combinations and distinguish between key presses and releases. A problem with the handling of the last line in a configuration file when there is no newline on the last line is gone. Numeric keys are now also allowed in [...]]]></description>
			<content:encoded><![CDATA[<p>New version of <a href="/2007/12/ese-key-daemon/">ESE Key Daemon</a> was released today.</p>
<p>New features include the ability to handle multiple key combinations and distinguish between key presses and releases. A problem with the handling of the last line in a configuration file when there is no newline on the last line is gone. Numeric keys are now also allowed in the configuration file.</p>
<p>Download: <a href="http://www.burghardt.pl/files/esekeyd-1.2.7.tar.gz">esekeyd-1.2.7.tar.gz</a> (<a href="http://www.burghardt.pl/files/esekeyd-1.2.7.tar.gz.asc">.asc</a>)</p>
<p>MD5: 5937ad6d7815dbc6ab6983411a9f37d4<br />
SHA1: 07671be42b61973a3270aaf1b41c3467568ae7ac</p>
]]></content:encoded>
			<wfw:commentRss>http://blog.burghardt.pl/2010/07/ese-key-daemon-1-2-7-released/feed/</wfw:commentRss>
		<slash:comments>0</slash:comments>
		</item>
		<item>
		<title>Debian GNU/Linux on Dell Inspiron 1764</title>
		<link>http://blog.burghardt.pl/2010/04/debian-gnulinux-on-dell-inspiron-1764/</link>
		<comments>http://blog.burghardt.pl/2010/04/debian-gnulinux-on-dell-inspiron-1764/#comments</comments>
		<pubDate>Mon, 26 Apr 2010 18:17:59 +0000</pubDate>
		<dc:creator>Krzysztof Burghardt</dc:creator>
				<category><![CDATA[Debian]]></category>
		<category><![CDATA[English]]></category>
		<category><![CDATA[Hardware]]></category>
		<category><![CDATA[Linux]]></category>
		<category><![CDATA[AMD64]]></category>
		<category><![CDATA[BCM4353]]></category>
		<category><![CDATA[Dell]]></category>
		<category><![CDATA[GNU]]></category>
		<category><![CDATA[Inspiron]]></category>
		<category><![CDATA[Radeon]]></category>

		<guid isPermaLink="false">http://www.burghardt.pl/?p=387</guid>
		<description><![CDATA[<p>Installing, configuring and using Debian GNU/Linux on Dell Inspiron 1764 (N0476409) notebook.</p>
<p></p>
Hardware overview

Intel Core i5-520M (2.4GHz, 4 Threads, turbo Boost up to 2.93GHz, 3M cache)
17.3&#8243; WLED High Definition+ (1600&#215;900) TFT Display
1GB ATI Mobility Radeon HD 5450
4096MB 1067MHz Dual Channel DDR3 SDRAM (2&#215;2048)
500GB (5400RPM) Serial ATA Hard Drive
DVD +/- RW Drive (read/write CD &#038; DVD)
Dell Wireless 1520 [...]]]></description>
			<content:encoded><![CDATA[<p>Installing, configuring and using Debian GNU/Linux on <a href="http://www1.euro.dell.com/uk/en/home/Laptops/inspiron-1764/pd.aspx?refid=inspiron-1764&#038;cs=ukdhs1&#038;s=dhs">Dell Inspiron 1764</a> (<a href="http://www.google.com/search?q=N0476409">N0476409</a>) notebook.</p>
<p><span id="more-387"></span></p>
<h2>Hardware overview</h2>
<ul>
<li>Intel Core i5-520M (2.4GHz, 4 Threads, turbo Boost up to 2.93GHz, 3M cache)</li>
<li>17.3&#8243; WLED High Definition+ (1600&#215;900) TFT Display</li>
<li>1GB ATI Mobility Radeon HD 5450</li>
<li>4096MB 1067MHz Dual Channel DDR3 SDRAM (2&#215;2048)</li>
<li>500GB (5400RPM) Serial ATA Hard Drive</li>
<li>DVD +/- RW Drive (read/write CD &#038; DVD)</li>
<li>Dell Wireless 1520 (802.11a/b/g/n)</li>
<li>Dell Bluetooth 365</li>
<li>Integrated 1,3MP webcam</li>
</ul>
<h2>Devices that works with Linux</h2>
<ul>
<li>CPU: both cores and HT works, recent Linux kernels support speedstep,</li>
<li>USB: works (even with Debian Installer images),</li>
<li>DVD+/-RW: works (even with Debian Installer images),</li>
<li>Graphic: basic features (2D, hardware accelerated 3D rendering) works with <strong>proprietary drivers only</strong>, most other features (CAL, POWERplay, multihead) unsupported; <strong>no FLOSS alternative</strong>,</li>
<li>Sound: works, but I need to pass options to module to make sound work properly,</li>
<li>Ethernet: works (even with Debian Installer images),</li>
<li>Wireless LAN: basic features (STA mode) supported by <strong>proprietary drivers only</strong>, other features (monitor mode and packet injection) not supported; <strong>no FLOSS alternative</strong>,</li>
<li>Bluetooth: works (as HCI only after reset with hid2hci),</li>
<li>Card reader: works (tested with MicroSD and Memory Stick PRO Duo, both with adapters),</li>
<li>Webcam: works.</li>
</ul>
<p></p>
<p>Also &#8220;Suspend to RAM&#8221; works using sysfs method of hibernate script. &#8220;Suspend to disk&#8221; works using ususpend method.</p>
<h2>Devices that does not work with Linux</h2>
<ul>
<li>none :-D</li>
</ul>
<h2>Devices</h2>
<ul>
<li><a href='/wp-content/uploads/2010/04/dmesg.txt' title='Linux kernel messages'>Linux kernel messages</a></li>
<li><a href='/wp-content/uploads/2010/04/lspci.txt' title='PCI devices list'>PCI devices list</a></li>
<li><a href='/wp-content/uploads/2010/04/lsusb.txt' title='USB devices list'>USB devices list</a></li>
<li><a href='/wp-content/uploads/2010/04/cpuinfo.txt' title='Processor details'>Processor details</a></li>
</ul>
<h2>Configuration</h2>
<h3>Graphic</h3>
<p>Download and install <a href="http://support.amd.com/us/gpudownload/Pages/index.aspx">fglrx</a> driver. <a href="http://www.google.com/search?q=fglrx+install">Google</a> is full of instruction how to install it, so I skip this step.</p>
<p>When driver is installed and fglrx is loaded into kernel its time to configure X.Org. Probably aticonfig would be best choice, but it fails on Mobility Radeon HD 5000 series cards with message:</p>
<pre>
# aticonfig --initial
aticonfig: No supported adapters detected
</pre>
<p>Download <a href='/wp-content/uploads/2010/04/xorg.txt'>my xorg.conf</a> and put it into <em>/etc/X11</em> directory. Then start X-server using <em>startx</em> command. My default layout include Inspiron&#8217;s built-in TFT screen, ATI Mobility Radeon HD 5450, ALPS touchpad and any other mice connected to it.</p>
<p>You will probably see &#8220;AMD unsupported hardware&#8221; watermark in lower right corner of the screen. There is no configuration option to remove it. Removal is possible by patching <em>fglrx_drv.so</em> file. <a href="http://www.phoronix.com/forums/member.php?u=6147">Kano</a> posted small script to replace call to EnableLogo with NOPs on <a href="http://www.phoronix.com/forums/showthread.php?t=19875">Phoronix Forums&#8217; thread &#8220;Unsupported Hardware watermark&#8221;</a>:</p>
<div class="codecolorer-container bash default" style="overflow:auto;white-space:nowrap;border:1px solid #9F9F9F;width:435px;"><div class="bash codecolorer" style="padding:5px;font:normal 12px/1.4em Monaco, Lucida Console, monospace;white-space:nowrap"><span style="color: #666666; font-style: italic;">#!/bin/sh</span><br />
<span style="color: #007800;">DRIVER</span>=<span style="color: #000000; font-weight: bold;">/</span>usr<span style="color: #000000; font-weight: bold;">/</span>lib<span style="color: #000000; font-weight: bold;">/</span>xorg<span style="color: #000000; font-weight: bold;">/</span>modules<span style="color: #000000; font-weight: bold;">/</span>drivers<span style="color: #000000; font-weight: bold;">/</span>fglrx_drv.so<br />
<span style="color: #000000; font-weight: bold;">for</span> x <span style="color: #000000; font-weight: bold;">in</span> $<span style="color: #7a0874; font-weight: bold;">&#40;</span>objdump <span style="color: #660033;">-d</span> <span style="color: #007800;">$DRIVER</span><span style="color: #000000; font-weight: bold;">|</span><span style="color: #c20cb9; font-weight: bold;">awk</span> <span style="color: #ff0000;">'/call/&amp;&amp;/EnableLogo/{print &quot;\\x&quot;$2&quot;\\x&quot;$3&quot;\\x&quot;$4&quot;\\x&quot;$5&quot;\\x&quot;$6}'</span><span style="color: #7a0874; font-weight: bold;">&#41;</span>; <span style="color: #000000; font-weight: bold;">do</span><br />
&nbsp;<span style="color: #c20cb9; font-weight: bold;">sed</span> <span style="color: #660033;">-i</span> <span style="color: #ff0000;">&quot;s/<span style="color: #007800;">$x</span>/\x90\x90\x90\x90\x90/g&quot;</span> <span style="color: #007800;">$DRIVER</span><br />
<span style="color: #000000; font-weight: bold;">done</span></div></div>
<h3>Sound</h3>
<p>Create file <em>/etc/modprobe.d/sound</em> with following content:</p>
<div class="codecolorer-container text default" style="overflow:auto;white-space:nowrap;border:1px solid #9F9F9F;width:435px;"><div class="text codecolorer" style="padding:5px;font:normal 12px/1.4em Monaco, Lucida Console, monospace;white-space:nowrap">alias snd-card-0 snd-hda-intel<br />
options snd-hda-intel model=dell index=0</div></div>
<p>Reload alsa driver (or reboot).</p>
<h3>Wireless LAN</h3>
<p>Drivers need to be compiled from sources. First prepare your system for kernel module building. Install <em>build-essential</em> and <em>module-assistant</em> packages.Then prepare kernel headers:</p>
<pre>
# aptitude install build-essential module-assistant
# m-a prepare
</pre>
<p>When kernel headers are ready download <a href="http://www.broadcom.com/support/802.11/linux_sta.php">802.11 Linux STA driver</a> for Broadcom&#8217;s IEEE 802.11a/b/g/n devices (this includes BCM4311, BCM4312, BCM4313, BCM4321 and BCM4322). Compile it. Install. And finally load into running kernel:</p>
<pre>
# cd /usr/src
# wget http://www.broadcom.com/docs/linux_sta/hybrid-portsrc-x86_64-v5.60.48.36.tar.gz
# mkdir hybrid-portsrc-x86_64-v5.60.48.36
# cd hybrid-portsrc-x86_64-v5.60.48.36
# tar zxf ../hybrid-portsrc-x86_64-v5.60.48.36.tar.gz
# make
# mkdir /lib/modules/`uname -r`/local
# cp wl.ko /lib/modules/`uname -r`/local
# depmod -A
# modprobe -v wl
</pre>
<p>Command <em>dmesg | tail</em> should output something similar to this:</p>
<pre>
wlan0: Broadcom BCM4353 802.11 Hybrid Wireless Controller 5.60.48.36
</pre>
<h3>Bluetooth</h3>
<p>Dell Bluetooth 365 is detected as HCI on kernel <a href="http://packages.debian.org/lenny-backports/linux-headers-2.6.32-bpo.4-amd64">2.6.32-bpo.4-amd64</a> only if previously reset with hid2hci (get a copy form <a href="http://packages.debian.org/lenny-backports/bluez">bluez 4.6</a>). This is actually <a href="http://idebian.wordpress.com/2008/07/06/manage-hid-bluetooth-devices-in-linux/">a feature, not a bug</a>. Use recent hid2hci to put device into HCI mode:</p>
<pre>
# hid2hci -m dell -v 413c -p 8162
Attempting to switch device 413c:8162 to HCI mode was successful
</pre>
]]></content:encoded>
			<wfw:commentRss>http://blog.burghardt.pl/2010/04/debian-gnulinux-on-dell-inspiron-1764/feed/</wfw:commentRss>
		<slash:comments>1</slash:comments>
		</item>
		<item>
		<title>Integration of AA Google 404 with Atahualpa</title>
		<link>http://blog.burghardt.pl/2009/11/integration-of-aa-google-404-with-atahualpa/</link>
		<comments>http://blog.burghardt.pl/2009/11/integration-of-aa-google-404-with-atahualpa/#comments</comments>
		<pubDate>Fri, 13 Nov 2009 01:41:55 +0000</pubDate>
		<dc:creator>Krzysztof Burghardt</dc:creator>
				<category><![CDATA[English]]></category>
		<category><![CDATA[Internet]]></category>
		<category><![CDATA[Software]]></category>
		<category><![CDATA[Atahualpa]]></category>
		<category><![CDATA[blog]]></category>
		<category><![CDATA[Google]]></category>
		<category><![CDATA[WordPress]]></category>

		<guid isPermaLink="false">http://www.burghardt.pl/?p=361</guid>
		<description><![CDATA[<p>AskApache Google 404 default 404.php does not work properly with Atahualpa theme. To fix those problems create another 404.php file in /themes/atahualpa with this content:</p>
<p></p>
&#60;?php

ob_start&#40;&#41;;

include&#40;TEMPLATEPATH . '/functions/bfa_get_options.php'&#41;;
get_header&#40;&#41;;

if &#40;function_exists&#40;'aa_google_404'&#41;&#41;
&#160; &#160; aa_google_404&#40;&#41;;
else
&#123;
?&#62;
&#160; &#160; &#60;h2&#62;&#60;?php _e&#40;'Not Found','atahualpa'&#41;; ?&#62;&#60;/h2&#62;
&#160; &#160; &#60;p&#62;&#60;?php _e&#40;&#34;Sorry, but you are looking for something that isn't here.&#34;,&#34;atahualpa&#34;&#41;; ?&#62;&#60;/p&#62;
&#60;?php
&#125;

bfa_center_content&#40;$bfa_ata&#91;'center_content_bottom'&#93;&#41;;

get_footer&#40;&#41;;

exit&#40;&#41;;

?&#62;
<p>When it is done, choose wp-content/themes/atahualpa/404.php as 404 File [...]]]></description>
			<content:encoded><![CDATA[<p><a href="http://wordpress.org/extend/plugins/askapache-google-404/">AskApache Google 404</a> default 404.php does not work properly with <a href="http://wordpress.org/extend/themes/atahualpa">Atahualpa</a> theme. To fix those problems create another 404.php file in <em>/themes/atahualpa</em> with this content:</p>
<p><span id="more-361"></span></p>
<div class="codecolorer-container php default" style="overflow:auto;white-space:nowrap;border:1px solid #9F9F9F;width:435px;height:300px;"><div class="php codecolorer" style="padding:5px;font:normal 12px/1.4em Monaco, Lucida Console, monospace;white-space:nowrap"><span style="color: #000000; font-weight: bold;">&lt;?php</span><br />
<br />
<a href="http://www.php.net/ob_start"><span style="color: #990000;">ob_start</span></a><span style="color: #009900;">&#40;</span><span style="color: #009900;">&#41;</span><span style="color: #339933;">;</span><br />
<br />
<span style="color: #b1b100;">include</span><span style="color: #009900;">&#40;</span>TEMPLATEPATH <span style="color: #339933;">.</span> <span style="color: #0000ff;">'/functions/bfa_get_options.php'</span><span style="color: #009900;">&#41;</span><span style="color: #339933;">;</span><br />
get_header<span style="color: #009900;">&#40;</span><span style="color: #009900;">&#41;</span><span style="color: #339933;">;</span><br />
<br />
<span style="color: #b1b100;">if</span> <span style="color: #009900;">&#40;</span><a href="http://www.php.net/function_exists"><span style="color: #990000;">function_exists</span></a><span style="color: #009900;">&#40;</span><span style="color: #0000ff;">'aa_google_404'</span><span style="color: #009900;">&#41;</span><span style="color: #009900;">&#41;</span><br />
&nbsp; &nbsp; aa_google_404<span style="color: #009900;">&#40;</span><span style="color: #009900;">&#41;</span><span style="color: #339933;">;</span><br />
<span style="color: #b1b100;">else</span><br />
<span style="color: #009900;">&#123;</span><br />
<span style="color: #000000; font-weight: bold;">?&gt;</span><br />
&nbsp; &nbsp; &lt;h2&gt;<span style="color: #000000; font-weight: bold;">&lt;?php</span> _e<span style="color: #009900;">&#40;</span><span style="color: #0000ff;">'Not Found'</span><span style="color: #339933;">,</span><span style="color: #0000ff;">'atahualpa'</span><span style="color: #009900;">&#41;</span><span style="color: #339933;">;</span> <span style="color: #000000; font-weight: bold;">?&gt;</span>&lt;/h2&gt;<br />
&nbsp; &nbsp; &lt;p&gt;<span style="color: #000000; font-weight: bold;">&lt;?php</span> _e<span style="color: #009900;">&#40;</span><span style="color: #0000ff;">&quot;Sorry, but you are looking for something that isn't here.&quot;</span><span style="color: #339933;">,</span><span style="color: #0000ff;">&quot;atahualpa&quot;</span><span style="color: #009900;">&#41;</span><span style="color: #339933;">;</span> <span style="color: #000000; font-weight: bold;">?&gt;</span>&lt;/p&gt;<br />
<span style="color: #000000; font-weight: bold;">&lt;?php</span><br />
<span style="color: #009900;">&#125;</span><br />
<br />
bfa_center_content<span style="color: #009900;">&#40;</span><span style="color: #000088;">$bfa_ata</span><span style="color: #009900;">&#91;</span><span style="color: #0000ff;">'center_content_bottom'</span><span style="color: #009900;">&#93;</span><span style="color: #009900;">&#41;</span><span style="color: #339933;">;</span><br />
<br />
get_footer<span style="color: #009900;">&#40;</span><span style="color: #009900;">&#41;</span><span style="color: #339933;">;</span><br />
<br />
<a href="http://www.php.net/exit"><span style="color: #990000;">exit</span></a><span style="color: #009900;">&#40;</span><span style="color: #009900;">&#41;</span><span style="color: #339933;">;</span><br />
<br />
<span style="color: #000000; font-weight: bold;">?&gt;</span></div></div>
<p>When it is done, choose <em>wp-content/themes/atahualpa/404.php</em> as <strong>404 File Handling</strong> and enable AA Google 404.</p>
]]></content:encoded>
			<wfw:commentRss>http://blog.burghardt.pl/2009/11/integration-of-aa-google-404-with-atahualpa/feed/</wfw:commentRss>
		<slash:comments>0</slash:comments>
		</item>
		<item>
		<title>Virtual destinations are faster than Camel routing</title>
		<link>http://blog.burghardt.pl/2009/10/virtual-destinations-are-faster-than-camel-routing/</link>
		<comments>http://blog.burghardt.pl/2009/10/virtual-destinations-are-faster-than-camel-routing/#comments</comments>
		<pubDate>Sat, 31 Oct 2009 20:26:08 +0000</pubDate>
		<dc:creator>Krzysztof Burghardt</dc:creator>
				<category><![CDATA[English]]></category>
		<category><![CDATA[Software]]></category>
		<category><![CDATA[ActiveMQ]]></category>
		<category><![CDATA[Camel]]></category>
		<category><![CDATA[queue]]></category>
		<category><![CDATA[routing]]></category>

		<guid isPermaLink="false">http://www.burghardt.pl/?p=328</guid>
		<description><![CDATA[<p>Routing messages from one input queue to two output queues in ActiveMQ can be done in two different ways. Apache Camel, a powerful rule-based routing engine often used with ActiveMQ, is a typical choice. Virtual composite queue is another solution. Which to choose? The faster.</p>
<p></p>
Apache Camel
<p>Camel configuration I use:</p>
&#60;beans
 &#160; &#160;xmlns:xsi=&#34;http://www.w3.org/2001/XMLSchema-instance&#34;
 &#160; &#160;xsi:schemaLocation=&#34;http://camel.apache.org/schema/spring http://camel.apache.org/schema/spring/camel-spring.xsd&#34;&#62;

&#160; &#160; &#60;camelContext [...]]]></description>
			<content:encoded><![CDATA[<p>Routing messages from one input queue to two output queues in <a href="http://activemq.apache.org/">ActiveMQ</a> can be done in two different ways. <a href="http://camel.apache.org/">Apache Camel</a>, a powerful rule-based routing engine often used with <a href="http://activemq.apache.org/">ActiveMQ</a>, is a typical choice. <a href="http://activemq.apache.org/virtual-destinations.html">Virtual composite queue</a> is another solution. Which to choose? The faster.</p>
<p><span id="more-328"></span></p>
<h2>Apache Camel</h2>
<p>Camel configuration I use:</p>
<div class="codecolorer-container xml default" style="overflow:auto;white-space:nowrap;border:1px solid #9F9F9F;width:435px;height:300px;"><div class="xml codecolorer" style="padding:5px;font:normal 12px/1.4em Monaco, Lucida Console, monospace;white-space:nowrap"><span style="color: #009900;"><span style="color: #000000; font-weight: bold;">&lt;beans</span></span><br />
<span style="color: #009900;"> &nbsp; &nbsp;<span style="color: #000066;">xmlns:xsi</span>=<span style="color: #ff0000;">&quot;http://www.w3.org/2001/XMLSchema-instance&quot;</span></span><br />
<span style="color: #009900;"> &nbsp; &nbsp;<span style="color: #000066;">xsi:schemaLocation</span>=<span style="color: #ff0000;">&quot;http://camel.apache.org/schema/spring http://camel.apache.org/schema/spring/camel-spring.xsd&quot;</span><span style="color: #000000; font-weight: bold;">&gt;</span></span><br />
<br />
&nbsp; &nbsp; <span style="color: #009900;"><span style="color: #000000; font-weight: bold;">&lt;camelContext</span> <span style="color: #000066;">id</span>=<span style="color: #ff0000;">&quot;camel&quot;</span> <span style="color: #000066;">xmlns</span>=<span style="color: #ff0000;">&quot;http://camel.apache.org/schema/spring&quot;</span><span style="color: #000000; font-weight: bold;">&gt;</span></span><br />
&nbsp; &nbsp; &nbsp; &nbsp; <span style="color: #009900;"><span style="color: #000000; font-weight: bold;">&lt;route<span style="color: #000000; font-weight: bold;">&gt;</span></span></span><br />
&nbsp; &nbsp; &nbsp; &nbsp; &nbsp; &nbsp; <span style="color: #009900;"><span style="color: #000000; font-weight: bold;">&lt;from</span> <span style="color: #000066;">uri</span>=<span style="color: #ff0000;">&quot;activemq:INPUT-QUEUE&quot;</span><span style="color: #000000; font-weight: bold;">/&gt;</span></span><br />
&nbsp; &nbsp; &nbsp; &nbsp; &nbsp; &nbsp; <span style="color: #009900;"><span style="color: #000000; font-weight: bold;">&lt;to</span> <span style="color: #000066;">uri</span>=<span style="color: #ff0000;">&quot;activemq:OUTPUT-1-QUEUE&quot;</span><span style="color: #000000; font-weight: bold;">/&gt;</span></span><br />
&nbsp; &nbsp; &nbsp; &nbsp; &nbsp; &nbsp; <span style="color: #009900;"><span style="color: #000000; font-weight: bold;">&lt;to</span> <span style="color: #000066;">uri</span>=<span style="color: #ff0000;">&quot;activemq:OUTPUT-2-QUEUE&quot;</span><span style="color: #000000; font-weight: bold;">/&gt;</span></span><br />
&nbsp; &nbsp; &nbsp; &nbsp; <span style="color: #009900;"><span style="color: #000000; font-weight: bold;">&lt;/route<span style="color: #000000; font-weight: bold;">&gt;</span></span></span><br />
&nbsp; &nbsp; <span style="color: #009900;"><span style="color: #000000; font-weight: bold;">&lt;/camelContext<span style="color: #000000; font-weight: bold;">&gt;</span></span></span><br />
<br />
&nbsp; &nbsp; <span style="color: #009900;"><span style="color: #000000; font-weight: bold;">&lt;bean</span> <span style="color: #000066;">id</span>=<span style="color: #ff0000;">&quot;activemq&quot;</span> <span style="color: #000066;">class</span>=<span style="color: #ff0000;">&quot;org.apache.activemq.camel.component.ActiveMQComponent&quot;</span> <span style="color: #000000; font-weight: bold;">&gt;</span></span><br />
&nbsp; &nbsp; &nbsp; &nbsp; <span style="color: #009900;"><span style="color: #000000; font-weight: bold;">&lt;property</span> <span style="color: #000066;">name</span>=<span style="color: #ff0000;">&quot;connectionFactory&quot;</span><span style="color: #000000; font-weight: bold;">&gt;</span></span><br />
&nbsp; &nbsp; &nbsp; &nbsp; &nbsp; <span style="color: #009900;"><span style="color: #000000; font-weight: bold;">&lt;bean</span> <span style="color: #000066;">class</span>=<span style="color: #ff0000;">&quot;org.apache.activemq.ActiveMQConnectionFactory&quot;</span><span style="color: #000000; font-weight: bold;">&gt;</span></span><br />
&nbsp; &nbsp; &nbsp; &nbsp; &nbsp; &nbsp; <span style="color: #009900;"><span style="color: #000000; font-weight: bold;">&lt;property</span> <span style="color: #000066;">name</span>=<span style="color: #ff0000;">&quot;brokerURL&quot;</span> <span style="color: #000066;">value</span>=<span style="color: #ff0000;">&quot;vm://localhost?create=false&amp;amp;waitForStart=10000&quot;</span> <span style="color: #000000; font-weight: bold;">/&gt;</span></span><br />
&nbsp; &nbsp; &nbsp; &nbsp; &nbsp; &nbsp; <span style="color: #009900;"><span style="color: #000000; font-weight: bold;">&lt;property</span> <span style="color: #000066;">name</span>=<span style="color: #ff0000;">&quot;userName&quot;</span> <span style="color: #000066;">value</span>=<span style="color: #ff0000;">&quot;${activemq.username}&quot;</span><span style="color: #000000; font-weight: bold;">/&gt;</span></span><br />
&nbsp; &nbsp; &nbsp; &nbsp; &nbsp; &nbsp; <span style="color: #009900;"><span style="color: #000000; font-weight: bold;">&lt;property</span> <span style="color: #000066;">name</span>=<span style="color: #ff0000;">&quot;password&quot;</span> <span style="color: #000066;">value</span>=<span style="color: #ff0000;">&quot;${activemq.password}&quot;</span><span style="color: #000000; font-weight: bold;">/&gt;</span></span><br />
&nbsp; &nbsp; &nbsp; &nbsp; &nbsp; <span style="color: #009900;"><span style="color: #000000; font-weight: bold;">&lt;/bean<span style="color: #000000; font-weight: bold;">&gt;</span></span></span><br />
&nbsp; &nbsp; &nbsp; &nbsp; <span style="color: #009900;"><span style="color: #000000; font-weight: bold;">&lt;/property<span style="color: #000000; font-weight: bold;">&gt;</span></span></span><br />
&nbsp; &nbsp; <span style="color: #009900;"><span style="color: #000000; font-weight: bold;">&lt;/bean<span style="color: #000000; font-weight: bold;">&gt;</span></span></span><br />
<span style="color: #009900;"><span style="color: #000000; font-weight: bold;">&lt;/beans<span style="color: #000000; font-weight: bold;">&gt;</span></span></span></div></div>
<p>Benchmark took 3 minutes 31 seconds to send 10 thousand messages through Camel:</p>
<pre>
$ time ./amqinject INPUT-QUEUE 10000
0.651u 0.490s 3:31.43 0.5%      0+0k 0+0io 0pf+0w
</pre>
<p>Unfortunately &#8220;Number Of Pending Messages&#8221; was always about 1024 and amqinject gets blocked in send() call:</p>
<pre>
INFO | Usage Manager memory limit reached on queue://INPUT-QUEUE. Producers will be throttled to the rate at which messages are removed from this destination to prevent flooding it. See http://activemq.apache.org/producer-flow-control.html for more info
</pre>
<h2>Virtual Composite Queue</h2>
<p>Virtual destinations are configured in &lt;broker&gt; tag. Here is my configuration:</p>
<div class="codecolorer-container xml default" style="overflow:auto;white-space:nowrap;border:1px solid #9F9F9F;width:435px;"><div class="xml codecolorer" style="padding:5px;font:normal 12px/1.4em Monaco, Lucida Console, monospace;white-space:nowrap">&nbsp; &nbsp; &nbsp; &nbsp; <span style="color: #009900;"><span style="color: #000000; font-weight: bold;">&lt;destinations<span style="color: #000000; font-weight: bold;">&gt;</span></span></span><br />
&nbsp; &nbsp; &nbsp; &nbsp; &nbsp; &nbsp; <span style="color: #009900;"><span style="color: #000000; font-weight: bold;">&lt;queue</span> <span style="color: #000066;">physicalName</span>=<span style="color: #ff0000;">&quot;INPUT-QUEUE&quot;</span> <span style="color: #000000; font-weight: bold;">/&gt;</span></span><br />
&nbsp; &nbsp; &nbsp; &nbsp; &nbsp; &nbsp; <span style="color: #009900;"><span style="color: #000000; font-weight: bold;">&lt;queue</span> <span style="color: #000066;">physicalName</span>=<span style="color: #ff0000;">&quot;OUTPUT-1-QUEUE&quot;</span> <span style="color: #000000; font-weight: bold;">/&gt;</span></span><br />
&nbsp; &nbsp; &nbsp; &nbsp; &nbsp; &nbsp; <span style="color: #009900;"><span style="color: #000000; font-weight: bold;">&lt;queue</span> <span style="color: #000066;">physicalName</span>=<span style="color: #ff0000;">&quot;OUTPUT-2-QUEUE&quot;</span> <span style="color: #000000; font-weight: bold;">/&gt;</span></span><br />
&nbsp; &nbsp; &nbsp; &nbsp; <span style="color: #009900;"><span style="color: #000000; font-weight: bold;">&lt;/destinations<span style="color: #000000; font-weight: bold;">&gt;</span></span></span><br />
<br />
&nbsp; &nbsp; &nbsp; &nbsp; <span style="color: #009900;"><span style="color: #000000; font-weight: bold;">&lt;destinationInterceptors<span style="color: #000000; font-weight: bold;">&gt;</span></span></span><br />
&nbsp; &nbsp; &nbsp; &nbsp; <span style="color: #009900;"><span style="color: #000000; font-weight: bold;">&lt;virtualDestinationInterceptor<span style="color: #000000; font-weight: bold;">&gt;</span></span></span><br />
&nbsp; &nbsp; &nbsp; &nbsp; &nbsp; &nbsp; <span style="color: #009900;"><span style="color: #000000; font-weight: bold;">&lt;virtualDestinations<span style="color: #000000; font-weight: bold;">&gt;</span></span></span><br />
&nbsp; &nbsp; &nbsp; &nbsp; &nbsp; &nbsp; <span style="color: #009900;"><span style="color: #000000; font-weight: bold;">&lt;compositeQueue</span> <span style="color: #000066;">name</span>=<span style="color: #ff0000;">&quot;INPUT-QUEUE&quot;</span><span style="color: #000000; font-weight: bold;">&gt;</span></span><br />
&nbsp; &nbsp; &nbsp; &nbsp; &nbsp; &nbsp; <span style="color: #009900;"><span style="color: #000000; font-weight: bold;">&lt;forwardTo<span style="color: #000000; font-weight: bold;">&gt;</span></span></span><br />
&nbsp; &nbsp; &nbsp; &nbsp; &nbsp; &nbsp; &nbsp; &nbsp; <span style="color: #009900;"><span style="color: #000000; font-weight: bold;">&lt;queue</span> <span style="color: #000066;">physicalName</span>=<span style="color: #ff0000;">&quot;OUTPUT-1-QUEUE&quot;</span> <span style="color: #000000; font-weight: bold;">/&gt;</span></span><br />
&nbsp; &nbsp; &nbsp; &nbsp; &nbsp; &nbsp; &nbsp; &nbsp; <span style="color: #009900;"><span style="color: #000000; font-weight: bold;">&lt;queue</span> <span style="color: #000066;">physicalName</span>=<span style="color: #ff0000;">&quot;OUTPUT-2-QUEUE&quot;</span> <span style="color: #000000; font-weight: bold;">/&gt;</span></span><br />
&nbsp; &nbsp; &nbsp; &nbsp; &nbsp; &nbsp; <span style="color: #009900;"><span style="color: #000000; font-weight: bold;">&lt;/forwardTo<span style="color: #000000; font-weight: bold;">&gt;</span></span></span><br />
&nbsp; &nbsp; &nbsp; &nbsp; &nbsp; &nbsp; <span style="color: #009900;"><span style="color: #000000; font-weight: bold;">&lt;/compositeQueue<span style="color: #000000; font-weight: bold;">&gt;</span></span></span><br />
&nbsp; &nbsp; &nbsp; &nbsp; &nbsp; &nbsp; <span style="color: #009900;"><span style="color: #000000; font-weight: bold;">&lt;/virtualDestinations<span style="color: #000000; font-weight: bold;">&gt;</span></span></span><br />
&nbsp; &nbsp; &nbsp; &nbsp; <span style="color: #009900;"><span style="color: #000000; font-weight: bold;">&lt;/virtualDestinationInterceptor<span style="color: #000000; font-weight: bold;">&gt;</span></span></span><br />
&nbsp; &nbsp; &nbsp; &nbsp; <span style="color: #009900;"><span style="color: #000000; font-weight: bold;">&lt;/destinationInterceptors<span style="color: #000000; font-weight: bold;">&gt;</span></span></span></div></div>
<p>Amqinject never blocked and it took only <strong>2 minutes 29 seconds</strong> to complete:</p>
<pre>
% time ./amqinject INPUT-QUEUE 10000
0.718u 0.539s 2:29.33 0.8%      0+0k 0+0io 0pf+0w
</pre>
]]></content:encoded>
			<wfw:commentRss>http://blog.burghardt.pl/2009/10/virtual-destinations-are-faster-than-camel-routing/feed/</wfw:commentRss>
		<slash:comments>0</slash:comments>
		</item>
		<item>
		<title>Migrating from ActiveMQ-CPP/CMS version 2.2 to 3.0</title>
		<link>http://blog.burghardt.pl/2009/08/migrating-from-activemq-cppcms-version-2-2-to-3-0/</link>
		<comments>http://blog.burghardt.pl/2009/08/migrating-from-activemq-cppcms-version-2-2-to-3-0/#comments</comments>
		<pubDate>Sun, 23 Aug 2009 00:02:55 +0000</pubDate>
		<dc:creator>Krzysztof Burghardt</dc:creator>
				<category><![CDATA[English]]></category>
		<category><![CDATA[Software]]></category>
		<category><![CDATA[ActiveMQ]]></category>
		<category><![CDATA[IP]]></category>
		<category><![CDATA[library]]></category>
		<category><![CDATA[TCP]]></category>

		<guid isPermaLink="false">http://www.burghardt.pl/?p=326</guid>
		<description><![CDATA[<p>Migrating from ActiveMQ-CPP/CMS version 2.2.6 to 3.0.1 is very easy. There are only two minor problems to deal with.</p>
<p></p>
First problem: exceptions
<p>No idea what &#8220;N3cms12CMSExceptionE&#8221; is? Use getCause() on cms::CMSException
objects to get std::exception*. Do not call what() directly. Do not try to call what() from any base classes.</p>
catch &#40;cms::CMSException&#38; e&#41; &#123;
&#160; &#160; cout &#60;&#60; e.getCause&#40;&#41;-&#62;what&#40;&#41; &#60;&#60; endl;
&#125;
<p>And [...]]]></description>
			<content:encoded><![CDATA[<p>Migrating from <a href="http://activemq.apache.org/">ActiveMQ</a>-CPP/<a href="http://activemq.apache.org/cms/">CMS</a> version 2.2.6 to 3.0.1 is very easy. There are only two minor problems to deal with.</p>
<p><span id="more-326"></span></p>
<h2>First problem: exceptions</h2>
<p>No idea what &#8220;N3cms12CMSExceptionE&#8221; is? Use <em>getCause()</em> on <em>cms::CMSException</em><br />
objects to get <em>std::exception*</em>. Do not call <em>what()</em> directly. Do not try to call <em>what()</em> from any base classes.</p>
<div class="codecolorer-container cpp default" style="overflow:auto;white-space:nowrap;border:1px solid #9F9F9F;width:435px;"><div class="cpp codecolorer" style="padding:5px;font:normal 12px/1.4em Monaco, Lucida Console, monospace;white-space:nowrap"><span style="color: #0000ff;">catch</span> <span style="color: #008000;">&#40;</span>cms<span style="color: #008080;">::</span><span style="color: #007788;">CMSException</span><span style="color: #000040;">&amp;</span> e<span style="color: #008000;">&#41;</span> <span style="color: #008000;">&#123;</span><br />
&nbsp; &nbsp; <span style="color: #0000dd;">cout</span> <span style="color: #000080;">&lt;&lt;</span> e.<span style="color: #007788;">getCause</span><span style="color: #008000;">&#40;</span><span style="color: #008000;">&#41;</span><span style="color: #000040;">-</span><span style="color: #000080;">&gt;</span>what<span style="color: #008000;">&#40;</span><span style="color: #008000;">&#41;</span> <span style="color: #000080;">&lt;&lt;</span> endl<span style="color: #008080;">;</span><br />
<span style="color: #008000;">&#125;</span></div></div>
<p>And now &#8220;N3cms12CMSExceptionE&#8221; is &#8220;No Matching Factory Registered for format := tcp&#8221;.</p>
<h2>Second problem: library initialization</h2>
<p>&#8220;No Matching Factory Registered for format := tcp&#8221; suggests that library was not initialized properly or some protocol-related modules was not loaded. Version 3.0 (and above) requires explicit initialization of ActiveMQ library.</p>
<p>To fix this problem include <em>activemq/library/ActiveMQCPP.h</em> and call <em>ActiveMQCPP::initializeLibrary()</em>.</p>
<div class="codecolorer-container cpp default" style="overflow:auto;white-space:nowrap;border:1px solid #9F9F9F;width:435px;"><div class="cpp codecolorer" style="padding:5px;font:normal 12px/1.4em Monaco, Lucida Console, monospace;white-space:nowrap"><span style="color: #339900;">#include &lt;activemq/library/ActiveMQCPP.h&gt;</span><br />
<span style="color: #666666;">// ...</span><br />
activemq<span style="color: #008080;">::</span><span style="color: #007788;">library</span><span style="color: #008080;">::</span><span style="color: #007788;">ActiveMQCPP</span><span style="color: #008080;">::</span><span style="color: #007788;">initializeLibrary</span><span style="color: #008000;">&#40;</span><span style="color: #008000;">&#41;</span><span style="color: #008080;">;</span></div></div>
]]></content:encoded>
			<wfw:commentRss>http://blog.burghardt.pl/2009/08/migrating-from-activemq-cppcms-version-2-2-to-3-0/feed/</wfw:commentRss>
		<slash:comments>0</slash:comments>
		</item>
		<item>
		<title>FreeBSD with X.Org on QEMU</title>
		<link>http://blog.burghardt.pl/2009/03/freebsd-with-xorg-on-qemu/</link>
		<comments>http://blog.burghardt.pl/2009/03/freebsd-with-xorg-on-qemu/#comments</comments>
		<pubDate>Fri, 27 Mar 2009 19:03:03 +0000</pubDate>
		<dc:creator>Krzysztof Burghardt</dc:creator>
				<category><![CDATA[English]]></category>
		<category><![CDATA[FreeBSD]]></category>
		<category><![CDATA[DBus]]></category>
		<category><![CDATA[HAL]]></category>
		<category><![CDATA[QEMU]]></category>
		<category><![CDATA[X.Org]]></category>

		<guid isPermaLink="false">http://www.burghardt.pl/?p=296</guid>
		<description><![CDATA[<p>X.Org form ports works fine with cirrus driver, but starts in 800&#215;600 only. Small tweak to configuration file is needed to run X in higher resolutions.</p>
<p></p>
Install X.Org and drivers
<p>First install xorg, xf86-video-cirrus and xf86-input-keyboard ports.</p>
DBus and HAL
<p>Installing DBus and HAL allow X Server to guess hardware configuration and work without any configuration file.</p>
<p>If your console get [...]]]></description>
			<content:encoded><![CDATA[<p>X.Org form ports works fine with <strong>cirrus</strong> driver, but starts in 800&#215;600 only. Small tweak to configuration file is needed to run X in higher resolutions.</p>
<p><span id="more-296"></span></p>
<h2>Install X.Org and drivers</h2>
<p>First install <strong>xorg</strong>, <strong>xf86-video-cirrus</strong> and <strong>xf86-input-keyboard</strong> ports.</p>
<h2>DBus and HAL</h2>
<p>Installing DBus and HAL allow X Server to guess hardware configuration and <a href="http://www.kirya.net/weblog/2009/02/07/my-new-xorgconf/">work without any configuration file</a>.</p>
<p>If your console get flooded by messages like this after enabling HAL:</p>
<pre>
acd0: FAILURE - unknown CMD (0x03) ILLEGAL REQUEST asc=0x20 ascq=0x00
</pre>
<p>disable CD-ROM polling in HAL with command:</p>
<pre>
# hal-disable-polling --device /dev/acd0
</pre>
<p>Automatically configured X-Window starts in resolution as small as 800&#215;600.</p>
<h2>Configuring X</h2>
<p>Create <em>xorg.conf.new</em> skeleton with:</p>
<pre>
# X -configure
</pre>
<h3>Tweak <em>xorg.conf.new</em></h2>
<p>Add those settings to get more then 800&#215;600:</p>
<div class="codecolorer-container text default" style="overflow:auto;white-space:nowrap;border:1px solid #9F9F9F;width:435px;"><div class="text codecolorer" style="padding:5px;font:normal 12px/1.4em Monaco, Lucida Console, monospace;white-space:nowrap">Section &quot;Monitor&quot;<br />
&nbsp; &nbsp; &nbsp; &nbsp;HorizSync &nbsp; &nbsp; &nbsp; 31.5 - 48.5<br />
&nbsp; &nbsp; &nbsp; &nbsp;VertRefresh &nbsp; &nbsp; 50.0 - 90.0<br />
&nbsp; &nbsp; &nbsp; &nbsp;Option &nbsp; &nbsp; &nbsp; &nbsp; &nbsp;&quot;DPMS&quot;<br />
EndSection<br />
<br />
Section &quot;Device&quot;<br />
&nbsp; &nbsp; &nbsp; &nbsp;Driver &nbsp; &nbsp; &nbsp; &nbsp; &nbsp;&quot;cirrus&quot;<br />
EndSection</div></div>
<p>If you want to set specific resolution (1024&#215;768 in this example) use:</p>
<div class="codecolorer-container text default" style="overflow:auto;white-space:nowrap;border:1px solid #9F9F9F;width:435px;"><div class="text codecolorer" style="padding:5px;font:normal 12px/1.4em Monaco, Lucida Console, monospace;white-space:nowrap">Section &quot;Screen&quot;<br />
&nbsp; &nbsp; &nbsp; &nbsp;DefaultDepth 16<br />
&nbsp; &nbsp; &nbsp; &nbsp;SubSection &quot;Display&quot;<br />
&nbsp; &nbsp; &nbsp; &nbsp; &nbsp; &nbsp; &nbsp; &nbsp;Depth &nbsp; &nbsp; 16<br />
&nbsp; &nbsp; &nbsp; &nbsp; &nbsp; &nbsp; &nbsp; &nbsp;Modes &nbsp; &nbsp; &quot;1024x768&quot;<br />
&nbsp; &nbsp; &nbsp; &nbsp;EndSubSection<br />
EndSection</div></div>
<h3>Testing X.Org setup</h3>
<p>To test your setup run:</p>
<pre>
# X -config xorg.conf.new
</pre>
<p>Finally move <em>xorg.conf.new</em> to <em>xorg.conf</em>:</p>
<pre>
# mv xorg.conf.new /etc/X11/xorg.conf
</pre>
<p>Now X.Org is configured. Login as plain user and run <strong>startx</strong> to start X-Window session.</p>
]]></content:encoded>
			<wfw:commentRss>http://blog.burghardt.pl/2009/03/freebsd-with-xorg-on-qemu/feed/</wfw:commentRss>
		<slash:comments>0</slash:comments>
		</item>
		<item>
		<title>Sptrace 1.4.2 released</title>
		<link>http://blog.burghardt.pl/2009/03/sptrace-142-released/</link>
		<comments>http://blog.burghardt.pl/2009/03/sptrace-142-released/#comments</comments>
		<pubDate>Sat, 14 Mar 2009 09:00:06 +0000</pubDate>
		<dc:creator>Krzysztof Burghardt</dc:creator>
				<category><![CDATA[English]]></category>
		<category><![CDATA[Linux]]></category>
		<category><![CDATA[Security]]></category>
		<category><![CDATA[Software]]></category>
		<category><![CDATA[gdb]]></category>
		<category><![CDATA[kernel]]></category>
		<category><![CDATA[LKM]]></category>
		<category><![CDATA[ltrace]]></category>
		<category><![CDATA[ptrace]]></category>
		<category><![CDATA[strace]]></category>

		<guid isPermaLink="false">http://www.burghardt.pl/?p=292</guid>
		<description><![CDATA[<p>New version of sptrace was released today. Sptrace is a secure ptrace() Linux Kernel Module (LKM). It limits users&#8217; access to the ptrace() call. Module was updated to reflect changes in new kernel releases and tested with 2.6.26.</p>
<p></p>
<p>When someone not allowed to trace processes uses program that call ptrace() (like strace, ltrace or gdb) current and [...]]]></description>
			<content:encoded><![CDATA[<p>New version of <a href="/2007/12/limiting-access-to-ptrace-call-in-linux/">sptrace</a> was released today. Sptrace is a <strong>secure ptrace()</strong> Linux Kernel Module (LKM). It limits users&#8217; access to the <em>ptrace()</em> call. Module was updated to reflect changes in new kernel releases and tested with 2.6.26.</p>
<p><span id="more-292"></span></p>
<p>When someone not allowed to trace processes uses program that call <em>ptrace()</em> (like strace, ltrace or gdb) current and parent processes names, pids, uids and euids are logged, e.g.:</p>
<pre>
Mar 13 08:51:11 ghost kernel: [ 8086.730499] sptrace: ptrace() DENIED for (gdb:6810) UID(1000) EUID(1000), parent (gdb:6785) UID(1000) EUID(1000)
Mar 13 08:51:11 ghost kernel: [ 8086.984694] sptrace: ptrace() DENIED for (gdb:6785) UID(1000) EUID(1000), parent (tcsh:32216) UID(1000) EUID(1000)
Mar 13 08:51:44 ghost kernel: [ 8119.928920] sptrace: ptrace() DENIED for (gdb:6923) UID(1000) EUID(1000), parent (tcsh:32216) UID(1000) EUID(1000)
</pre>
<p>Program that call <em>ptrace()</em> will get EPERM error:</p>
<pre>
$ strace ls
strace: ptrace(PTRACE_TRACEME, ...): Operation not permitted
$ ltrace ls
PTRACE_TRACEME: Operation not permitted
PTRACE_SETOPTIONS: Operation not permitted
$ gdb -p 32215
GNU gdb 6.8-debian
[...]
This GDB was configured as "i486-linux-gnu".
Attaching to process 32215
ptrace: Operation not permitted.
</pre>
<p>Module log both allowed and denied <em>ptrace()</em> calls. Allowed traces as logged as:</p>
<pre>
Mar 11 19:14:48 ghost kernel: [ 6445.524669] sptrace: ptrace() by (ltrace:27558) UID(1000) EUID(1000), parent (ltrace:27557) UID(1000) EUID(1000)
Mar 11 19:14:48 ghost kernel: [ 6445.525460] sptrace: ptrace() by (ltrace:27557) UID(1000) EUID(1000), parent (tcsh:26606) UID(1000) EUID(1000)
</pre>
<p>By default <strong>sptrace</strong> deny access to <em>ptrace()</em> to all non root users (GID != 0). Root group (or wheel) is allowed to use this call. To disable tracing for all users, including those in root group pass parameter <strong>ptrace_group=-1</strong>, e.g.:</p>
<pre>
$ insmod ./sptrace.ko ptrace_group=-1
</pre>
<p>Download: <a href="http://www.burghardt.pl/files/sptrace-1.4.2.tar.gz">sptrace-1.4.2.tar.gz</a> (<a href="http://www.burghardt.pl/files/sptrace-1.4.2.tar.gz.asc">.asc</a>)</p>
<p>md5sum: 9a23198cbdcd256b11e2b0dc2c03b331<br />
sha1sum: 458f9b15e9a5b02cd18759b6b09a4b41d062d7cd</p>
]]></content:encoded>
			<wfw:commentRss>http://blog.burghardt.pl/2009/03/sptrace-142-released/feed/</wfw:commentRss>
		<slash:comments>0</slash:comments>
		</item>
		<item>
		<title>Keep Doxyfile in sync with Autoconf</title>
		<link>http://blog.burghardt.pl/2009/03/keep-doxyfile-in-sync-with-autoconf/</link>
		<comments>http://blog.burghardt.pl/2009/03/keep-doxyfile-in-sync-with-autoconf/#comments</comments>
		<pubDate>Wed, 04 Mar 2009 19:37:16 +0000</pubDate>
		<dc:creator>Krzysztof Burghardt</dc:creator>
				<category><![CDATA[English]]></category>
		<category><![CDATA[Software]]></category>
		<category><![CDATA[Autoconf]]></category>
		<category><![CDATA[Doxyfile]]></category>
		<category><![CDATA[Doxygen]]></category>

		<guid isPermaLink="false">http://www.burghardt.pl/?p=284</guid>
		<description><![CDATA[<p>Generating Doxygen configuration file &#8211; Doxyfile from Autoconf is simple and helps to avoid duplication of version numbers, input and output directories and packages names. Doxyfile can be generated like Makefiles from Doxyfile.in by configure script.</p>
<p></p>
<p>First generate Doxyfile skeleton like usual:</p>

$ doxygen -g Doxyfile.in

<p>Then open Doxyfile.in in $EDITOR and set following variables:</p>
PROJECT_NAME &#160; &#160; &#160; &#160; [...]]]></description>
			<content:encoded><![CDATA[<p>Generating Doxygen configuration file &#8211; <em>Doxyfile</em> from Autoconf is simple and helps to avoid duplication of version numbers, input and output directories and packages names. <em>Doxyfile</em> can be generated like Makefiles from <em>Doxyfile.in</em> by <em>configure</em> script.</p>
<p><span id="more-284"></span></p>
<p>First generate <em>Doxyfile</em> skeleton like usual:</p>
<pre>
$ doxygen -g Doxyfile.in
</pre>
<p>Then open <em>Doxyfile.in</em> in $EDITOR and set following variables:</p>
<div class="codecolorer-container make default" style="overflow:auto;white-space:nowrap;border:1px solid #9F9F9F;width:435px;"><div class="make codecolorer" style="padding:5px;font:normal 12px/1.4em Monaco, Lucida Console, monospace;white-space:nowrap">PROJECT_NAME &nbsp; &nbsp; &nbsp; &nbsp; &nbsp; <span style="color: #004400;">=</span> <span style="color: #004400;">@</span>PACKAGE_NAME<span style="color: #004400;">@</span><br />
PROJECT_NUMBER &nbsp; &nbsp; &nbsp; &nbsp; <span style="color: #004400;">=</span> <span style="color: #004400;">@</span>VERSION<span style="color: #004400;">@</span><br />
<br />
INPUT &nbsp; &nbsp; &nbsp; &nbsp; &nbsp; &nbsp; &nbsp; &nbsp; &nbsp;<span style="color: #004400;">=</span> <span style="color: #004400;">@</span>top_srcdir<span style="color: #004400;">@</span><br />
OUTPUT_DIRECTORY &nbsp; &nbsp; &nbsp; <span style="color: #004400;">=</span> <span style="color: #004400;">@</span>top_builddir<span style="color: #004400;">@/</span>doc<br />
<br />
RECURSIVE &nbsp; &nbsp; &nbsp; &nbsp; &nbsp; &nbsp; &nbsp;<span style="color: #004400;">=</span> YES</div></div>
<p>Finally add <em>Doxyfile</em> to <em>configure.ac</em> (or .in if you prefer .in convention):</p>
<div class="codecolorer-container make default" style="overflow:auto;white-space:nowrap;border:1px solid #9F9F9F;width:435px;"><div class="make codecolorer" style="padding:5px;font:normal 12px/1.4em Monaco, Lucida Console, monospace;white-space:nowrap">AC_CONFIG_FILES<span style="color: #004400;">&#40;</span><span style="color: #004400;">&#91;</span>Makefile<br />
&nbsp; &nbsp; &nbsp; &nbsp; &nbsp; &nbsp; &nbsp; &nbsp; &nbsp;<span style="color: #004400;">...</span><br />
&nbsp; &nbsp; &nbsp; &nbsp; &nbsp; &nbsp; &nbsp; &nbsp; &nbsp;Doxyfile<br />
&nbsp; &nbsp; &nbsp; &nbsp; &nbsp; &nbsp; &nbsp; &nbsp; <span style="color: #004400;">&#93;</span><span style="color: #004400;">&#41;</span><br />
AC_OUTPUT</div></div>
<p>Recreate <em>configure</em> script and run it (just run &#8220;make&#8221; and it will do all the magic for you).</p>
<p>Next time you change version, package name or anything else in Autoconf <em>Doxyfile</em> will be recreated with updated values.</p>
]]></content:encoded>
			<wfw:commentRss>http://blog.burghardt.pl/2009/03/keep-doxyfile-in-sync-with-autoconf/feed/</wfw:commentRss>
		<slash:comments>0</slash:comments>
		</item>
		<item>
		<title>ClamFS 1.0.0 has been released</title>
		<link>http://blog.burghardt.pl/2009/02/clamfs-100-has-been-released/</link>
		<comments>http://blog.burghardt.pl/2009/02/clamfs-100-has-been-released/#comments</comments>
		<pubDate>Sun, 08 Feb 2009 14:18:45 +0000</pubDate>
		<dc:creator>Krzysztof Burghardt</dc:creator>
				<category><![CDATA[English]]></category>
		<category><![CDATA[Linux]]></category>
		<category><![CDATA[Security]]></category>
		<category><![CDATA[Software]]></category>
		<category><![CDATA[ClamAV]]></category>
		<category><![CDATA[ClamFS]]></category>
		<category><![CDATA[Samba]]></category>
		<category><![CDATA[WINE]]></category>

		<guid isPermaLink="false">http://www.burghardt.pl/?p=273</guid>
		<description><![CDATA[<p>ClamFS 1.0.0 has been released yesterday. It contains some new features that might be quite interesting for its users.</p>
<p></p>
Completed clamd results caching
<p>This was a long waiting feature. Version 0.9.1 cache only information about clean files. Infected files was scanned on every access. Starting from version 1.0.0 information about both clean and infected files are kept in [...]]]></description>
			<content:encoded><![CDATA[<p><a href="http://clamfs.sourceforge.net/">ClamFS</a> <a href="http://freshmeat.net/releases/293686/">1.0.0</a> has been released yesterday. It contains some new features that might be quite interesting for its users.</p>
<p><span id="more-273"></span></p>
<h2>Completed clamd results caching</h2>
<p>This was a long waiting feature. Version 0.9.1 cache only information about clean files. Infected files was scanned on every access. Starting from version 1.0.0 information about both clean and infected files are kept in cache while files that cannot be scanned (mostly because of permission problems) are discarded from cache.</p>
<h2>Starting without clamd available</h2>
<p>A new &#8220;check&#8221; option was added to allow you to mount a ClamFS file system when clamd is not available, such as during an early stage of the boot process. To disable ClamAV Daemon (clamd) check on ClamFS startup set option check to no:</p>
<div class="codecolorer-container xml default" style="overflow:auto;white-space:nowrap;border:1px solid #9F9F9F;width:435px;"><div class="xml codecolorer" style="padding:5px;font:normal 12px/1.4em Monaco, Lucida Console, monospace;white-space:nowrap"><span style="color: #009900;"><span style="color: #000000; font-weight: bold;">&lt;clamd</span> <span style="color: #000066;">socket</span>=<span style="color: #ff0000;">&quot;/var/run/clamav/clamd.ctl&quot;</span> <span style="color: #000066;">check</span>=<span style="color: #ff0000;">&quot;no&quot;</span> <span style="color: #000000; font-weight: bold;">/&gt;</span></span></div></div>
<h3>Mounting file systems from /etc/fstab</h3>
<p>With &#8220;check=no&#8221; mounting ClamFS file systems form <em>/etc/fstab</em> is possible using fuse mount helper (<em>/sbin/mount.fuse</em>). ClamFS will be started on boot with configuration file defined here provided as its argument. Simple definition of ClamFS mount point in <em>/etc/fstab</em> looks like:</p>
<div class="codecolorer-container text default" style="overflow:auto;white-space:nowrap;border:1px solid #9F9F9F;width:435px;"><div class="text codecolorer" style="padding:5px;font:normal 12px/1.4em Monaco, Lucida Console, monospace;white-space:nowrap">clamfs#/etc/clamfs/share.xml &nbsp;/clamfs/share &nbsp;fuse &nbsp;defaults &nbsp;0 &nbsp;0</div></div>
<h2>Read-only mounts</h2>
<p>The &#8220;readonly&#8221; option was added to the filesystem options allowing you to create a read-only protected file system. Just extend filesystem definition in config file with readonly option set to yes:</p>
<div class="codecolorer-container xml default" style="overflow:auto;white-space:nowrap;border:1px solid #9F9F9F;width:435px;"><div class="xml codecolorer" style="padding:5px;font:normal 12px/1.4em Monaco, Lucida Console, monospace;white-space:nowrap"><span style="color: #009900;"><span style="color: #000000; font-weight: bold;">&lt;filesystem</span> <span style="color: #000066;">root</span>=<span style="color: #ff0000;">&quot;/share&quot;</span> <span style="color: #000066;">mountpoint</span>=<span style="color: #ff0000;">&quot;/clamfs/share&quot;</span> <span style="color: #000066;">readonly</span>=<span style="color: #ff0000;">&quot;yes&quot;</span> <span style="color: #000000; font-weight: bold;">/&gt;</span></span></div></div>
<h2>File system and cache statistics</h2>
<p>ClamFS has file system statistics that allow you to monitor and tune its performance. Statistics module keep track of file system usage and cache hits. Stats module is configured with &#8220;stats&#8221; tag. It can dump statistics periodically and on ClamFS dismount:</p>
<div class="codecolorer-container xml default" style="overflow:auto;white-space:nowrap;border:1px solid #9F9F9F;width:435px;"><div class="xml codecolorer" style="padding:5px;font:normal 12px/1.4em Monaco, Lucida Console, monospace;white-space:nowrap"><span style="color: #009900;"><span style="color: #000000; font-weight: bold;">&lt;stats</span> <span style="color: #000066;">atexit</span>=<span style="color: #ff0000;">&quot;yes&quot;</span> <span style="color: #000066;">every</span>=<span style="color: #ff0000;">&quot;3600&quot;</span> <span style="color: #000000; font-weight: bold;">/&gt;</span></span></div></div>
<p>Statistics are dumped to configured logging target. Here is an example of such statistics dumped to syslog:</p>
<pre>
Feb  8 14:52:51 ghost clamfs: --- begin of statistics ---
Feb  8 14:52:51 ghost clamfs: Early cache hit: 1038
Feb  8 14:52:51 ghost clamfs: Early cache miss: 1030
Feb  8 14:52:51 ghost clamfs: Late cache hit: 1038
Feb  8 14:52:51 ghost clamfs: Late cache miss: 0
Feb  8 14:52:51 ghost clamfs: Whitelist hit: 10
Feb  8 14:52:51 ghost clamfs: Blacklist hit: 108
Feb  8 14:52:51 ghost clamfs: Files bigger than maximal-size: 3
Feb  8 14:52:51 ghost clamfs: open() function called 2081 times (allowed: 1803, denied: 278)
Feb  8 14:52:51 ghost clamfs: Scan failed 278 times
Feb  8 14:52:51 ghost clamfs: --- end of statistics ---
</pre>
<h2>Better default extension blacklist</h2>
<p>Default blacklist in configuration file was extended. I advise all users to incorporate <a href="http://clamfs.svn.sourceforge.net/viewvc/clamfs/tags/clamfs-1.0.0/doc/clamfs.xml?view=markup">blacklist from version 1.0.0</a> into their configuration files.</p>
]]></content:encoded>
			<wfw:commentRss>http://blog.burghardt.pl/2009/02/clamfs-100-has-been-released/feed/</wfw:commentRss>
		<slash:comments>13</slash:comments>
		</item>
		<item>
		<title>Multiple FreeBSD jails sharing one IP address</title>
		<link>http://blog.burghardt.pl/2009/01/multiple-freebsd-jails-sharing-one-ip-address/</link>
		<comments>http://blog.burghardt.pl/2009/01/multiple-freebsd-jails-sharing-one-ip-address/#comments</comments>
		<pubDate>Sat, 10 Jan 2009 22:19:35 +0000</pubDate>
		<dc:creator>Krzysztof Burghardt</dc:creator>
				<category><![CDATA[English]]></category>
		<category><![CDATA[FreeBSD]]></category>
		<category><![CDATA[Internet]]></category>
		<category><![CDATA[Security]]></category>
		<category><![CDATA[ezjail]]></category>
		<category><![CDATA[jail]]></category>
		<category><![CDATA[PF]]></category>

		<guid isPermaLink="false">http://www.burghardt.pl/?p=203</guid>
		<description><![CDATA[<p>If you want to use multiple jails on FreeBSD with only one external IP addresses you may set up all jails on private addressed with little help of loopback interface, NAT and PF.</p>
<p></p>
Networking
<p>Each jail requires one IP address. First create lo1 loopback interface and assign IPs to it:</p>

# ifconfig lo1 create
# ifconfig lo1 inet 10.0.0.1 netmask [...]]]></description>
			<content:encoded><![CDATA[<p>If you want to use multiple jails on FreeBSD with only one external IP addresses you may set up all jails on private addressed with little help of <a href="http://en.wikipedia.org/wiki/Loopback">loopback</a> interface, <a href="http://en.wikipedia.org/wiki/Network_Address_Translation">NAT</a> and <a href="http://en.wikipedia.org/wiki/PF_(firewall)">PF</a>.</p>
<p><span id="more-203"></span></p>
<h2>Networking</h2>
<p>Each jail requires one IP address. First create lo1 loopback interface and assign IPs to it:</p>
<pre>
# ifconfig lo1 create
# ifconfig lo1 inet 10.0.0.1 netmask 255.255.255.0 alias
# ifconfig lo1 inet 10.0.0.2 netmask 255.255.255.0 alias
...
</pre>
<p>To make this permanent add following lines to <em>/etc/rc.conf</em>:</p>
<div class="codecolorer-container bash default" style="overflow:auto;white-space:nowrap;border:1px solid #9F9F9F;width:435px;"><div class="bash codecolorer" style="padding:5px;font:normal 12px/1.4em Monaco, Lucida Console, monospace;white-space:nowrap"><span style="color: #007800;">cloned_interfaces</span>=<span style="color: #ff0000;">&quot;lo1&quot;</span><br />
<span style="color: #007800;">ifconfig_lo1</span>=<span style="color: #ff0000;">&quot;inet 10.0.0.254 netmask 255.255.255.0&quot;</span><br />
<span style="color: #007800;">ifconfig_lo1_alias0</span>=<span style="color: #ff0000;">&quot;inet 10.0.0.1 netmask 255.255.255.0&quot;</span><br />
...</div></div>
<p>Now configure port redirection (forwarding) from your IP to your jails&#8217;s IPs. Here is my <a href="http://www.openbsd.org/faq/pf/index.html">PF</a> line (add it to <em>/etc/pf.conf</em>):</p>
<div class="codecolorer-container text default" style="overflow:auto;white-space:nowrap;border:1px solid #9F9F9F;width:435px;"><div class="text codecolorer" style="padding:5px;font:normal 12px/1.4em Monaco, Lucida Console, monospace;white-space:nowrap">rdr on re0 proto tcp from any to ext._ip port http -&gt; 10.0.0.1 port http<br />
rdr on re0 proto tcp from any to ext._ip port ircd -&gt; 10.0.0.2 port ircd<br />
...</div></div>
<p>If jails need network access (e.g. to download ports) create <a href="http://en.wikipedia.org/wiki/Network_address_translation">NAT</a> on your external network interface:</p>
<div class="codecolorer-container text default" style="overflow:auto;white-space:nowrap;border:1px solid #9F9F9F;width:435px;"><div class="text codecolorer" style="padding:5px;font:normal 12px/1.4em Monaco, Lucida Console, monospace;white-space:nowrap">nat on re0 from lo1:network to any -&gt; (re0)</div></div>
<p>Finally reload PF rules:</p>
<pre>
# pfctl -d
# pfctl -e -f /etc/pf.conf
</pre>
<h2>Ezjail</h2>
<p>Install <strong>ezjail</strong> from <em>/usr/ports/sysutils/ezjail</em>:</p>
<pre>
# cd /usr/ports/sysutils/ezjail
# make install clean
</pre>
<p>After ezjail installation create base jail. This jail is used as skeleton of all jails. Before creating base jail you need to have current FreeBSD sources in <em>/usr/src</em>. If you have built them add <strong>-i</strong> option to update command to prevent (re)building them:</p>
<pre>
# ezjail-admin update
</pre>
<h2>Creating jails</h2>
<p>When basejail is installed we are ready to create jails:</p>
<pre>
# ezjail-admin create -f default apachejail 10.0.0.1
# ezjail-admin create -f default ircjail 10.0.0.2
</pre>
<h2>See also</h2>
<ul>
<li><a href="http://erdgeist.org/arts/software/ezjail/">ezjail &#8211; jail administration framework</a></li>
</ul>
]]></content:encoded>
			<wfw:commentRss>http://blog.burghardt.pl/2009/01/multiple-freebsd-jails-sharing-one-ip-address/feed/</wfw:commentRss>
		<slash:comments>2</slash:comments>
		</item>
	</channel>
</rss>
