# Rubygems only runs as root

**URL:** <https://www.ruby-forum.com/t/rubygems-only-runs-as-root/73161>\
**Category:** Ruby\
**Created:** [October 22, 2006, 8:15am UTC](https://www.ruby-forum.com/t/rubygems-only-runs-as-root/73161 "2006-10-22T08:15:55Z")\
**Posts on this page:** 2\
**Page:** 1

<div class="post-metadata">

**Author:** ![unknown](https://www.ruby-forum.com/letter_avatar_proxy/v4/letter/u/4bbf92/32.png) [@unknown](https://www.ruby-forum.com/u/unknown)\
**Post date:** [October 22, 2006, 8:15am UTC](https://www.ruby-forum.com/t/rubygems-only-runs-as-root/73161/1 "2006-10-22T08:15:55Z")

</div>

Loaded the lastest rubygems (0.9.0) as root, like always,  
but in my USER account I can’t see it anymore. I have no  
problem doing this on my laptop. The only difference is I’m  
using ruby 1.8.5 in my USER account, while the root has 1.8.4.

I’m using PCLinuxOS 0.9.2 on my desktop and 0.9.3a on the laptop.

In both cases gem was placed in /usr/bin/gem and the PATH is set  
to see this dir in both case. But when I run the gem command from my  
desktop I get the following message:

$ /usr/bin/gem  
/usr/bin/gem:10: unitialized constant Gem (NameError)

or

$ gem  
bash: /usr/local/bin/gem: No such file or directory

---

<div class="post-metadata">

**Author:** ![unknown](https://www.ruby-forum.com/letter_avatar_proxy/v4/letter/u/4bbf92/32.png) [@unknown](https://www.ruby-forum.com/u/unknown)\
**Post date:** [October 22, 2006, 2:02pm UTC](https://www.ruby-forum.com/t/rubygems-only-runs-as-root/73161/2 "2006-10-22T14:02:36Z")

</div>

On 10/22/06, removed\_email\_address@domain.invalid [removed\_email\_address@domain.invalid](mailto:removed_email_address@domain.invalid) wrote:

> Loaded the lastest rubygems (0.9.0) as root, like always,  
> but in my USER account I can’t see it anymore. I have no  
> problem doing this on my laptop. The only difference is I’m  
> using ruby 1.8.5 in my USER account, while the root has 1.8.4.

The ‘gem’ command is just a front-end to code in the RubyGems library,  
so you probably need to install RubyGems under your user account copy  
of Ruby (the 1.8.5 installation) as well.
