# Gem on ubuntu problem : /usr/local/lib/site\_ruby/1.8/rubygem

**URL:** <https://rubytalk.org/t/gem-on-ubuntu-problem-usr-local-lib-site-ruby-1-8-rubygem/43342>\
**Category:** ruby-talk\
**Created:** [27 December 2007 17:43 UTC](https://rubytalk.org/t/gem-on-ubuntu-problem-usr-local-lib-site-ruby-1-8-rubygem/43342 "2007-12-27T17:43:02Z")\
**Posts on this page:** 5\
**Page:** 1

<div class="post-metadata">

**Author:** ![Jp\_Jp](https://avatars.discourse-cdn.com/v4/letter/j/53a042/32.png) [@Jp\_Jp](https://rubytalk.org/u/Jp_Jp)\
**Post date:** [27 December 2007 17:43 UTC](https://rubytalk.org/t/gem-on-ubuntu-problem-usr-local-lib-site-ruby-1-8-rubygem/43342/1 "2007-12-27T17:43:02Z")

</div>

Hi all,

I've got a serious problem installing gem on my ubuntu. i used the  
apt-get manager.

here is what i get when i try to launch gem :  
/usr/local/lib/site\_ruby/1.8/rubygems/custom\_require.rb:27:in  
`gem\_original\_require': no such file to load -- sources (LoadError)  
&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;from  
/usr/local/lib/site\_ruby/1.8/rubygems/custom\_require.rb:27:in `require'  
&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;from  
/usr/local/lib/site\_ruby/1.8/rubygems/source\_info\_cache.rb:6  
&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;from  
/usr/local/lib/site\_ruby/1.8/rubygems/custom\_require.rb:27:in  
`gem\_original\_require'  
&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;from  
/usr/local/lib/site\_ruby/1.8/rubygems/custom\_require.rb:27:in `require'  
&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;from  
/usr/local/lib/site\_ruby/1.8/rubygems/remote\_installer.rb:12  
&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;from  
/usr/local/lib/site\_ruby/1.8/rubygems/custom\_require.rb:27:in  
`gem\_original\_require'  
&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;from  
/usr/local/lib/site\_ruby/1.8/rubygems/custom\_require.rb:27:in `require'  
&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;from /usr/local/lib/site\_ruby/1.8/rubygems.rb:112:in  
`manage\_gems'  
&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;from /usr/bin/gem:10

even whe I add a "require 'rubygems/gem\_runner'" in /usr/bin/gem, same  
error (but last line number is 11).

what can I do ?

> **···**
>
> --  
> Posted via [http://www.ruby-forum.com/](http://www.ruby-forum.com/).

---

<div class="post-metadata">

**Author:** ![Michael\_Greenly](https://avatars.discourse-cdn.com/v4/letter/m/b2d939/32.png) [@Michael\_Greenly](https://rubytalk.org/u/Michael_Greenly)\
**Post date:** [28 December 2007 03:07 UTC](https://rubytalk.org/t/gem-on-ubuntu-problem-usr-local-lib-site-ruby-1-8-rubygem/43342/2 "2007-12-28T03:07:51Z")

</div>

Something doesn't add up. It's looking in /usr/local. It looks to me like  
you've either done a 'gem update --system' or tried to install gems from  
source at some point. Regardless removing it and reinstalling it should fix  
the problem.

This should remove it  
$\> sudo apt-get remove --purge rubygems

Then you're free to install from source or from apt  
$\> sudo apt-get install rubygems

> **···**
>
> On Dec 27, 2007 11:43 AM, Jp Jp \<nnczm12u5227vj1@jetable.com\> wrote:
> 
> > Hi all,
> > 
> > I've got a serious problem installing gem on my ubuntu. i used the  
> > apt-get manager.
> > 
> > here is what i get when i try to launch gem :  
> > /usr/local/lib/site\_ruby/1.8/rubygems/custom\_require.rb:27:in  
> > `gem\_original\_require': no such file to load -- sources (LoadError)  
> > &nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;from  
> > /usr/local/lib/site\_ruby/1.8/rubygems/custom\_require.rb:27:in `require'  
> > &nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;from  
> > /usr/local/lib/site\_ruby/1.8/rubygems/source\_info\_cache.rb:6  
> > &nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;from  
> > /usr/local/lib/site\_ruby/1.8/rubygems/custom\_require.rb:27:in  
> > `gem\_original\_require'  
> > &nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;from  
> > /usr/local/lib/site\_ruby/1.8/rubygems/custom\_require.rb:27:in `require'  
> > &nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;from  
> > /usr/local/lib/site\_ruby/1.8/rubygems/remote\_installer.rb:12  
> > &nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;from  
> > /usr/local/lib/site\_ruby/1.8/rubygems/custom\_require.rb:27:in  
> > `gem\_original\_require'  
> > &nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;from  
> > /usr/local/lib/site\_ruby/1.8/rubygems/custom\_require.rb:27:in `require'  
> > &nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;from /usr/local/lib/site\_ruby/1.8/rubygems.rb:112:in  
> > `manage\_gems'  
> > &nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;from /usr/bin/gem:10
> > 
> > even whe I add a "require 'rubygems/gem\_runner'" in /usr/bin/gem, same  
> > error (but last line number is 11).
> > 
> > what can I do ?  
> > --  
> > Posted via [http://www.ruby-forum.com/\](http://www.ruby-forum.com/%5C).
> 
> --  
> Michael Greenly

---

<div class="post-metadata">

**Author:** ![Jp\_Jp](https://avatars.discourse-cdn.com/v4/letter/j/53a042/32.png) [@Jp\_Jp](https://rubytalk.org/u/Jp_Jp)\
**Post date:** [28 December 2007 09:33 UTC](https://rubytalk.org/t/gem-on-ubuntu-problem-usr-local-lib-site-ruby-1-8-rubygem/43342/3 "2007-12-28T09:33:42Z")

</div>

Michael Greenly wrote:

> This should remove it  
> $\> sudo apt-get remove --purge rubygems
> 
> Then you're free to install from source or from apt  
> $\> sudo apt-get install rubygems

it stil doesn't work for me ☹

> **···**
>
> --  
> Posted via [http://www.ruby-forum.com/\](http://www.ruby-forum.com/%5C).

---

<div class="post-metadata">

**Author:** ![Michael\_Greenly](https://avatars.discourse-cdn.com/v4/letter/m/b2d939/32.png) [@Michael\_Greenly](https://rubytalk.org/u/Michael_Greenly)\
**Post date:** [28 December 2007 10:03 UTC](https://rubytalk.org/t/gem-on-ubuntu-problem-usr-local-lib-site-ruby-1-8-rubygem/43342/4 "2007-12-28T10:03:48Z")

</div>

I'm betting there's a partially installed 'from source gems' there then?  
Make sure there's nothing in /usr/local/lib/site\_ruby/gems or /var/lib/gems  
before reinstalling.

> **···**
>
> On Dec 28, 2007 3:33 AM, Jp Jp \<nnczm12u5227vj1@jetable.com\> wrote:
> 
> > Michael Greenly wrote:  
> > \> This should remove it  
> > \> $\> sudo apt-get remove --purge rubygems  
> > \>  
> > \> Then you're free to install from source or from apt  
> > \> $\> sudo apt-get install rubygems
> > 
> > it stil doesn't work for me ☹  
> > --  
> > Posted via [http://www.ruby-forum.com/\](http://www.ruby-forum.com/%5C).
> 
> --  
> Michael Greenly  
> [http://blog.michaelgreenly.com](http://blog.michaelgreenly.com)

---

<div class="post-metadata">

**Author:** ![Jp\_Jp](https://avatars.discourse-cdn.com/v4/letter/j/53a042/32.png) [@Jp\_Jp](https://rubytalk.org/u/Jp_Jp)\
**Post date:** [28 December 2007 10:13 UTC](https://rubytalk.org/t/gem-on-ubuntu-problem-usr-local-lib-site-ruby-1-8-rubygem/43342/5 "2007-12-28T10:13:57Z")

</div>

Michael Greenly wrote:

> I'm betting there's a partially installed 'from source gems' there then?  
> Make sure there's nothing in /usr/local/lib/site\_ruby/gems or  
> /var/lib/gems  
> before reinstalling.

well you are right about a partially installed 'from source gems', but  
I removed everything in both directories

I ended with compiling ruby 1.9 myself and gem provided with it is ok.  
compiling ruby is pretty fast and harmless.  
still, I don't understand why my standard ubuntu ruby installation was  
KO..

> **···**
>
> --  
> Posted via [http://www.ruby-forum.com/\](http://www.ruby-forum.com/%5C).
