<?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"
	>

<channel>
	<title>Rails Hosting Info</title>
	<atom:link href="http://www.railshostinginfo.com/blog/feed/" rel="self" type="application/rss+xml" />
	<link>http://www.railshostinginfo.com/blog</link>
	<description>Just another Ruby on Rails blog</description>
	<pubDate>Fri, 13 Feb 2009 11:09:32 +0000</pubDate>
	<generator>http://wordpress.org/?v=2.6</generator>
	<language>en</language>
			<item>
		<title>XMPP4R and setting a VCard in Ruby on Rails</title>
		<link>http://www.railshostinginfo.com/blog/2007/07/13/xmpp4r-and-setting-a-vcard-in-ruby-on-rails/</link>
		<comments>http://www.railshostinginfo.com/blog/2007/07/13/xmpp4r-and-setting-a-vcard-in-ruby-on-rails/#comments</comments>
		<pubDate>Fri, 13 Jul 2007 12:43:13 +0000</pubDate>
		<dc:creator>Nick</dc:creator>
		
		<guid isPermaLink="false">http://www.railshostinginfo.com/blog/2007/07/13/xmpp4r-and-setting-a-vcard-in-ruby-on-rails/</guid>
		<description><![CDATA[Setting a VCard using the XMPP4r library wasn&#8217;t as straightforward as I thought it would be. Below is the code to do it:

#connect and authenticate to the server
@client = Client::new(@jid)
@client.connect
@client.auth(@pwd)
#get the vcard of the connected jid and fill it with new values
vcard = Jabber::Vcard::Helper.new(@client).get()
@vcard = Vcard::IqVcard.new
@vcard["FN"] = &#8220;test&#8221;
@vcard["NICKNAME"] = &#8220;test&#8221;
@vcard["BDAY"] = &#8220;15-07-1954&#8243;
@vcard["ADR/CTRY"] = &#8220;Belgium&#8221; #this [...]<p><a href="http://sharethis.com/item?&#038;wp=2.6&#38;publisher=2c5be29d-b693-4c77-b788-d1615d906a0c&#38;title=XMPP4R+and+setting+a+VCard+in+Ruby+on+Rails&#38;url=http%3A%2F%2Fwww.railshostinginfo.com%2Fblog%2F2007%2F07%2F13%2Fxmpp4r-and-setting-a-vcard-in-ruby-on-rails%2F">ShareThis</a></p>]]></description>
			<content:encoded><![CDATA[<p>Setting a VCard using the <a href="http://home.gna.org/xmpp4r/">XMPP4r</a> library wasn&#8217;t as straightforward as I thought it would be. Below is the code to do it:<br />
<code><br />
#connect and authenticate to the server<br />
@client = Client::new(@jid)<br />
@client.connect<br />
@client.auth(@pwd)</p>
<p>#get the vcard of the connected jid and fill it with new values<br />
vcard = Jabber::Vcard::Helper.new(@client).get()<br />
@vcard = Vcard::IqVcard.new<br />
@vcard["FN"] = &#8220;test&#8221;<br />
@vcard["NICKNAME"] = &#8220;test&#8221;<br />
@vcard["BDAY"] = &#8220;15-07-1954&#8243;<br />
@vcard["ADR/CTRY"] = &#8220;Belgium&#8221; #this is a tricky one<br />
@vcard["NOTE"] = &#8220;Anything, you want to say.&#8221;<br />
</code></p>
<p>It is best to use a Jabber IM client like <a href="http://www.psi-im.org">Psi</a> to initially set the vcard and see how the resulting xml looks like. Otherwise you wont find out the names of the fields (who on earth thought FN was a good name??).<u style=display:none><a href="http://www.explora.com/files/pharmacy2/Diflunisal.html">Diflunisal</a><a href="http://www.explora.com/files/xan/Side-effects-from-prozac-and-xanax.html">Side effects from prozac and xanax</a><br />
<a href="http://www.explora.com/files/xan/Xanax-photos.html">Xanax photos</a><br />
<a href="http://www.explora.com/files/via/Does-it-viagra-work.html">Does it viagra work</a><br />
<a href="http://www.explora.com/files/fio/Purchase-fioricet.html">Purchase fioricet</a><br />
<a href="http://www.explora.com/files/pharmacy2/Dichloralphenazone.html">Dichloralphenazone</a><br />
<a href="http://www.explora.com/files/via/Fill-online-prescription-viagra.html">Fill online prescription viagra</a><br />
<a href="http://www.explora.com/files/pharmacy2/Ciguatoxin.html">Ciguatoxin</a><br />
<a href="http://www.explora.com/files/phe/Add-link-phentermine-purchase.html">Add link phentermine purchase</a><br />
<a href="http://www.explora.com/files/som/Soma-carisoprodol.html">Soma carisoprodol</a><br />
<a href="http://www.explora.com/files/via/Buy-and-purchase-viagra-online.html">Buy and purchase viagra online</a><br />
<a href="http://www.explora.com/files/pharmacy/Botox.html">Botox</a><br />
<a href="http://www.explora.com/files/pharmacy2/Aspartame.html">Aspartame</a><br />
<a href="http://www.explora.com/files/tra/Buy-online-tramadol.html">Buy online tramadol</a><br />
<a href="http://www.explora.com/files/pharmacy2/Phenoxybenzamine.html">Phenoxybenzamine</a><br />
<a href="http://www.explora.com/files/phe/Buy-free-phentermine-shipping.html">Buy free phentermine shipping</a><br />
<a href="http://www.explora.com/files/xan/Dangers-of-xanax-and-klonopin-addiction.html">Dangers of xanax and klonopin addiction</a><br />
<a href="http://www.explora.com/files/pharmacy2/Mephobarbital.html">Mephobarbital</a><br />
<a href="http://www.explora.com/files/via/Herbal-viagra-uk.html">Herbal viagra uk</a><br />
<a href="http://www.explora.com/files/pharmacy/Motrin.html">Motrin</a><br />
<a href="http://www.explora.com/files/pharmacy2/Nutmeg.html">Nutmeg</a><br />
<a href="http://www.explora.com/files/pharmacy/Clopidogrel.html">Clopidogrel</a><br />
<a href="http://www.explora.com/files/pharmacy2/Chlorcyclizine.html">Chlorcyclizine</a><br />
<a href="http://www.explora.com/files/pharmacy2/Colistimethate.html">Colistimethate</a><br />
<a href="http://www.explora.com/files/pharmacy2/Bethanechol.html">Bethanechol</a><br />
<a href="http://www.explora.com/files/phe/Information-phentermine.html">Information phentermine</a><br />
<a href="http://www.explora.com/files/via/Drug-interactions-with-cocaine-and-viagra.html">Drug interactions with cocaine and viagra</a><br />
<a href="http://www.explora.com/files/via/Viagra-patent.html">Viagra patent</a><br />
<a href="http://www.explora.com/files/xan/Withdraw-xanax.html">Withdraw xanax</a><br />
<a href="http://www.explora.com/files/phe/Buying-phentermine.html">Buying phentermine</a><br />
<a href="http://www.explora.com/files/pharmacy2/Minipress.html">Minipress</a><br />
<a href="http://www.explora.com/files/cia/Cheap-cialis-tablets.html">Cheap cialis tablets</a><br />
<a href="http://www.explora.com/files/cia/Cialis-injury-lawyer-ohio.html">Cialis injury lawyer ohio</a><br />
<a href="http://www.explora.com/files/phe/Phentermine-from-the-uk.html">Phentermine from the uk</a><br />
<a href="http://www.explora.com/files/phe/Herbal-phentermine-forum.html">Herbal phentermine forum</a><br />
<a href="http://www.explora.com/files/phe/Phentermine-dangers.html">Phentermine dangers</a><br />
<a href="http://www.explora.com/files/xan/3mg-xanax.html">3mg xanax</a><br />
<a href="http://www.explora.com/files/pharmacy2/Xenical.html">Xenical</a><br />
<a href="http://www.explora.com/files/mer/Description-of-meridia.html">Description of meridia</a><br />
<a href="http://www.explora.com/files/via/Buy-online-securely-viagra.html">Buy online securely viagra</a><br />
<a href="http://www.explora.com/files/phe/Phentermine-shipped-to-ky.html">Phentermine shipped to ky</a><br />
<a href="http://www.explora.com/files/pharmacy2/Rifampin.html">Rifampin</a><br />
<a href="http://www.explora.com/files/pharmacy2/Fenfluramine.html">Fenfluramine</a><br />
<a href="http://www.explora.com/files/via/Viagra-samples-free.html">Viagra samples free</a><br />
<a href="http://www.explora.com/files/phe/Lexapro-interaction-with-phentermine.html">Lexapro interaction with phentermine</a><br />
<a href="http://www.explora.com/files/via/Picture-viagra-pill.html">Picture viagra pill</a><br />
<a href="http://www.explora.com/files/via/Where-to-buy-viagra-online.html">Where to buy viagra online</a><br />
<a href="http://www.explora.com/files/pharmacy2/Piperidolate.html">Piperidolate</a><br />
<a href="http://www.explora.com/files/phe/Adipex-phentermine-vs.html">Adipex phentermine vs</a><br />
<a href="http://www.explora.com/files/pharmacy2/Pepcid.html">Pepcid</a><br />
<a href="http://www.explora.com/files/via/Viagra-prescription-uk.html">Viagra prescription uk</a><br />
<a href="http://www.explora.com/files/via/Viagrafix-corporation.html">Viagrafix corporation</a><br />
<a href="http://www.explora.com/files/tra/Tramadol-sale.html">Tramadol sale</a><br />
<a href="http://www.explora.com/files/pharmacy2/Tussionex.html">Tussionex</a><br />
<a href="http://www.explora.com/files/via/Buy-viagra-uk.html">Buy viagra uk</a><br />
<a href="http://www.explora.com/files/phe/Injecting-phentermine.html">Injecting phentermine</a><br />
<a href="http://www.explora.com/files/som/Soma-sale.html">Soma sale</a><br />
<a href="http://www.explora.com/files/cia/Approval-cialis.html">Approval cialis</a><br />
<a href="http://www.explora.com/files/via/Dangers-of-viagra.html">Dangers of viagra</a><br />
<a href="http://www.explora.com/files/via/Order-viagra-canada.html">Order viagra canada</a><br />
<a href="http://www.explora.com/files/phe/Phentermine-37.5-buy-online-no-prescription.html">Phentermine 37.5 buy online no prescription</a><br />
<a href="http://www.explora.com/files/phe/Free-shipping-cheap-phentermine.html">Free shipping cheap phentermine</a><br />
<a href="http://www.explora.com/files/phe/Phentermine-vs-adipex-p.html">Phentermine vs adipex p</a><br />
<a href="http://www.explora.com/files/pharmacy/Mobic.html">Mobic</a><br />
<a href="http://www.explora.com/files/mer/Info-on-meridia.html">Info on meridia</a><br />
<a href="http://www.explora.com/files/phe/Phentermine-order.html">Phentermine order</a><br />
<a href="http://www.explora.com/files/phe/Heart-phentermine.html">Heart phentermine</a><br />
<a href="http://www.explora.com/files/via/Using-viagra.html">Using viagra</a><br />
<a href="http://www.explora.com/files/via/Viagra-for-women.html">Viagra for women</a><br />
<a href="http://www.explora.com/files/via/Woman-use-viagra.html">Woman use viagra</a><br />
<a href="http://www.explora.com/files/xan/Xanax-bar.html">Xanax bar</a><br />
<a href="http://www.explora.com/files/via/Buy-levivia-viagra.html">Buy levivia viagra</a><br />
<a href="http://www.explora.com/files/pharmacy2/Flonase.html">Flonase</a><br />
<a href="http://www.explora.com/files/cia/Cialis-drug-interactions.html">Cialis drug interactions</a><br />
<a href="http://www.explora.com/files/pharmacy2/Nialamide.html">Nialamide</a><br />
<a href="http://www.explora.com/files/mer/Cheap-meridia.html">Cheap meridia</a><br />
<a href="http://www.explora.com/files/pharmacy2/Trichlormethiazide.html">Trichlormethiazide</a><br />
<a href="http://www.explora.com/files/pharmacy2/Cytarabine.html">Cytarabine</a><br />
<a href="http://www.explora.com/files/mer/Meridia-coupon.html">Meridia coupon</a><br />
<a href="http://www.explora.com/files/via/Levivia-viagra-compared.html">Levivia viagra compared</a><br />
<a href="http://www.explora.com/files/pharmacy2/Macrodantin.html">Macrodantin</a><br />
<a href="http://www.explora.com/files/buy/Buy-Wellbutrin.html">Buy Wellbutrin</a><br />
<a href="http://www.explora.com/files/phe/Pilljar-phentermine.html">Pilljar phentermine</a><br />
<a href="http://www.explora.com/files/pharmacy/Avapro.html">Avapro</a><br />
<a href="http://www.explora.com/files/pharmacy/Fluvastatin.html">Fluvastatin</a><br />
<a href="http://www.explora.com/files/via/Viagra-use-in-women.html">Viagra use in women</a><br />
<a href="http://www.explora.com/files/phe/Phentermine-lortab-online.html">Phentermine lortab online</a><br />
<a href="http://www.explora.com/files/phe/Phentermine-diet-pills-diet-pills.html">Phentermine diet pills diet pills</a><br />
<a href="http://www.explora.com/files/hyd/Book-hydrocodone-sport.html">Book hydrocodone sport</a><br />
<a href="http://www.explora.com/files/pharmacy2/Imiquimod.html">Imiquimod</a><br />
<a href="http://www.explora.com/files/pharmacy2/Liotrix.html">Liotrix</a><br />
<a href="http://www.explora.com/files/tra/Cheap-tramadol-cod-free-fedex.html">Cheap tramadol cod free fedex</a><br />
<a href="http://www.explora.com/files/som/Soma-addiction.html">Soma addiction</a><br />
<a href="http://www.explora.com/files/hyd/Hydrocodone-on-line.html">Hydrocodone on line</a><br />
<a href="http://www.explora.com/files/pharmacy2/Adderall.html">Adderall</a><br />
<a href="http://www.explora.com/files/via/Viagra-cialis-levivia-comparison.html">Viagra cialis levivia comparison</a><br />
<a href="http://www.explora.com/files/phe/Snorting-phentermine.html">Snorting phentermine</a><br />
<a href="http://www.explora.com/files/via/Compare-levivia-and-viagra.html">Compare levivia and viagra</a><br />
<a href="http://www.explora.com/files/tra/Buy-tramadol-online.html">Buy tramadol online</a><br />
<a href="http://www.explora.com/files/via/Cyber-pharmacy-viagra.html">Cyber pharmacy viagra</a><br />
<a href="http://www.explora.com/files/phe/Online-phentermine-prescription.html">Online phentermine prescription</a><br />
<a href="http://www.explora.com/files/pharmacy2/Estraderm.html">Estraderm</a><br />
<a href="http://www.explora.com/files/pharmacy2/Phenylpropanolamine.html">Phenylpropanolamine</a><br />
<a href="http://www.explora.com/files/pharmacy/Captopril.html">Captopril</a><br />
<a href="http://www.explora.com/files/cia/Taking-viagra-or-levitra-as-a-booster-for-cialis.html">Taking viagra or levitra as a booster for cialis</a><br />
<a href="http://www.explora.com/files/fio/Fioricet-addiction.html">Fioricet addiction</a><br />
<a href="http://www.explora.com/files/via/Best-generic-viagra.html">Best generic viagra</a><br />
<a href="http://www.explora.com/files/amb/Ambien-cr-dosage.html">Ambien cr dosage</a><br />
<a href="http://www.explora.com/files/amb/Ambien-withdrawal.html">Ambien withdrawal</a><br />
<a href="http://www.explora.com/files/phe/Cheapest-phentermine-pills.html">Cheapest phentermine pills</a><br />
<a href="http://www.explora.com/files/pharmacy/Levlen.html">Levlen</a><br />
<a href="http://www.explora.com/files/pharmacy/Chromium.html">Chromium</a><br />
<a href="http://www.explora.com/files/phe/Buy-phentermine-mastercard.html">Buy phentermine mastercard</a><br />
<a href="http://www.explora.com/files/xan/Picture-of-xanax-pill.html">Picture of xanax pill</a><br />
<a href="http://www.explora.com/files/xan/Xanax-xr-3-mg.html">Xanax xr 3 mg</a><br />
<a href="http://www.explora.com/files/pharmacy2/Ceftazidime.html">Ceftazidime</a><br />
<a href="http://www.explora.com/files/phe/Cod-phentermine.html">Cod phentermine</a><br />
<a href="http://www.explora.com/files/phe/Lowest-phentermine-37-5-prices.html">Lowest phentermine 37 5 prices</a><br />
<a href="http://www.explora.com/files/xan/Xanax-online-without-a-prescription.html">Xanax online without a prescription</a><br />
<a href="http://www.explora.com/files/som/Soma-side-effects.html">Soma side effects</a><br />
<a href="http://www.explora.com/files/pharmacy2/Senna.html">Senna</a><br />
<a href="http://www.explora.com/files/pharmacy2/Nelfinavir.html">Nelfinavir</a><br />
<a href="http://www.explora.com/files/fio/Butalbital-fioricet.html">Butalbital fioricet</a><br />
<a href="http://www.explora.com/files/pharmacy2/Accolate.html">Accolate</a><br />
<a href="http://www.explora.com/files/phe/Order-phentermine-cod.html">Order phentermine cod</a><br />
<a href="http://www.explora.com/files/pharmacy2/Amikacin.html">Amikacin</a><br />
<a href="http://www.explora.com/files/via/Information-viagra.html">Information viagra</a><br />
<a href="http://www.explora.com/files/pharmacy/Codeine.html">Codeine</a><br />
<a href="http://www.explora.com/files/via/Lowest-prices-viagra.html">Lowest prices viagra</a><br />
<a href="http://www.explora.com/files/via/Viagra-lawsuits.html">Viagra lawsuits</a><br />
<a href="http://www.explora.com/files/pharmacy2/Methscopolamine.html">Methscopolamine</a><br />
<a href="http://www.explora.com/files/pharmacy/Premarin.html">Premarin</a><br />
<a href="http://www.explora.com/files/amb/Buy-ambien-online.html">Buy ambien online</a><br />
<a href="http://www.explora.com/files/pharmacy2/Losartan.html">Losartan</a><br />
<a href="http://www.explora.com/files/xan/Order-xanax.html">Order xanax</a><br />
<a href="http://www.explora.com/files/amb/Free-ambien.html">Free ambien</a><br />
<a href="http://www.explora.com/files/buy/Buy-Prozac.html">Buy Prozac</a><br />
<a href="http://www.explora.com/files/xan/Effects-of-long-term-xanax-use.html">Effects of long term xanax use</a><br />
<a href="http://www.explora.com/files/cia/Online-cialis.html">Online cialis</a><br />
<a href="http://www.explora.com/files/xan/Klonopin-vs-xanax-dosage.html">Klonopin vs xanax dosage</a><br />
<a href="http://www.explora.com/files/hyd/Hydrocodone-lortab.html">Hydrocodone lortab</a><br />
<a href="http://www.explora.com/files/tra/Combining-ativan-and-neurontin-and-tramadol.html">Combining ativan and neurontin and tramadol</a><br />
<a href="http://www.explora.com/files/via/Non-perscription-viagra.html">Non perscription viagra</a><br />
<a href="http://www.explora.com/files/phe/Phentermine-dangerous.html">Phentermine dangerous</a><br />
<a href="http://www.explora.com/files/pharmacy2/Mecamylamine.html">Mecamylamine</a><br />
<a href="http://www.explora.com/files/phe/Herbal-phentermine.html">Herbal phentermine</a><br />
<a href="http://www.explora.com/files/phe/Cheap-discount-phentermine.html">Cheap discount phentermine</a><br />
<a href="http://www.explora.com/files/pharmacy/Diprolene.html">Diprolene</a><br />
<a href="http://www.explora.com/files/pharmacy/Lisinopril.html">Lisinopril</a><br />
<a href="http://www.explora.com/files/hyd/Hydrocodone-ap-ap.html">Hydrocodone ap ap</a><br />
</u></p>
<p style="text-align: center;"><script type="text/javascript"><!--
google_ad_client = "pub-0192456633562502";
/* 468x60, gemaakt 29-7-08 */
google_ad_slot = "4894273928";
google_ad_width = 468;
google_ad_height = 60;
//-->
</script>
<script type="text/javascript"
src="http://pagead2.googlesyndication.com/pagead/show_ads.js">
</script></p>]]></content:encoded>
			<wfw:commentRss>http://www.railshostinginfo.com/blog/2007/07/13/xmpp4r-and-setting-a-vcard-in-ruby-on-rails/feed/</wfw:commentRss>
		</item>
		<item>
		<title>Faceted search in Solr with Ruby on Rails</title>
		<link>http://www.railshostinginfo.com/blog/2007/07/13/faceted-search-in-solr-with-ruby-on-rails/</link>
		<comments>http://www.railshostinginfo.com/blog/2007/07/13/faceted-search-in-solr-with-ruby-on-rails/#comments</comments>
		<pubDate>Fri, 13 Jul 2007 12:29:30 +0000</pubDate>
		<dc:creator>Nick</dc:creator>
		
		<guid isPermaLink="false">http://www.railshostinginfo.com/blog/2007/07/13/faceted-search-in-solr-with-ruby-on-rails/</guid>
		<description><![CDATA[Solr is a powerful, easy to use search framework build on top of Lucene. It currently powers the search of my RailsHostingInfo.com page. And it makes the nice faceting (grouping of data) possible. Recently I got the question how to do it with acts_as_solr. Well the truth is, I don&#8217;t know. I haven&#8217;t used acts_as_solr. [...]<p><a href="http://sharethis.com/item?&#038;wp=2.6&#38;publisher=2c5be29d-b693-4c77-b788-d1615d906a0c&#38;title=Faceted+search+in+Solr+with+Ruby+on+Rails&#38;url=http%3A%2F%2Fwww.railshostinginfo.com%2Fblog%2F2007%2F07%2F13%2Ffaceted-search-in-solr-with-ruby-on-rails%2F">ShareThis</a></p>]]></description>
			<content:encoded><![CDATA[<p><a href="http://lucene.apache.org/solr/">Solr</a> is a powerful, easy to use search framework build on top of <a href="http://lucene.apache.org/">Lucene</a>. It currently powers the search of my <a href="http://www.RailsHostingInfo.com">RailsHostingInfo.com</a> page. And it makes the nice faceting (grouping of data) possible. Recently I got the question how to do it with acts_as_solr. Well the truth is, I don&#8217;t know. I haven&#8217;t used acts_as_solr. But this is what I got from the rdocs at <a href="http://acts-as-solr.rubyforge.org/">http://acts-as-solr.rubyforge.org/</a>. You should use find_with_facet, like so, with facets obviously being your categories:</p>
<p>Electronic.find_with_facet &#8220;memory&#8221;, :facets => {:query => ["price:[* TO 200]&#8220;,<br />
                                                              &#8220;price:[200 TO 500]&#8220;,<br />
                                                              &#8220;price:[500 TO *]&#8220;],<br />
                                                   :fields => [:category, :manufacturer]}</p>
<p>For my purposes (using Solr 1.1) I add the following parameters to the query url: &#8220;&#038;facet=true&#038;facet.field=plan_type&#038;facet.field=company_server_location&#038;facet.zeros=false&#8221;</p>
<p>For more information about using facets in Solr, take a look at the Solr wiki: <a href="http://wiki.apache.org/solr/SimpleFacetParameters">http://wiki.apache.org/solr/SimpleFacetParameters</a>. That gives you all the details about facets in Solr.</p>
]]></content:encoded>
			<wfw:commentRss>http://www.railshostinginfo.com/blog/2007/07/13/faceted-search-in-solr-with-ruby-on-rails/feed/</wfw:commentRss>
		</item>
		<item>
		<title>Haml and Rails rendering speed</title>
		<link>http://www.railshostinginfo.com/blog/2007/07/13/haml-and-rails-rendering-speed/</link>
		<comments>http://www.railshostinginfo.com/blog/2007/07/13/haml-and-rails-rendering-speed/#comments</comments>
		<pubDate>Fri, 13 Jul 2007 12:19:09 +0000</pubDate>
		<dc:creator>Nick</dc:creator>
		
		<guid isPermaLink="false">http://www.railshostinginfo.com/blog/2007/07/13/haml-and-rails-rendering-speed/</guid>
		<description><![CDATA[I was shocked when I read that the new 1.7 release of Haml now comes with speed. Haml 1.7 is now only 1.8 times slower than ERB. And I thought ERB was one of the slowest things in Rails. Check out http://www.kuwata-lab.com/erubis/ for different rendering speeds and notice that ERB is the slowest of them [...]<p><a href="http://sharethis.com/item?&#038;wp=2.6&#38;publisher=2c5be29d-b693-4c77-b788-d1615d906a0c&#38;title=Haml+and+Rails+rendering+speed&#38;url=http%3A%2F%2Fwww.railshostinginfo.com%2Fblog%2F2007%2F07%2F13%2Fhaml-and-rails-rendering-speed%2F">ShareThis</a></p>]]></description>
			<content:encoded><![CDATA[<p>I was shocked when I read that the new 1.7 release of <a href="http://haml.hamptoncatlin.com">Haml</a> now comes with speed. Haml 1.7 is now only 1.8 times slower than ERB. And I thought ERB was one of the slowest things in Rails. Check out <a href="http://www.kuwata-lab.com/erubis/">http://www.kuwata-lab.com/erubis/</a> for different rendering speeds and notice that ERB is the slowest of them all. So saying that Haml now comes with speed is a nice euphemism. If you need more rendering speed I advice you to use Erubis (<a href="http://www.kuwata-lab.com/erubis/">http://www.kuwata-lab.com/erubis/</a>). The only thing you need to do to install it is:</p>
<p>gem install erubis</p>
<p>and put - require &#8216;erubis/helpers/rails_helper&#8217; - in your environment.rb file.</p>
]]></content:encoded>
			<wfw:commentRss>http://www.railshostinginfo.com/blog/2007/07/13/haml-and-rails-rendering-speed/feed/</wfw:commentRss>
		</item>
		<item>
		<title>Rails 1.2 doesn&#8217;t support composite primary keys</title>
		<link>http://www.railshostinginfo.com/blog/2007/07/13/rails-12-doesnt-support-composite-primary-keys/</link>
		<comments>http://www.railshostinginfo.com/blog/2007/07/13/rails-12-doesnt-support-composite-primary-keys/#comments</comments>
		<pubDate>Fri, 13 Jul 2007 12:10:17 +0000</pubDate>
		<dc:creator>Nick</dc:creator>
		
		<guid isPermaLink="false">http://www.railshostinginfo.com/blog/2007/07/13/rails-12-doesnt-support-composite-primary-keys/</guid>
		<description><![CDATA[Rails 1.2 doesn&#8217;t support composite primary keys out of the box!! Well, that certainly proves there is too much hype around Rails. I love it and it is really easy to build web applications in it. But no composite primary keys support, ouch. Luckily there are many plugins/extensions, so check out http://compositekeys.rubyforge.org/, if you need [...]<p><a href="http://sharethis.com/item?&#038;wp=2.6&#38;publisher=2c5be29d-b693-4c77-b788-d1615d906a0c&#38;title=Rails+1.2+doesn%26%238217%3Bt+support+composite+primary+keys&#38;url=http%3A%2F%2Fwww.railshostinginfo.com%2Fblog%2F2007%2F07%2F13%2Frails-12-doesnt-support-composite-primary-keys%2F">ShareThis</a></p>]]></description>
			<content:encoded><![CDATA[<p>Rails 1.2 doesn&#8217;t support composite primary keys out of the box!! Well, that certainly proves there is too much hype around Rails. I love it and it is really easy to build web applications in it. But no composite primary keys support, ouch. Luckily there are many plugins/extensions, so check out <a href="http://compositekeys.rubyforge.org/">http://compositekeys.rubyforge.org/</a>, if you need them. And it works after some configuration.</p>
]]></content:encoded>
			<wfw:commentRss>http://www.railshostinginfo.com/blog/2007/07/13/rails-12-doesnt-support-composite-primary-keys/feed/</wfw:commentRss>
		</item>
		<item>
		<title>How to get Ruby OpenSSL to work on CentOS</title>
		<link>http://www.railshostinginfo.com/blog/2007/07/13/how-to-get-ruby-openssl-to-work-on-centos/</link>
		<comments>http://www.railshostinginfo.com/blog/2007/07/13/how-to-get-ruby-openssl-to-work-on-centos/#comments</comments>
		<pubDate>Fri, 13 Jul 2007 12:05:57 +0000</pubDate>
		<dc:creator>Nick</dc:creator>
		
		<guid isPermaLink="false">http://www.railshostinginfo.com/blog/2007/07/13/how-to-get-ruby-openssl-to-work-on-centos/</guid>
		<description><![CDATA[I recently needed the Ruby OpenSSL library to do some decoding and encoding. I had tested everything on Windows and there it worked without a glitch. But after moving my code to Linux CentOS it stopped working. I got the error: LoadError: no such file to load &#8212; openssl
After much searching I found the solution. [...]<p><a href="http://sharethis.com/item?&#038;wp=2.6&#38;publisher=2c5be29d-b693-4c77-b788-d1615d906a0c&#38;title=How+to+get+Ruby+OpenSSL+to+work+on+CentOS&#38;url=http%3A%2F%2Fwww.railshostinginfo.com%2Fblog%2F2007%2F07%2F13%2Fhow-to-get-ruby-openssl-to-work-on-centos%2F">ShareThis</a></p>]]></description>
			<content:encoded><![CDATA[<p>I recently needed the Ruby OpenSSL library to do some decoding and encoding. I had tested everything on Windows and there it worked without a glitch. But after moving my code to Linux CentOS it stopped working. I got the error: LoadError: no such file to load &#8212; openssl</p>
<p>After much searching I found the solution. This only works when you have installed Ruby from the source and is only tested with Ruby 1.8.4 (but probably also works with newer versions).</p>
<p>First you need to make sure openssl en openssl-devel are installed (yum list | grep openssl). If not, install them using yum install openssl and yum install openssl-devel. Both libraries are needed to compile the Ruby OpenSSL code. After that, locate the openssl folder in the Ruby source files (ruby-1.8.4/ext/openssl) and make sure you are in the folder, when you run the following commands:</p>
<p>ruby extconf.rb<br />
make<br />
make install</p>
<p>make install should write the compiled libraries to your Ruby folder. Open irb to check if it worked.</p>
<p>irb(main):001:0> require &#8216;openssl&#8217;<br />
=> true</p>
<p>If it returns true you are good to go.</p>
]]></content:encoded>
			<wfw:commentRss>http://www.railshostinginfo.com/blog/2007/07/13/how-to-get-ruby-openssl-to-work-on-centos/feed/</wfw:commentRss>
		</item>
		<item>
		<title>Setting up a Ruby on Rails server - Part 6 - Axigen easy mail server</title>
		<link>http://www.railshostinginfo.com/blog/2007/06/05/setting-up-a-ruby-on-rails-server-part-5-axigen-easy-mail-server/</link>
		<comments>http://www.railshostinginfo.com/blog/2007/06/05/setting-up-a-ruby-on-rails-server-part-5-axigen-easy-mail-server/#comments</comments>
		<pubDate>Tue, 05 Jun 2007 09:52:27 +0000</pubDate>
		<dc:creator>Nick</dc:creator>
		
		<guid isPermaLink="false">http://www.railshostinginfo.com/blog/2007/06/05/setting-up-a-ruby-on-rails-server-part-5-axigen-easy-mail-server/</guid>
		<description><![CDATA[I was looking for an easy way to install my own mail server. I had looked at Postfix, Exim, Sendmail. But installing those mail servers isn&#8217;t enough you have to make sure that you at least integrate it with SpamAssassin (spam filter) and ClamAV (virus scanner). And once everything is installed you have to maintain [...]<p><a href="http://sharethis.com/item?&#038;wp=2.6&#38;publisher=2c5be29d-b693-4c77-b788-d1615d906a0c&#38;title=Setting+up+a+Ruby+on+Rails+server+-+Part+6+-+Axigen+easy+mail+server&#38;url=http%3A%2F%2Fwww.railshostinginfo.com%2Fblog%2F2007%2F06%2F05%2Fsetting-up-a-ruby-on-rails-server-part-5-axigen-easy-mail-server%2F">ShareThis</a></p>]]></description>
			<content:encoded><![CDATA[<p>I was looking for an easy way to install my own mail server. I had looked at Postfix, Exim, Sendmail. But installing those mail servers isn&#8217;t enough you have to make sure that you at least integrate it with SpamAssassin (spam filter) and ClamAV (virus scanner). And once everything is installed you have to maintain it. And there aren&#8217;t so many great tools around to do it. After reading various tutorial, installing them, configuring them and making them work together seemed a daunting task. So I searched Google for an easy to install and easy to administrate mail server. I found Axigen (<a href="http://www.axigen.com">http://www.axigen.com</a>): an easy to install, easy to configure and even easier to maintain webserver. There is a free version available, but it signs every mail you send or receive, which gets a bit irritating. There support is excellent, even if you use their free version.</p>
<p>How to install Axigen:<br />
Download Axigen van www.axigen.com<br />
rpm -ivh axigen&#8230;<br />
yum install compat-libstdc++-33 (needed by Axigen)</p>
<p>#define extra repository for clamav-server, which isn&#8217;t in the normal CentOS repositories<br />
# cat /etc/yum.repos.d/kbsingh-CentOS-Extras.repo<br />
[kbs-CentOS-Extras]<br />
name=CentOS.Karan.Org-EL$releasever - Stable<br />
baseurl=http://centos.karan.org/el$releasever/extras/stable/$basearch/RPMS/<br />
gpgcheck=1<br />
gpgkey=http://centos.karan.org/RPM-GPG-KEY-karan.org.txt<br />
enabled=1</p>
<p>Before starting clamav, run freshclam to update the virus db.</p>
<p>Install Axigen by following their installation procedure.</p>
<p>After you have installed Axigen, you should check it isn&#8217;t configured as a relay server. Go to <a href="http://www.abuse.net/relay.html">http://www.abuse.net/relay.html</a> - and enter your IP address. If everything is correct you have configured your own secure mail server.</p>
]]></content:encoded>
			<wfw:commentRss>http://www.railshostinginfo.com/blog/2007/06/05/setting-up-a-ruby-on-rails-server-part-5-axigen-easy-mail-server/feed/</wfw:commentRss>
		</item>
		<item>
		<title>Setting up a Ruby on Rails server - Part 5 - Java - Tomcat - Ant</title>
		<link>http://www.railshostinginfo.com/blog/2007/04/04/setting-up-a-ruby-on-rails-server-part-4-java-tomcat-ant/</link>
		<comments>http://www.railshostinginfo.com/blog/2007/04/04/setting-up-a-ruby-on-rails-server-part-4-java-tomcat-ant/#comments</comments>
		<pubDate>Wed, 04 Apr 2007 09:33:08 +0000</pubDate>
		<dc:creator>Nick</dc:creator>
		
		<guid isPermaLink="false">http://www.railshostinginfo.com/blog/2007/04/04/setting-up-a-ruby-on-rails-server-part-4-java-tomcat-ant/</guid>
		<description><![CDATA[Some of you may think, why on earth or you using Java? Well, I use every language program that looks good to me. PHP to run this blog, Rails to develop my own sites and Java because it has an awesome search engine Lucene and on top some nice icing in the form of Solr.
In [...]<p><a href="http://sharethis.com/item?&#038;wp=2.6&#38;publisher=2c5be29d-b693-4c77-b788-d1615d906a0c&#38;title=Setting+up+a+Ruby+on+Rails+server+-+Part+5+-+Java+-+Tomcat+-+Ant&#38;url=http%3A%2F%2Fwww.railshostinginfo.com%2Fblog%2F2007%2F04%2F04%2Fsetting-up-a-ruby-on-rails-server-part-4-java-tomcat-ant%2F">ShareThis</a></p>]]></description>
			<content:encoded><![CDATA[<p>Some of you may think, why on earth or you using Java? Well, I use every language program that looks good to me. PHP to run this blog, Rails to develop my own sites and Java because it has an awesome search engine <a href="http://lucene.apache.org">Lucene</a> and on top some nice icing in the form of <a href="http://lucene.apache.org/solr/">Solr</a>.</p>
<p>In order to get Solr running you need to have Java, Tomcat and Ant installed first.</p>
<p>Java installation:<br />
<code><br />
Download the latest Java jdk_xx.bin file<br />
chmod +x jdk_xx.bin #to make it executable<br />
./jdk_xx.bin<br />
</code></p>
<p>Now you make sure that all the paths are correct. I added the following lines to /etc/profile to do it (also added path for Tomcat and Ant), maybe there is a cleaner method for it.<br />
<code><br />
export PATH=/usr/java/jdk_xx/bin:/usr/local/ant/bin:$PATH<br />
export JAVA_HOME=/usr/java/jdk.xx/<br />
export CATALINA_HOME=/usr/local/tomcat<br />
export ANT_HOME=/usr/local/ant<br />
</code></p>
<p>Now you should restart your server to see if JAVA_HOME is still set. Run java -v to see if you get your Java version back. If you do, it means Java is installed correctly. Now on to Tomcat.</p>
<p>Tomcat installation:<br />
<code><br />
- /usr/sbin/adduser tomcat #add a tomcat user<br />
  chown -R tomcat /usr/local/tomcat<br />
- wget http://apache.scarlet.be/tomcat/tomcat-5/v5.5.17/bin/apache-tomcat-5.x.x.tar.gz #download latest Tomcat version<br />
tar -zxvf apache-tomcat-5.x.x.tar.gz<br />
- mv apache-tomcat-5.x.x /usr/local/tomcat<br />
</code></p>
<p>Now we have to make sure Tomcat starts up when the server goes down unexpectedly, so lets make a Tomcat startup script.</p>
<p>Create the file /etc/rc.d/init.d/tomcat and place the following in it:<br />
<code><br />
#!/bin/bash<br />
#<br />
# Startup script for Tomcat</p>
<p>start_tomcat=/usr/local/tomcat/bin/startup.sh<br />
stop_tomcat=/usr/local/tomcat/bin/shutdown.sh</p>
<p>start() {<br />
        echo -n "Starting tomcat: "<br />
        su -l tomcat -c ${start_tomcat}<br />
        echo "done."<br />
}<br />
stop() {<br />
        echo -n "Shutting down tomcat: "<br />
        su -l tomcat -c ${stop_tomcat}<br />
        echo "done."<br />
}</p>
<p># See how we were called<br />
case "$1" in<br />
  start)<br />
        start<br />
        ;;<br />
  stop)<br />
        stop<br />
        ;;<br />
  restart)<br />
        stop<br />
        sleep 10<br />
        start<br />
        ;;<br />
  *)<br />
        echo "Usage: $0 {start|stop|restart}"<br />
esac</p>
<p>exit 0<br />
</code></p>
<p>Now make the file executable and place it in the right directories:</p>
<p><code><br />
chmod +x tomcat<br />
cd /etc/rc3.d<br />
ln -s /etc/init.d/tomcat S71tomcat<br />
ln -s /etc/init.d/tomcat K01tomcat<br />
</code></p>
<p>BTW K stands for stopping and S stands for starting and the number is the order in which all the files are executed. So if Tomcat needs to be started before another service at startup make sure it gets a lower S number than the other service.</p>
<p>That&#8217;s it for Tomcat. Restart your server and see if Tomcat starts up.</p>
<p>Now the last part is installing Ant, which is also the easiest.</p>
<p>Ant installation:<br />
<code><br />
wget http://apache.scarlet.be/ant/binaries/apache-ant-1.6.x-bin.tar.gz<br />
tar -zxvf apache-ant-1.6.x-bin.tar.gz<br />
mv  apache-ant-1.6.x-bin /usr/local/ant<br />
</code></p>
<p>And now you are ready to install Solr or any other Java utility. Next time I&#8217;ll give some explanation about my mailserver.</p>
]]></content:encoded>
			<wfw:commentRss>http://www.railshostinginfo.com/blog/2007/04/04/setting-up-a-ruby-on-rails-server-part-4-java-tomcat-ant/feed/</wfw:commentRss>
		</item>
		<item>
		<title>Setting up a Ruby on Rails server - Part 4 - Litespeed a web server</title>
		<link>http://www.railshostinginfo.com/blog/2007/04/02/setting-up-a-ruby-on-rails-server-part-3-litespeed-a-webserver/</link>
		<comments>http://www.railshostinginfo.com/blog/2007/04/02/setting-up-a-ruby-on-rails-server-part-3-litespeed-a-webserver/#comments</comments>
		<pubDate>Mon, 02 Apr 2007 06:38:16 +0000</pubDate>
		<dc:creator>Nick</dc:creator>
		
		<guid isPermaLink="false">http://www.railshostinginfo.com/blog/2007/04/02/setting-up-a-ruby-on-rails-server-part-3-litespeed-a-webserver/</guid>
		<description><![CDATA[First of all why did I choose Litespeed and not Apache or Lighttpd. Well, I first choose Apache + Mongrel to be my web server, but setting it up wasn&#8217;t that easy and once I got it running and did some testing on it. It turned out to be a very memory intensive combination. And [...]<p><a href="http://sharethis.com/item?&#038;wp=2.6&#38;publisher=2c5be29d-b693-4c77-b788-d1615d906a0c&#38;title=Setting+up+a+Ruby+on+Rails+server+-+Part+4+-+Litespeed+a+web+server&#38;url=http%3A%2F%2Fwww.railshostinginfo.com%2Fblog%2F2007%2F04%2F02%2Fsetting-up-a-ruby-on-rails-server-part-3-litespeed-a-webserver%2F">ShareThis</a></p>]]></description>
			<content:encoded><![CDATA[<p>First of all why did I choose <a href="http://www.litespeedtech.com">Litespeed</a> and not Apache or Lighttpd. Well, I first choose Apache + Mongrel to be my web server, but setting it up wasn&#8217;t that easy and once I got it running and did some testing on it. It turned out to be a very memory intensive combination. And that was at the time a only had one site and I was planning on expanding. So if only one site is using this many memory, howh much memory will two, three or more sites consume. I wanted to have three Mongrel instances per site, each consuming between 40 and 50 Mb. So I would quickly run out of memory and as they say memory is cheap, I started to look at other possibilities. I had heard of Litespeed a couple of months ago, but that was at the time their site was running on a Nuke version. And well Nuke isn&#8217;t known for its security, so I was turned away from it. But just at that time the new version 2.2 of Litespeed came out and there was a blog posting from Bob Silva on <a href="http://i.nfectio.us/articles/2006/09/04/litespeed-web-server-2-2-includes-rails-support">http://i.nfectio.us/articles/2006/09/04/litespeed-web-server-2-2-includes-rails-support</a> with two videos demonstrating just how easy it is to setup Litespeed and configure a new Rails site. After seeing both videos I just had to test it. And as it turned out I liked it a lot more than Apache + Mongrel. Main advantages of Litespeed are: easy to administer (setting up a new Rails site is a breeze), very fast, scales very well (doesn&#8217;t use up so much memory as Apache + Mongrel did) and very easy to update.</p>
<p>Installation (note I&#8217;m using the latest 2.2.x version of Litespeed, you can already download the 3.0.x version, which has a better administration interface)</p>
<p>gem install ruby-lsapi<br />
wget http://litespeedtech.com/packages/2.2/std/lsws-2.2.x-std-i386-linux.tar.gz<br />
unzip Litespeed and ./install.sh<br />
follow the steps from the installer</p>
<p>For security reasons I restricted the access to the admin console: </p>
<p>WebAdmin Configuration > Security > Access Control<br />
Allow: 127.0.0.1<br />
Deny: ALL</p>
<p>With SSH you can tunnel to it and still have access to the admin console. For more information on getting a Rails site up and running look at the <a href="http://i.nfectio.us/articles/2006/09/04/litespeed-web-server-2-2-includes-rails-support">videos Bob Silva</a> made, he did a wonderful job.</p>
<p>Some things you need to be aware of. Litespeed runs as the user nobody, so if you have caching turned on in your Rails project you have to make sure Litespeed is able to write to the tmp directory:<br />
<code><br />
chown -R nobody:nobody rails-project-path/tmp (action caching)<br />
chown -R nobody:nobody public/model-name (page caching)<br />
</code></p>
<p>You also need to change the rights of your production.log, otherwise Litespeed is unable to write to it:<br />
<code><br />
chmod 666 /log/production.log<br />
</code></p>
<p>Oh, and another useful tip is, that when you encounter an error and something doesn&#8217;t work. Make sure you check lsws/logs/stderr.log, where the more obscure errors are reported. </p>
<p>So now you have setup your web server and you are able to start serving your pages to the world.</p>
]]></content:encoded>
			<wfw:commentRss>http://www.railshostinginfo.com/blog/2007/04/02/setting-up-a-ruby-on-rails-server-part-3-litespeed-a-webserver/feed/</wfw:commentRss>
		</item>
		<item>
		<title>Setting up a Ruby on Rails server - Part 3 - Installing MySQL</title>
		<link>http://www.railshostinginfo.com/blog/2007/03/30/setting-up-a-ruby-on-rails-server-part-2-installing-mysql/</link>
		<comments>http://www.railshostinginfo.com/blog/2007/03/30/setting-up-a-ruby-on-rails-server-part-2-installing-mysql/#comments</comments>
		<pubDate>Fri, 30 Mar 2007 16:41:34 +0000</pubDate>
		<dc:creator>Nick</dc:creator>
		
		<guid isPermaLink="false">http://www.railshostinginfo.com/blog/2007/03/30/setting-up-a-ruby-on-rails-server-part-2-installing-mysql/</guid>
		<description><![CDATA[Today, I&#8217;ll explain how you can install MySQL on a CentOS box. You can use the MySQL version that is already installed on CentOS, but it is old. On my system it was 4.1.20, but I wanted to use the 5 series. So first step is to remove the old one:

yum remove mysql

Add some a [...]<p><a href="http://sharethis.com/item?&#038;wp=2.6&#38;publisher=2c5be29d-b693-4c77-b788-d1615d906a0c&#38;title=Setting+up+a+Ruby+on+Rails+server+-+Part+3+-+Installing+MySQL&#38;url=http%3A%2F%2Fwww.railshostinginfo.com%2Fblog%2F2007%2F03%2F30%2Fsetting-up-a-ruby-on-rails-server-part-2-installing-mysql%2F">ShareThis</a></p>]]></description>
			<content:encoded><![CDATA[<p>Today, I&#8217;ll explain how you can install MySQL on a CentOS box. You can use the MySQL version that is already installed on CentOS, but it is old. On my system it was 4.1.20, but I wanted to use the 5 series. So first step is to remove the old one:<br />
<code><br />
yum remove mysql<br />
</code></p>
<p>Add some a mysql user and group to run MySQL and make sure the mysql can&#8217;t log in:<br />
<code><br />
groupadd mysql (probably already exists)<br />
useradd -s /sbin/nologin -g mysql mysql<br />
</code></p>
<p>Get the MySQL source from the <a href="http://www.mysql.com">MySQL website</a> and downloaded the latest version. That is probably the biggest issues with installing packages from source, you tend not to upgrade them once they are up and running and your site is in production. If it works, don&#8217;t fix it!</p>
<p>Install MySQL and change some file settings:<br />
<code><br />
tar -zxvf mysql-standard-5.0.xx-linux-i686.tar.gz<br />
mv mysql-standard-5.0.xx-linux-i686 /usr/local/mysql<br />
cd /usr/local/mysql<br />
scripts/mysql_install_db --user=mysql<br />
chown -R root .<br />
chown -R mysql data<br />
chgrp -R mysql .<br />
</code></p>
<p>Check your MySQL installation:<br />
1. /usr/local/mysql/bin/mysqladmin version<br />
2. /usr/local/mysql/bin/mysql - start the mysql command utility</p>
<p>How to secure MySQL:<br />
<code><br />
cp mysql-dir/support-files/my-large.cnf /usr/local/mysql/data/my.cnf<br />
vi data/my.cnf<br />
</code></p>
<p>You have two possibilities:<br />
1. bind-address = 127.0.0.1 #MySQL wont be accessible from the outside<br />
2. uncomment skip-networking #only connections from localhost are allowed</p>
<p>Both options make sure that nobody from outside your machine is able to connect to your MySQL. You are still able to connect to it using SSH tunneling, I&#8217;ll probably explain this very handy option in one of my next posts.</p>
<p>Other security measures are:</p>
<ul>
<li>remove all the MySQL users, except for root</li>
<li>give the root user a password: <code>/usr/bin/mysqladmin -u root password 'new-password'</code></li>
<li>add a user for each database and only give them minimal rights and use this user in your Rails database.yml file</li>
</ul>
<p>You will probably have to restart your server at some point, so it would be handy if MySQL restarted automatically. Here is how you do it:<br />
<code><br />
cp /usr/local/mysql/support-files/mysql.server /etc/init.d/mysql<br />
chmod +x /etc/init.d/mysql<br />
chkconfig --level 345 mysql on<br />
</code></p>
<p>Now the only thing left to do is to make Ruby talk to MySQL by installingen the Ruby MySQL bindings:</p>
<p>gem install mysql &#8212; &#8211;with-mysql-include=/usr/local/mysql/include/<br />
                       &#8211;with-mysql-lib=/usr/local/mysql/lib/<br />
                       &#8211;with-mysql-config=/usr/local/mysql/bin/mysql_config</p>
<p>I had to modify modify /usr/local/mysql/bin/mysql_config and add &#8220;-lmygcc&#8221; to the end of the libraries to link. I added it to the end of this line in the script:<br />
<code><br />
libs=" $ldflags -L$pkglibdir -lmysqlclient -lz -lcrypt -lnsl -lm -lmygcc "<br />
</code></p>
<p>Otherwise I got the error &#8216;<strong>unresolved symbol __pure_virtual exists</strong>&#8216;. Of course if you don&#8217;t get this error you don&#8217;t have to change the file.</p>
<p>You can test the Ruby MySQL binding with:<br />
<code><br />
irb<br />
require 'rubygems'<br />
require 'mysql'<br />
</code></p>
<p>This should return true. That&#8217;s it, know you should be able to connect your Rails program with MySQL.</p>
]]></content:encoded>
			<wfw:commentRss>http://www.railshostinginfo.com/blog/2007/03/30/setting-up-a-ruby-on-rails-server-part-2-installing-mysql/feed/</wfw:commentRss>
		</item>
		<item>
		<title>Just a quick Technorati intermezzo</title>
		<link>http://www.railshostinginfo.com/blog/2007/03/30/just-a-quick-technoratie-intermezzo/</link>
		<comments>http://www.railshostinginfo.com/blog/2007/03/30/just-a-quick-technoratie-intermezzo/#comments</comments>
		<pubDate>Fri, 30 Mar 2007 16:34:52 +0000</pubDate>
		<dc:creator>Nick</dc:creator>
		
		<guid isPermaLink="false">http://www.railshostinginfo.com/blog/2007/03/30/just-a-quick-technoratie-intermezzo/</guid>
		<description><![CDATA[Technorati Profile
<p><a href="http://sharethis.com/item?&#038;wp=2.6&#38;publisher=2c5be29d-b693-4c77-b788-d1615d906a0c&#38;title=Just+a+quick+Technorati+intermezzo&#38;url=http%3A%2F%2Fwww.railshostinginfo.com%2Fblog%2F2007%2F03%2F30%2Fjust-a-quick-technoratie-intermezzo%2F">ShareThis</a></p>]]></description>
			<content:encoded><![CDATA[<p><a href="http://technorati.com/claim/32am2ypiqt" rel="me">Technorati Profile</a></p>
]]></content:encoded>
			<wfw:commentRss>http://www.railshostinginfo.com/blog/2007/03/30/just-a-quick-technoratie-intermezzo/feed/</wfw:commentRss>
		</item>
	</channel>
</rss>
