{"id":340,"date":"2014-06-26T02:48:13","date_gmt":"2014-06-26T02:48:13","guid":{"rendered":"https:\/\/digitalchild.info\/?p=340"},"modified":"2014-06-26T02:48:13","modified_gmt":"2014-06-26T02:48:13","slug":"centos-6-5-and-ruby1-9-3-via-software-collections","status":"publish","type":"post","link":"https:\/\/randomadult.local\/centos-6-5-and-ruby1-9-3-via-software-collections\/","title":{"rendered":"Centos 6.5 and Ruby 1.9.3 via Software Collections"},"content":{"rendered":"

I wanted to cut the amount of repositories that my systems were running and I recently came across Red Hats Software Collections<\/a>\u00a0(SCL). Software collections is a relatively new system that allows you to run some newer versions of popular packages including ruby, php, postgreSQL and more. I needed a newer version of Ruby (1.9.3) for my systems because I use a backup system that’s\u00a0written in ruby from Michael van Rooijen<\/a>.\u00a0I know that Ruby 1.9.3 might not be new enough for some but it works for me. The following is a quick guide on how to get Centos 6.5 and Ruby 1.9.3 via software collections.<\/p>\n

The standard CentOS repositories ships with software collections and its very easy to get them running. You can do so by running the following command.<\/p>\n

\nyum install -y centos-release-SCL\n<\/pre>\n

This will then give you access to the standard SCL’s that ship with CentOS\/RHEL. You can build your own software collections<\/a> if you like but I won’t go into that with this post.\u00a0Now\u00a0you will have the newer versions available to install such as ruby193. Run the following to install ruby193.<\/p>\n

\nyum install -y ruby193\n<\/pre>\n

I run minimal installs so I never have any other versions of software installed unless I need them so if I was to run ruby -v<\/strong> on the command line I would get the following:<\/p>\n

\n[root@machine1 ~]# ruby -v\n-bash: ruby: command not found\n<\/pre>\n

Now you might think that ruby hasn’t installed, it has it’s just not part of your path or current session. To enable ruby run\u00a0the following command.<\/p>\n

\n[root@machine1\u00a0~]# source \/opt\/rh\/ruby193\/enable\n[root@machine1 ~]# ruby -v\nruby 1.9.3p448 (2013-06-27) [x86_64-linux]\n<\/pre>\n

As you can see we’ve now got access to ruby 1.9.3 from the software collections. There is a whole bunch of ruby193 packages available you can find them using search with yum. As I don’t use the standard ruby packages at all I want to make the SCL version my default version. The above commands are great for the current session but you would have to run source<\/strong>\u00a0 every login. \u00a0A nice way to make sure that this is working across logout and reboots is to put the source command in the profile.<\/p>\n

\necho "source \/opt\/rh\/ruby193\/enable" | sudo tee -a \/etc\/profile.d\/ruby193.sh\n<\/pre>\n

This will make it available as default for all users.<\/p>\n","protected":false},"excerpt":{"rendered":"

I wanted to cut the amount of repositories that my systems were running and I recently came across Red Hats Software Collections\u00a0(SCL). Software collections is a relatively new system that allows you to run some newer versions of popular packages including ruby, php, postgreSQL and more. I needed a newer …<\/p>\n

Centos 6.5 and Ruby 1.9.3 via Software Collections<\/span> Read More \u00bb<\/a><\/p>\n","protected":false},"author":1,"featured_media":0,"comment_status":"open","ping_status":"open","sticky":false,"template":"","format":"standard","meta":{"site-sidebar-layout":"default","site-content-layout":"default","ast-global-header-display":"","ast-banner-title-visibility":"","ast-main-header-display":"","ast-hfb-above-header-display":"","ast-hfb-below-header-display":"","ast-hfb-mobile-header-display":"","site-post-title":"","ast-breadcrumbs-content":"","ast-featured-img":"","footer-sml-layout":"","theme-transparent-header-meta":"","adv-header-id-meta":"","stick-header-meta":"","header-above-stick-meta":"","header-main-stick-meta":"","header-below-stick-meta":""},"categories":[5,9],"tags":[22,34,113,167,184],"yoast_head":"\nCentos 6.5 and Ruby 1.9.3 via Software Collections<\/title>\n<meta name=\"description\" content=\"A quick guide on getting CentOS 6.5 and Ruby 1.9.3 installed via Software Collections. Includes a quick tip on having it work across reboots.\" \/>\n<meta name=\"robots\" content=\"index, follow, max-snippet:-1, max-image-preview:large, max-video-preview:-1\" \/>\n<link rel=\"canonical\" href=\"https:\/\/randomadult.local\/centos-6-5-and-ruby1-9-3-via-software-collections\/\" \/>\n<meta property=\"og:locale\" content=\"en_US\" \/>\n<meta property=\"og:type\" content=\"article\" \/>\n<meta property=\"og:title\" content=\"Centos 6.5 and Ruby 1.9.3 via Software Collections\" \/>\n<meta property=\"og:description\" content=\"A quick guide on getting CentOS 6.5 and Ruby 1.9.3 installed via Software Collections. Includes a quick tip on having it work across reboots.\" \/>\n<meta property=\"og:url\" content=\"https:\/\/randomadult.local\/centos-6-5-and-ruby1-9-3-via-software-collections\/\" \/>\n<meta property=\"og:site_name\" content=\"Random Adult\" \/>\n<meta property=\"article:published_time\" content=\"2014-06-26T02:48:13+00:00\" \/>\n<meta name=\"author\" content=\"digitalchild\" \/>\n<meta name=\"twitter:card\" content=\"summary_large_image\" \/>\n<meta name=\"twitter:creator\" content=\"@dcwhatwhat\" \/>\n<meta name=\"twitter:site\" content=\"@dcwhatwhat\" \/>\n<meta name=\"twitter:label1\" content=\"Written by\" \/>\n\t<meta name=\"twitter:data1\" content=\"digitalchild\" \/>\n\t<meta name=\"twitter:label2\" content=\"Est. reading time\" \/>\n\t<meta name=\"twitter:data2\" content=\"2 minutes\" \/>\n<script type=\"application\/ld+json\" class=\"yoast-schema-graph\">{\"@context\":\"https:\/\/schema.org\",\"@graph\":[{\"@type\":\"Article\",\"@id\":\"https:\/\/randomadult.local\/centos-6-5-and-ruby1-9-3-via-software-collections\/#article\",\"isPartOf\":{\"@id\":\"https:\/\/randomadult.local\/centos-6-5-and-ruby1-9-3-via-software-collections\/\"},\"author\":{\"name\":\"digitalchild\",\"@id\":\"https:\/\/randomadult.local\/#\/schema\/person\/b0b954202434291ace51b4e7a0a81c04\"},\"headline\":\"Centos 6.5 and Ruby 1.9.3 via Software Collections\",\"datePublished\":\"2014-06-26T02:48:13+00:00\",\"dateModified\":\"2014-06-26T02:48:13+00:00\",\"mainEntityOfPage\":{\"@id\":\"https:\/\/randomadult.local\/centos-6-5-and-ruby1-9-3-via-software-collections\/\"},\"wordCount\":418,\"commentCount\":2,\"publisher\":{\"@id\":\"https:\/\/randomadult.local\/#organization\"},\"keywords\":[\"backup\",\"centos\",\"linux\",\"ruby\",\"software collections\"],\"articleSection\":[\"Geek\",\"Tip\"],\"inLanguage\":\"en-US\",\"potentialAction\":[{\"@type\":\"CommentAction\",\"name\":\"Comment\",\"target\":[\"https:\/\/randomadult.local\/centos-6-5-and-ruby1-9-3-via-software-collections\/#respond\"]}]},{\"@type\":\"WebPage\",\"@id\":\"https:\/\/randomadult.local\/centos-6-5-and-ruby1-9-3-via-software-collections\/\",\"url\":\"https:\/\/randomadult.local\/centos-6-5-and-ruby1-9-3-via-software-collections\/\",\"name\":\"Centos 6.5 and Ruby 1.9.3 via Software Collections\",\"isPartOf\":{\"@id\":\"https:\/\/randomadult.local\/#website\"},\"datePublished\":\"2014-06-26T02:48:13+00:00\",\"dateModified\":\"2014-06-26T02:48:13+00:00\",\"description\":\"A quick guide on getting CentOS 6.5 and Ruby 1.9.3 installed via Software Collections. Includes a quick tip on having it work across reboots.\",\"breadcrumb\":{\"@id\":\"https:\/\/randomadult.local\/centos-6-5-and-ruby1-9-3-via-software-collections\/#breadcrumb\"},\"inLanguage\":\"en-US\",\"potentialAction\":[{\"@type\":\"ReadAction\",\"target\":[\"https:\/\/randomadult.local\/centos-6-5-and-ruby1-9-3-via-software-collections\/\"]}]},{\"@type\":\"BreadcrumbList\",\"@id\":\"https:\/\/randomadult.local\/centos-6-5-and-ruby1-9-3-via-software-collections\/#breadcrumb\",\"itemListElement\":[{\"@type\":\"ListItem\",\"position\":1,\"name\":\"Home\",\"item\":\"https:\/\/randomadult.local\/\"},{\"@type\":\"ListItem\",\"position\":2,\"name\":\"Centos 6.5 and Ruby 1.9.3 via Software Collections\"}]},{\"@type\":\"WebSite\",\"@id\":\"https:\/\/randomadult.local\/#website\",\"url\":\"https:\/\/randomadult.local\/\",\"name\":\"Random Adult\",\"description\":\"Ramblings of a random adult\",\"publisher\":{\"@id\":\"https:\/\/randomadult.local\/#organization\"},\"potentialAction\":[{\"@type\":\"SearchAction\",\"target\":{\"@type\":\"EntryPoint\",\"urlTemplate\":\"https:\/\/randomadult.local\/?s={search_term_string}\"},\"query-input\":\"required name=search_term_string\"}],\"inLanguage\":\"en-US\"},{\"@type\":\"Organization\",\"@id\":\"https:\/\/randomadult.local\/#organization\",\"name\":\"Random Adult\",\"url\":\"https:\/\/randomadult.local\/\",\"logo\":{\"@type\":\"ImageObject\",\"inLanguage\":\"en-US\",\"@id\":\"https:\/\/randomadult.local\/#\/schema\/logo\/image\/\",\"url\":\"https:\/\/randomadult.local\/wp-content\/uploads\/2020\/01\/logo.png\",\"contentUrl\":\"https:\/\/randomadult.local\/wp-content\/uploads\/2020\/01\/logo.png\",\"width\":320,\"height\":134,\"caption\":\"Random Adult\"},\"image\":{\"@id\":\"https:\/\/randomadult.local\/#\/schema\/logo\/image\/\"},\"sameAs\":[\"https:\/\/twitter.com\/dcwhatwhat\"]},{\"@type\":\"Person\",\"@id\":\"https:\/\/randomadult.local\/#\/schema\/person\/b0b954202434291ace51b4e7a0a81c04\",\"name\":\"digitalchild\",\"image\":{\"@type\":\"ImageObject\",\"inLanguage\":\"en-US\",\"@id\":\"https:\/\/randomadult.local\/#\/schema\/person\/image\/\",\"url\":\"https:\/\/secure.gravatar.com\/avatar\/e0331079f6730910bc7760cb8f781237?s=96&d=mm&r=g\",\"contentUrl\":\"https:\/\/secure.gravatar.com\/avatar\/e0331079f6730910bc7760cb8f781237?s=96&d=mm&r=g\",\"caption\":\"digitalchild\"},\"url\":\"https:\/\/randomadult.local\/author\/digitalchild\/\"}]}<\/script>\n<!-- \/ Yoast SEO Premium plugin. -->","yoast_head_json":{"title":"Centos 6.5 and Ruby 1.9.3 via Software Collections","description":"A quick guide on getting CentOS 6.5 and Ruby 1.9.3 installed via Software Collections. Includes a quick tip on having it work across reboots.","robots":{"index":"index","follow":"follow","max-snippet":"max-snippet:-1","max-image-preview":"max-image-preview:large","max-video-preview":"max-video-preview:-1"},"canonical":"https:\/\/randomadult.local\/centos-6-5-and-ruby1-9-3-via-software-collections\/","og_locale":"en_US","og_type":"article","og_title":"Centos 6.5 and Ruby 1.9.3 via Software Collections","og_description":"A quick guide on getting CentOS 6.5 and Ruby 1.9.3 installed via Software Collections. Includes a quick tip on having it work across reboots.","og_url":"https:\/\/randomadult.local\/centos-6-5-and-ruby1-9-3-via-software-collections\/","og_site_name":"Random Adult","article_published_time":"2014-06-26T02:48:13+00:00","author":"digitalchild","twitter_card":"summary_large_image","twitter_creator":"@dcwhatwhat","twitter_site":"@dcwhatwhat","twitter_misc":{"Written by":"digitalchild","Est. reading time":"2 minutes"},"schema":{"@context":"https:\/\/schema.org","@graph":[{"@type":"Article","@id":"https:\/\/randomadult.local\/centos-6-5-and-ruby1-9-3-via-software-collections\/#article","isPartOf":{"@id":"https:\/\/randomadult.local\/centos-6-5-and-ruby1-9-3-via-software-collections\/"},"author":{"name":"digitalchild","@id":"https:\/\/randomadult.local\/#\/schema\/person\/b0b954202434291ace51b4e7a0a81c04"},"headline":"Centos 6.5 and Ruby 1.9.3 via Software Collections","datePublished":"2014-06-26T02:48:13+00:00","dateModified":"2014-06-26T02:48:13+00:00","mainEntityOfPage":{"@id":"https:\/\/randomadult.local\/centos-6-5-and-ruby1-9-3-via-software-collections\/"},"wordCount":418,"commentCount":2,"publisher":{"@id":"https:\/\/randomadult.local\/#organization"},"keywords":["backup","centos","linux","ruby","software collections"],"articleSection":["Geek","Tip"],"inLanguage":"en-US","potentialAction":[{"@type":"CommentAction","name":"Comment","target":["https:\/\/randomadult.local\/centos-6-5-and-ruby1-9-3-via-software-collections\/#respond"]}]},{"@type":"WebPage","@id":"https:\/\/randomadult.local\/centos-6-5-and-ruby1-9-3-via-software-collections\/","url":"https:\/\/randomadult.local\/centos-6-5-and-ruby1-9-3-via-software-collections\/","name":"Centos 6.5 and Ruby 1.9.3 via Software Collections","isPartOf":{"@id":"https:\/\/randomadult.local\/#website"},"datePublished":"2014-06-26T02:48:13+00:00","dateModified":"2014-06-26T02:48:13+00:00","description":"A quick guide on getting CentOS 6.5 and Ruby 1.9.3 installed via Software Collections. Includes a quick tip on having it work across reboots.","breadcrumb":{"@id":"https:\/\/randomadult.local\/centos-6-5-and-ruby1-9-3-via-software-collections\/#breadcrumb"},"inLanguage":"en-US","potentialAction":[{"@type":"ReadAction","target":["https:\/\/randomadult.local\/centos-6-5-and-ruby1-9-3-via-software-collections\/"]}]},{"@type":"BreadcrumbList","@id":"https:\/\/randomadult.local\/centos-6-5-and-ruby1-9-3-via-software-collections\/#breadcrumb","itemListElement":[{"@type":"ListItem","position":1,"name":"Home","item":"https:\/\/randomadult.local\/"},{"@type":"ListItem","position":2,"name":"Centos 6.5 and Ruby 1.9.3 via Software Collections"}]},{"@type":"WebSite","@id":"https:\/\/randomadult.local\/#website","url":"https:\/\/randomadult.local\/","name":"Random Adult","description":"Ramblings of a random adult","publisher":{"@id":"https:\/\/randomadult.local\/#organization"},"potentialAction":[{"@type":"SearchAction","target":{"@type":"EntryPoint","urlTemplate":"https:\/\/randomadult.local\/?s={search_term_string}"},"query-input":"required name=search_term_string"}],"inLanguage":"en-US"},{"@type":"Organization","@id":"https:\/\/randomadult.local\/#organization","name":"Random Adult","url":"https:\/\/randomadult.local\/","logo":{"@type":"ImageObject","inLanguage":"en-US","@id":"https:\/\/randomadult.local\/#\/schema\/logo\/image\/","url":"https:\/\/randomadult.local\/wp-content\/uploads\/2020\/01\/logo.png","contentUrl":"https:\/\/randomadult.local\/wp-content\/uploads\/2020\/01\/logo.png","width":320,"height":134,"caption":"Random Adult"},"image":{"@id":"https:\/\/randomadult.local\/#\/schema\/logo\/image\/"},"sameAs":["https:\/\/twitter.com\/dcwhatwhat"]},{"@type":"Person","@id":"https:\/\/randomadult.local\/#\/schema\/person\/b0b954202434291ace51b4e7a0a81c04","name":"digitalchild","image":{"@type":"ImageObject","inLanguage":"en-US","@id":"https:\/\/randomadult.local\/#\/schema\/person\/image\/","url":"https:\/\/secure.gravatar.com\/avatar\/e0331079f6730910bc7760cb8f781237?s=96&d=mm&r=g","contentUrl":"https:\/\/secure.gravatar.com\/avatar\/e0331079f6730910bc7760cb8f781237?s=96&d=mm&r=g","caption":"digitalchild"},"url":"https:\/\/randomadult.local\/author\/digitalchild\/"}]}},"_links":{"self":[{"href":"https:\/\/randomadult.local\/wp-json\/wp\/v2\/posts\/340"}],"collection":[{"href":"https:\/\/randomadult.local\/wp-json\/wp\/v2\/posts"}],"about":[{"href":"https:\/\/randomadult.local\/wp-json\/wp\/v2\/types\/post"}],"author":[{"embeddable":true,"href":"https:\/\/randomadult.local\/wp-json\/wp\/v2\/users\/1"}],"replies":[{"embeddable":true,"href":"https:\/\/randomadult.local\/wp-json\/wp\/v2\/comments?post=340"}],"version-history":[{"count":0,"href":"https:\/\/randomadult.local\/wp-json\/wp\/v2\/posts\/340\/revisions"}],"wp:attachment":[{"href":"https:\/\/randomadult.local\/wp-json\/wp\/v2\/media?parent=340"}],"wp:term":[{"taxonomy":"category","embeddable":true,"href":"https:\/\/randomadult.local\/wp-json\/wp\/v2\/categories?post=340"},{"taxonomy":"post_tag","embeddable":true,"href":"https:\/\/randomadult.local\/wp-json\/wp\/v2\/tags?post=340"}],"curies":[{"name":"wp","href":"https:\/\/api.w.org\/{rel}","templated":true}]}}