{"id":370,"date":"2011-02-01T11:17:31","date_gmt":"2011-02-01T16:17:31","guid":{"rendered":"http:\/\/www.1oc.com\/blog\/?p=370"},"modified":"2011-07-14T22:22:11","modified_gmt":"2011-07-15T02:22:11","slug":"deploying-genexus-applications-on-centos-with-ruby-1-9-and-mysql-part-1","status":"publish","type":"post","link":"http:\/\/blog.1oc.com\/?p=370","title":{"rendered":"Deploying GeneXus applications on CentOS with Ruby 1.9 and mysql (part 1)"},"content":{"rendered":"<p>Firs of all you need a CentOS operating system with mysql, ruby 1.9 and passenger installed<\/p>\n<p>If you don&#8217;t have this or you don&#8217;t know how to do it, just follow the simple instructions on these 2 posts:<\/p>\n<h3><a href=\"http:\/\/blog.1oc.com\/?p=336\" rel=\"bookmark\">Installing Ruby 1.9 on CentOS<\/a><\/h3>\n<h3><a href=\"http:\/\/blog.1oc.com\/?p=346\" rel=\"bookmark\">Installing Phusion\u2019s Passenger on CentOS (for Ruby 1.9)<\/a><\/h3>\n<p>Once you are done with this you are ready to move forward.<\/p>\n<p>First you need to copy the following directories from your GeneXus installation to the CentOS server.<\/p>\n<p><a href=\"http:\/\/blog.1oc.com\/wp-content\/uploads\/2011\/02\/Screen-shot-2011-02-01-at-10.53.02-AM.png\"><img loading=\"lazy\" decoding=\"async\" class=\"alignnone size-medium wp-image-372\" title=\"Screen shot 2011-02-01 at 10.53.02 AM\" src=\"http:\/\/blog.1oc.com\/wp-content\/uploads\/2011\/02\/Screen-shot-2011-02-01-at-10.53.02-AM-300x175.png\" alt=\"\" width=\"300\" height=\"175\" srcset=\"http:\/\/blog.1oc.com\/wp-content\/uploads\/2011\/02\/Screen-shot-2011-02-01-at-10.53.02-AM-300x175.png 300w, http:\/\/blog.1oc.com\/wp-content\/uploads\/2011\/02\/Screen-shot-2011-02-01-at-10.53.02-AM-500x293.png 500w, http:\/\/blog.1oc.com\/wp-content\/uploads\/2011\/02\/Screen-shot-2011-02-01-at-10.53.02-AM.png 819w\" sizes=\"auto, (max-width: 300px) 100vw, 300px\" \/><\/a><\/p>\n<p>From under &#8220;gxruby&#8221; copy the &#8220;linux&#8221; and &#8220;generic&#8221; directory both under the same subdirectory.<\/p>\n<p>In my case I&#8217;ve created a new directory on the server called &#8220;gxruby&#8221; (original \ud83d\ude42 ), and put them there.<\/p>\n<p><a href=\"http:\/\/blog.1oc.com\/wp-content\/uploads\/2011\/02\/Screen-shot-2011-01-28-at-12.19.44-PM.png\"><img loading=\"lazy\" decoding=\"async\" class=\"alignnone size-medium wp-image-373\" title=\"Screen shot 2011-01-28 at 12.19.44 PM\" src=\"http:\/\/blog.1oc.com\/wp-content\/uploads\/2011\/02\/Screen-shot-2011-01-28-at-12.19.44-PM-300x142.png\" alt=\"\" width=\"300\" height=\"142\" srcset=\"http:\/\/blog.1oc.com\/wp-content\/uploads\/2011\/02\/Screen-shot-2011-01-28-at-12.19.44-PM-300x142.png 300w, http:\/\/blog.1oc.com\/wp-content\/uploads\/2011\/02\/Screen-shot-2011-01-28-at-12.19.44-PM-500x237.png 500w, http:\/\/blog.1oc.com\/wp-content\/uploads\/2011\/02\/Screen-shot-2011-01-28-at-12.19.44-PM.png 928w\" sizes=\"auto, (max-width: 300px) 100vw, 300px\" \/><\/a><\/p>\n<p>Now before you run the installation script, in order to work properly under CentOS you have to do the following:<\/p>\n<ol>\n<li>The installation script is based on Debian, so it expects to have certain libraries installed in places where CentOS doesn&#8217;t normally used them<br \/>\nspecially the &#8220;libmysqlclient&#8221;. On CentOS these library is called &#8220;libmysqlclient.so.15.0.0&#8221; and it&#8217;s under &#8220;\/usr\/lib\/mysql\/&#8221;, but in the installation<br \/>\nscript it should be under &#8220;\/usr\/local\/lib\/&#8221; so we&#8217;ll have to link it to the new location, we do this with the following command:<br \/>\n$ ln -s \/usr\/lib\/mysql\/libmysqlclient.so.15.0.0 \/usr\/local\/lib\/libmysqlclient.so<\/li>\n<li>Under the subdirectory &#8220;gxruby\/generic\/gx_lucene&#8221; (this is where you copy from the GeneXus machine), you have to edit the script &#8220;build_make.sh&#8221;.<br \/>\nIn reality, because this file is corrupted on GeneXus Evo1 U3, it&#8217;s better if you delete it an create a new one with the same name with the following contente:<\/p>\n<div id=\"_mcePaste\"><strong>#!\/bin\/sh<\/strong><\/div>\n<div id=\"_mcePaste\"><strong>tar -xzf clucene-core-0.9.21b.tar.gz<\/strong><\/div>\n<div id=\"_mcePaste\"><strong>cd clucene-core-0.9.21b<\/strong><\/div>\n<div id=\"_mcePaste\"><strong>sh autogen.sh<\/strong><\/div>\n<div id=\"_mcePaste\"><strong>sh configure<\/strong><\/div>\n<div id=\"_mcePaste\"><strong>make<\/strong><\/div>\n<div id=\"_mcePaste\"><strong>make install<\/strong><\/div>\n<div id=\"_mcePaste\"><strong>cd ..<\/strong><\/div>\n<div id=\"_mcePaste\"><strong>ruby extconf.rb &#8211;with-clucene-include=&#8217;clucene-core-0.9.21b\/src&#8217; &#8211;with-clucene<\/strong><strong>-lib=&#8217;clucene-core-0.9.21b\/src\/.libs&#8217; &#8211;with-ldflags=&#8217;-lclucene&#8217;<\/strong><\/div>\n<div id=\"_mcePaste\"><strong>make<\/strong><\/div>\n<div id=\"_mcePaste\"><strong>mkdir lib<\/strong><\/div>\n<div id=\"_mcePaste\"><strong>mv CLucene_gx.so lib<\/strong><\/div>\n<div id=\"_mcePaste\"><strong>gem build build_gem.rb<\/strong><\/div>\n<div id=\"_mcePaste\"><strong>gem install \u00a0CLucene_gx-0.1.1-x86-linux<\/strong><\/div>\n<div id=\"_mcePaste\"><strong><br \/>\n<\/strong><\/div>\n<\/li>\n<\/ol>\n<p>NOTE:<\/p>\n<p>In addition, if you are using a 64 bit platform replace the last line of the script for\u00a0gem install \u00a0<em><strong>CLucene_gx-0.1.1-x86_64-linux<\/strong><\/em><\/p>\n<p>Now you are ready to run the installation script that will install all GeneXus gems on your system.<\/p>\n<p>Go to &#8220;.\/gxruby\/linux&#8221;, and run the &#8220;installgems.bash&#8221; script.<\/p>\n<p>In order to do that just change the mode of the file to &#8220;executable&#8221; with <em>$\u00a0chmod +x installgems.bash<\/em><\/p>\n<p>and then runt <strong><em>$ .\/installgems.bash<\/em><\/strong><\/p>\n<p><strong><em><span style=\"font-style: normal; font-weight: normal;\">Now, you are ready to deploy your GeneXus Ruby applications.<\/span><\/em><\/strong><\/p>\n<p>If you don&#8217;t know how to do it, follow the next post where I&#8217;m going to walk you through the deployment process<\/p>\n<p>\ud83d\ude09<\/p>\n","protected":false},"excerpt":{"rendered":"<p>Firs of all you need a CentOS operating system with mysql, ruby 1.9 and passenger installed If you don&#8217;t have this or you don&#8217;t know how to do it, just follow the simple instructions on these 2 posts: Installing Ruby &hellip; <a href=\"http:\/\/blog.1oc.com\/?p=370\">Continue reading <span class=\"meta-nav\">&rarr;<\/span><\/a><\/p>\n","protected":false},"author":1,"featured_media":0,"comment_status":"open","ping_status":"open","sticky":false,"template":"","format":"standard","meta":{"footnotes":""},"categories":[6,8,9],"tags":[],"class_list":["post-370","post","type-post","status-publish","format-standard","hentry","category-genexus","category-servers","category-unix"],"_links":{"self":[{"href":"http:\/\/blog.1oc.com\/index.php?rest_route=\/wp\/v2\/posts\/370","targetHints":{"allow":["GET"]}}],"collection":[{"href":"http:\/\/blog.1oc.com\/index.php?rest_route=\/wp\/v2\/posts"}],"about":[{"href":"http:\/\/blog.1oc.com\/index.php?rest_route=\/wp\/v2\/types\/post"}],"author":[{"embeddable":true,"href":"http:\/\/blog.1oc.com\/index.php?rest_route=\/wp\/v2\/users\/1"}],"replies":[{"embeddable":true,"href":"http:\/\/blog.1oc.com\/index.php?rest_route=%2Fwp%2Fv2%2Fcomments&post=370"}],"version-history":[{"count":1,"href":"http:\/\/blog.1oc.com\/index.php?rest_route=\/wp\/v2\/posts\/370\/revisions"}],"predecessor-version":[{"id":403,"href":"http:\/\/blog.1oc.com\/index.php?rest_route=\/wp\/v2\/posts\/370\/revisions\/403"}],"wp:attachment":[{"href":"http:\/\/blog.1oc.com\/index.php?rest_route=%2Fwp%2Fv2%2Fmedia&parent=370"}],"wp:term":[{"taxonomy":"category","embeddable":true,"href":"http:\/\/blog.1oc.com\/index.php?rest_route=%2Fwp%2Fv2%2Fcategories&post=370"},{"taxonomy":"post_tag","embeddable":true,"href":"http:\/\/blog.1oc.com\/index.php?rest_route=%2Fwp%2Fv2%2Ftags&post=370"}],"curies":[{"name":"wp","href":"https:\/\/api.w.org\/{rel}","templated":true}]}}