<?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>42 &#187; linux</title>
	<atom:link href="http://www.42.mach7x.com/category/linux/feed/" rel="self" type="application/rss+xml" />
	<link>http://www.42.mach7x.com</link>
	<description>Thoughts and tips about programming with Ruby on Rails</description>
	<lastBuildDate>Thu, 09 Sep 2010 09:28:07 +0000</lastBuildDate>
	<language>en</language>
	<sy:updatePeriod>hourly</sy:updatePeriod>
	<sy:updateFrequency>1</sy:updateFrequency>
	<generator>http://wordpress.org/?v=3.0.1</generator>
		<item>
		<title>Rails Passenger Staging environment problem in Dreamhost</title>
		<link>http://www.42.mach7x.com/2010/09/09/rails-passenger-staging-environment-problem-in-dreamhost/</link>
		<comments>http://www.42.mach7x.com/2010/09/09/rails-passenger-staging-environment-problem-in-dreamhost/#comments</comments>
		<pubDate>Thu, 09 Sep 2010 09:28:07 +0000</pubDate>
		<dc:creator>kosmas</dc:creator>
				<category><![CDATA[Apache]]></category>
		<category><![CDATA[Dreamhost]]></category>
		<category><![CDATA[Phusion Passenger]]></category>
		<category><![CDATA[linux]]></category>
		<category><![CDATA[ruby on rails]]></category>
		<category><![CDATA[apache]]></category>
		<category><![CDATA[Passenger]]></category>
		<category><![CDATA[phusion passenger]]></category>
		<category><![CDATA[Staging]]></category>

		<guid isPermaLink="false">http://www.42.mach7x.com/?p=226</guid>
		<description><![CDATA[Problem You want to deploy your rails application using Passenger in Dreamhost, but on a staging environment. It doesn&#8217;t work just changing your Capistrano recipe or your environment files, as the default environment for passenger is &#8216;production&#8217;. Solution Looking at the Passenger documentation here, there are four different ways of achieving that by changing the [...]]]></description>
			<content:encoded><![CDATA[<p><strong>Problem</strong><br />
You want to deploy your rails application using Passenger in Dreamhost, but on a staging environment. It doesn&#8217;t work just changing your Capistrano recipe or your environment files, as the default environment for passenger is &#8216;production&#8217;.</p>
<p><strong>Solution</strong><br />
Looking at the Passenger documentation <a href="http://www.modrails.com/documentation/Users%20guide%20Apache.html#rails_env">here</a>, there are four different ways of achieving that by changing the RailsEnv option. If you don&#8217;t want to change the Apache configuration files, and as long as the option AllowOverride is on (which should be on Dreamhost), then you would need to create an .htaccess file in your application&#8217;s public folder with the following:</p>
<p><span class="code">RailsEnv staging</span> </p>
]]></content:encoded>
			<wfw:commentRss>http://www.42.mach7x.com/2010/09/09/rails-passenger-staging-environment-problem-in-dreamhost/feed/</wfw:commentRss>
		<slash:comments>0</slash:comments>
		</item>
		<item>
		<title>Video playing too fast in mplayer (Mandriva)</title>
		<link>http://www.42.mach7x.com/2010/09/06/video-playing-too-fast-in-mplayer-mandriva/</link>
		<comments>http://www.42.mach7x.com/2010/09/06/video-playing-too-fast-in-mplayer-mandriva/#comments</comments>
		<pubDate>Mon, 06 Sep 2010 13:16:52 +0000</pubDate>
		<dc:creator>kosmas</dc:creator>
				<category><![CDATA[Mandriva]]></category>
		<category><![CDATA[linux]]></category>
		<category><![CDATA[Mplayer]]></category>
		<category><![CDATA[Video]]></category>

		<guid isPermaLink="false">http://www.42.mach7x.com/?p=222</guid>
		<description><![CDATA[Problem The video playback in mplayer (or any other media player), in Mandriva 2010.0 plays too fast. Solution According to the errata in the Mandriva website here you only have to add the following to your ~/.mplayer/config file: vo=x11]]></description>
			<content:encoded><![CDATA[<p><strong>Problem</strong><br />
The video playback in mplayer (or any other media player), in Mandriva 2010.0 plays too fast.</p>
<p><strong>Solution</strong><br />
According to the errata in the Mandriva website <a href="http://wiki.mandriva.com/en/2009.1_Errata">here</a> you only have to add the following to your ~/.mplayer/config file:</p>
<p><span class="code"><br />
 vo=x11<br />
</span></p>
]]></content:encoded>
			<wfw:commentRss>http://www.42.mach7x.com/2010/09/06/video-playing-too-fast-in-mplayer-mandriva/feed/</wfw:commentRss>
		<slash:comments>0</slash:comments>
		</item>
		<item>
		<title>Dreamhost &#8211; SquirrelMail &#8211; old-messages folder</title>
		<link>http://www.42.mach7x.com/2010/08/05/dreamhost-squirrelmail-old-messages-folder/</link>
		<comments>http://www.42.mach7x.com/2010/08/05/dreamhost-squirrelmail-old-messages-folder/#comments</comments>
		<pubDate>Thu, 05 Aug 2010 17:14:50 +0000</pubDate>
		<dc:creator>kosmas</dc:creator>
				<category><![CDATA[Dreamhost]]></category>
		<category><![CDATA[linux]]></category>
		<category><![CDATA[email]]></category>
		<category><![CDATA[old-messages]]></category>
		<category><![CDATA[squirrelmail]]></category>

		<guid isPermaLink="false">http://www.42.mach7x.com/?p=210</guid>
		<description><![CDATA[Problem You have left a message in a squirrel mail account in dreamhost for a long time and it gets archived by dreamhost. According to the dreamhost you should be able to get to your archived messages, by looking at the old-messages folder. The problem is that just by logging in to squirrel mail the [...]]]></description>
			<content:encoded><![CDATA[<p><strong>Problem</strong><br />
You have left a message in a squirrel mail account in dreamhost for a long time and it gets archived by dreamhost. According to the dreamhost you should be able to get to your archived messages, by looking at the old-messages folder.<br />
The problem is that just by logging in to squirrel mail the folder doesn&#8217;t get displayed on the left hand side.</p>
<p><strong>Solution</strong><br />
Log on to squirrel mail and go to &#8216;Folders&#8217; menu at the top.<br />
In the &#8216;Create Folder&#8217; put &#8216;test&#8217; or anything that you would like in the text box, and make sure that in the dropdown box you select &#8216;INBOX.old-messages&#8217;, so your newly created folder is a subfolder of the &#8216;inbox/old-messages&#8217; folder.<br />
Create the subfolder, refresh the page, and in your left hand the old-messages folder should appear.</p>
]]></content:encoded>
			<wfw:commentRss>http://www.42.mach7x.com/2010/08/05/dreamhost-squirrelmail-old-messages-folder/feed/</wfw:commentRss>
		<slash:comments>0</slash:comments>
		</item>
		<item>
		<title>Thunderbird &#8211; GoogleMail</title>
		<link>http://www.42.mach7x.com/2010/07/21/thunderbird-googlemail/</link>
		<comments>http://www.42.mach7x.com/2010/07/21/thunderbird-googlemail/#comments</comments>
		<pubDate>Wed, 21 Jul 2010 08:27:50 +0000</pubDate>
		<dc:creator>kosmas</dc:creator>
				<category><![CDATA[Dreamhost]]></category>
		<category><![CDATA[linux]]></category>
		<category><![CDATA[Google]]></category>
		<category><![CDATA[Thunderbird]]></category>

		<guid isPermaLink="false">http://www.42.mach7x.com/?p=207</guid>
		<description><![CDATA[Problem You want to add the Google calendar tab in your thunderbird but you don&#8217;t want to use the standard google mail calendar, but the one setup for your domain. Solution Install the Google Calendar add on in Thunderbird: Tools -> Addons -> Get Add-ons and then search for Calendar (Google Calendar Tab) The when [...]]]></description>
			<content:encoded><![CDATA[<p><strong>Problem</strong><br />
You want to add the Google calendar tab in your thunderbird but you don&#8217;t want to use the standard google mail calendar, but the one setup for your domain.</p>
<p><strong>Solution</strong><br />
Install the Google Calendar add on in Thunderbird:</p>
<p>Tools -> Addons -> Get Add-ons and then search for Calendar (Google Calendar Tab)</p>
<p>The when thunderbird is restarted go and change the default domain for logging in to the calender in:</p>
<p>Tools &#8211; Add-ons -> Extensions</p>
<p>and select the Preferences in the Google Calendar Tab.</p>
<p>from there select the &#8216;Google Apps for your domain&#8217; and then change the URL into something like:</p>
<p>&#8216;http://www.google.com/calendar/hosted/your_domain_hosted_with_google</p>
]]></content:encoded>
			<wfw:commentRss>http://www.42.mach7x.com/2010/07/21/thunderbird-googlemail/feed/</wfw:commentRss>
		<slash:comments>0</slash:comments>
		</item>
		<item>
		<title>Syncing files between PCs with rsync and ssh</title>
		<link>http://www.42.mach7x.com/2010/07/15/syncing-files-between-pcs-with-rsync-and-ssh/</link>
		<comments>http://www.42.mach7x.com/2010/07/15/syncing-files-between-pcs-with-rsync-and-ssh/#comments</comments>
		<pubDate>Thu, 15 Jul 2010 12:30:38 +0000</pubDate>
		<dc:creator>kosmas</dc:creator>
				<category><![CDATA[linux]]></category>
		<category><![CDATA[rsync]]></category>
		<category><![CDATA[ssh]]></category>

		<guid isPermaLink="false">http://www.42.mach7x.com/?p=205</guid>
		<description><![CDATA[Problem You want to mirror directories from one PC to another, using rsync and ssh. Solution Use the following: rsync -avc /path/to/source_folder/ user_name@remote_pc:/path/to/destination_folder/]]></description>
			<content:encoded><![CDATA[<p><strong>Problem</strong><br />
You want to mirror directories from one PC to another, using rsync and ssh.</p>
<p><strong>Solution</strong><br />
Use the following:<br />
<span class="code">rsync -avc /path/to/source_folder/ user_name@remote_pc:/path/to/destination_folder/</p>
]]></content:encoded>
			<wfw:commentRss>http://www.42.mach7x.com/2010/07/15/syncing-files-between-pcs-with-rsync-and-ssh/feed/</wfw:commentRss>
		<slash:comments>0</slash:comments>
		</item>
		<item>
		<title>Help! I&#8217;m getting the message &#8220;libMagickWand.so.1: cannot open shared object file: No such file or directory&#8221; I know ImageMagick is installed! What should I do?</title>
		<link>http://www.42.mach7x.com/2010/07/13/help-im-getting-the-message-libmagickwand-so-1-cannot-open-shared-object-file-no-such-file-or-directory-i-know-imagemagick-is-installed-what-should-i-do/</link>
		<comments>http://www.42.mach7x.com/2010/07/13/help-im-getting-the-message-libmagickwand-so-1-cannot-open-shared-object-file-no-such-file-or-directory-i-know-imagemagick-is-installed-what-should-i-do/#comments</comments>
		<pubDate>Tue, 13 Jul 2010 16:20:01 +0000</pubDate>
		<dc:creator>kosmas</dc:creator>
				<category><![CDATA[linux]]></category>
		<category><![CDATA[ruby on rails]]></category>
		<category><![CDATA[LD_LIBRARY_PATH]]></category>
		<category><![CDATA[Rmagick]]></category>
		<category><![CDATA[shared libraries]]></category>

		<guid isPermaLink="false">http://www.42.mach7x.com/?p=203</guid>
		<description><![CDATA[Problem Cannot install RMagick as there is an error about nob being able to find some shared libraries. Solution After reading the RMagick installation FAQ it seem there is a problem with the LD_LIBRARY_PATH that cannot find the needed libraries as they are installed in /usr/local/lib instead of /usr/lib. Doing a quick search revealed that [...]]]></description>
			<content:encoded><![CDATA[<p><strong>Problem</strong><br />
Cannot install RMagick as there is an error about nob being able to find some shared libraries.</p>
<p><strong>Solution</strong><br />
After reading the RMagick installation FAQ it seem there is a problem with the LD_LIBRARY_PATH that cannot find the needed libraries as they are installed in /usr/local/lib instead of /usr/lib.<br />
Doing a quick search revealed that people suggest that the LD_LIBRARY_PATH shouldn&#8217;t be changed, for various reasons.<br />
So, the quick solution is to create a couple of symbolic links for the libraries that cannot be found, ie:</p>
<p><span class="code">sudo ln -s /usr/local/lib/libMagickWand.so.4 /usr/lib/libMagickWand.so.4<br />
ln -s /usr/local/lib/libMagickCore.so.4 /usr/lib/libMagickCore.so.4</span></p>
]]></content:encoded>
			<wfw:commentRss>http://www.42.mach7x.com/2010/07/13/help-im-getting-the-message-libmagickwand-so-1-cannot-open-shared-object-file-no-such-file-or-directory-i-know-imagemagick-is-installed-what-should-i-do/feed/</wfw:commentRss>
		<slash:comments>0</slash:comments>
		</item>
		<item>
		<title>ATI Radeon HD-4350 Mandriva 2010 Dual Monitor</title>
		<link>http://www.42.mach7x.com/2010/05/14/ati-radeon-hd-43500-mandriva-201-dual-monitor/</link>
		<comments>http://www.42.mach7x.com/2010/05/14/ati-radeon-hd-43500-mandriva-201-dual-monitor/#comments</comments>
		<pubDate>Fri, 14 May 2010 10:47:29 +0000</pubDate>
		<dc:creator>kosmas</dc:creator>
				<category><![CDATA[Mandriva]]></category>
		<category><![CDATA[linux]]></category>
		<category><![CDATA[Dual Monitor]]></category>
		<category><![CDATA[mandriva 2010]]></category>
		<category><![CDATA[Xorg]]></category>
		<category><![CDATA[xranr]]></category>

		<guid isPermaLink="false">http://www.42.mach7x.com/?p=198</guid>
		<description><![CDATA[Problem Trying to get Mandriva 2010 to work on a dual monitor with an ATI Radeon HD 4350. Desktop used is a Dell Vostro 430 and two BenQ G920WL monitors. Solution After reading the articles here and here, the steps required were: Select driver ATI Radeon HD 2000 and later (radeon/fglrx) Don&#8217;t select proprietary driver [...]]]></description>
			<content:encoded><![CDATA[<p><strong>Problem</strong><br />
Trying to get Mandriva 2010 to work on a dual monitor with an ATI Radeon HD 4350. Desktop used is a Dell Vostro 430 and two BenQ G920WL monitors.</p>
<p><strong>Solution</strong><br />
After reading the articles <a href="http://forum.mandriva.com/viewtopic.php?t=110181">here</a> and <a href="http://www.thinkwiki.org/wiki/Xorg_RandR_1.2">here</a>, the steps required were:</p>
<ul>
<li>Select driver ATI Radeon HD 2000 and later (radeon/fglrx)</li>
<li>Don&#8217;t select proprietary driver from next screen</li>
<li>Run xrandr -q to find out the name of the monitors</li>
<li>From the output find out the current resolution (1440&#215;900), names (VGA_1,DVI-I_2/analog) and maximum resolution (1440&#215;900)</li>
<li>Edit the xorg.conf file (/etc/X11/xorg.conf) and add the Virtual 2880 900 (without quotes) underneath the Modes line in the Display Subsection</li>
<li>Save the file and restart the X server</li>
<li>Run again the xrandr -q command and make sure the maximum resolution has changed to 2880&#215;900</li>
<li>Run xrandr &#8211;output DVI-I_2/analog &#8211;auto &#8211;right-of VGA_1 to put one screen next to the other
<li>
<li>Follow the description <a href="http://www.thinkwiki.org/wiki/Xorg_RandR_1.2">here</a> to set it up permanently on login</li>
</ul>
]]></content:encoded>
			<wfw:commentRss>http://www.42.mach7x.com/2010/05/14/ati-radeon-hd-43500-mandriva-201-dual-monitor/feed/</wfw:commentRss>
		<slash:comments>0</slash:comments>
		</item>
		<item>
		<title>Problem with Sansa mp3 player automatic connection in Mandriva</title>
		<link>http://www.42.mach7x.com/2010/04/28/problem-with-sansa-mp3-player-automatic-connection-in-mandriva/</link>
		<comments>http://www.42.mach7x.com/2010/04/28/problem-with-sansa-mp3-player-automatic-connection-in-mandriva/#comments</comments>
		<pubDate>Wed, 28 Apr 2010 23:12:17 +0000</pubDate>
		<dc:creator>kosmas</dc:creator>
				<category><![CDATA[Mandriva]]></category>
		<category><![CDATA[linux]]></category>
		<category><![CDATA[Sansa]]></category>
		<category><![CDATA[USB]]></category>

		<guid isPermaLink="false">http://www.42.mach7x.com/?p=196</guid>
		<description><![CDATA[Problem After an upgrade my Sansa E260 is no longer automatically recognised in Mandriva and looking at the /var/log/messages displays the error: reset high speed USB device using ehci_hcd and address 5 Solution Run as su the following (maybe a couple of times), while the sansa is connected: sudo rmmod ehci_hcd sudo modprobe ehci_hcd]]></description>
			<content:encoded><![CDATA[<p><Strong>Problem</strong><br />
After an upgrade my Sansa E260 is no longer automatically recognised in Mandriva and looking at the /var/log/messages displays the error:<br />
<span class="code">reset high speed USB device using ehci_hcd and address 5</span></p>
<p><Strong>Solution</strong><br />
Run as su the following (maybe a couple of times), while the sansa is connected:<br />
<span class="code">sudo rmmod ehci_hcd<br />
sudo modprobe ehci_hcd</span></p>
]]></content:encoded>
			<wfw:commentRss>http://www.42.mach7x.com/2010/04/28/problem-with-sansa-mp3-player-automatic-connection-in-mandriva/feed/</wfw:commentRss>
		<slash:comments>0</slash:comments>
		</item>
		<item>
		<title>NoMethodError (undefined method `refresh_token&#8217; for #):</title>
		<link>http://www.42.mach7x.com/2010/03/26/nomethoderror-undefined-method-refresh_token-for/</link>
		<comments>http://www.42.mach7x.com/2010/03/26/nomethoderror-undefined-method-refresh_token-for/#comments</comments>
		<pubDate>Fri, 26 Mar 2010 15:52:48 +0000</pubDate>
		<dc:creator>kosmas</dc:creator>
				<category><![CDATA[Mandriva]]></category>
		<category><![CDATA[linux]]></category>
		<category><![CDATA[ruby on rails]]></category>
		<category><![CDATA[authentication]]></category>
		<category><![CDATA[Rails]]></category>

		<guid isPermaLink="false">http://www.42.mach7x.com/?p=187</guid>
		<description><![CDATA[Problem When you get the above error you cannot login to your application. Solution You will need to delete the cookies for the authentication, so in Firefox (Linux) go to Preferences, remove individual cookies for the specific domain.]]></description>
			<content:encoded><![CDATA[<p><strong>Problem</strong><br />
When you get the above error you cannot login to your application.</p>
<p><strong>Solution</strong><br />
You will need to delete the cookies for the authentication, so in Firefox (Linux) go to Preferences, remove individual cookies for the specific domain.</p>
]]></content:encoded>
			<wfw:commentRss>http://www.42.mach7x.com/2010/03/26/nomethoderror-undefined-method-refresh_token-for/feed/</wfw:commentRss>
		<slash:comments>0</slash:comments>
		</item>
		<item>
		<title>undefined method &#8216;remap&#8217; for class &#8216;Magick::Image&#8217;</title>
		<link>http://www.42.mach7x.com/2010/03/18/undefined-method-remap-for-class-magickimage/</link>
		<comments>http://www.42.mach7x.com/2010/03/18/undefined-method-remap-for-class-magickimage/#comments</comments>
		<pubDate>Thu, 18 Mar 2010 10:13:10 +0000</pubDate>
		<dc:creator>kosmas</dc:creator>
				<category><![CDATA[Dreamhost]]></category>
		<category><![CDATA[linux]]></category>
		<category><![CDATA[ruby on rails]]></category>
		<category><![CDATA[ImageMagick]]></category>
		<category><![CDATA[Magick]]></category>
		<category><![CDATA[Remap]]></category>
		<category><![CDATA[Rmagick]]></category>

		<guid isPermaLink="false">http://www.42.mach7x.com/?p=180</guid>
		<description><![CDATA[Problem You have just deployed your rails application to dreamhost but you are getting this error from passenger. Solution There was a change in the ImageMagic between versions 6.4.3 and 6.4.4 from the affinity function to remap. If you don&#8217;t want, or don&#8217;t have time to recompile the ImageMagick and install the rmagick gem, you [...]]]></description>
			<content:encoded><![CDATA[<p><strong>Problem</strong><br />
You have just deployed your rails application to dreamhost but you are getting this error from passenger.</p>
<p><strong>Solution</strong><br />
There was a change in the ImageMagic between versions 6.4.3 and 6.4.4 from the affinity function to remap.<br />
If you don&#8217;t want, or don&#8217;t have time to recompile the ImageMagick and install the rmagick gem, you can comment out the two declarations for the alias functions, located around lines 782 and 1525 in the file rmagick-2.12.2/lib/RMagick.rb:</p>
<p><span class="code">alias_method :affinity, :remap</span></p>
]]></content:encoded>
			<wfw:commentRss>http://www.42.mach7x.com/2010/03/18/undefined-method-remap-for-class-magickimage/feed/</wfw:commentRss>
		<slash:comments>0</slash:comments>
		</item>
	</channel>
</rss>
