NameError: uninitialized constant Object::BOSH

46 views
Skip to first unread message

张 磊

unread,
May 3, 2012, 1:25:11 AM5/3/12
to bosh-dev
I have successed in the ruby configuration steps methoned in the
https://github.com/cloudfoundry/oss-docs/blob/master/bosh/documenta....

but I came across the ERROR below whenever I input bosh --version

NameError: uninitialized constant Object::BOSH

It is obviously that the class BOSH is undefined or can not be found
in the ruby file, and I have read the source code of CF but I can't
find any reason for this problem. Can anyone give me a hand?

Oleg Shaldibin

unread,
May 3, 2012, 1:29:23 AM5/3/12
to bosh...@cloudfoundry.org
Can you post the full stack trace?
--
Best,
Oleg

张 磊

unread,
May 3, 2012, 4:00:16 AM5/3/12
to bosh-dev
Thanks for your reply.This is it. If you need more information, please
contact me.
==================================================================================================================================
[root@localhost Harry]# bosh
/root/.rbenv/versions/1.9.2-p290/lib/ruby/gems/1.9.1/gems/
bosh_cli-0.17/bin/bosh:17:in `<top (required)>': uninitialized
constant Object::Bosh (NameError)
from /root/.rbenv/versions/1.9.2-p290/bin/bosh:19:in `load'
from /root/.rbenv/versions/1.9.2-p290/bin/bosh:19:in `<main>'

==================================================================================================================================


On 5月3日, 下午1时29分, Oleg Shaldibin <ol...@rbcon.com> wrote:
> Can you post the full stack trace?
>

Oleg Shaldybin

unread,
May 3, 2012, 4:16:02 AM5/3/12
to bosh...@cloudfoundry.org, bosh-dev
Are you sure you ran 'rbenv rehash'?

Sent from my iPhone

张 磊

unread,
May 3, 2012, 6:47:16 AM5/3/12
to bosh-dev
Yes, I did. Is there any way to check whether my steps before are all
right? Thus I may find out where is wrong.

On 5月3日, 下午4时16分, Oleg Shaldybin <ol...@rbcon.com> wrote:
> Are you sure you ran 'rbenv rehash'?
>
> Sent from my iPhone
>

Oleg Shaldibin

unread,
May 3, 2012, 2:07:53 PM5/3/12
to bosh...@cloudfoundry.org
This looks like some environmental issue. Can you try removing the gem, running 'rbenv rehash', installing it again and running 'rbenv rehash' again? Also, make sure you're installing the gem with the same version of Ruby you're using afterwards.
--
Best,
Oleg

张 磊

unread,
May 4, 2012, 12:57:26 AM5/4/12
to bosh-dev
My ruby -v is 1.9.2 and gem -v is 1.3.7 Is this OK?

张 磊

unread,
May 4, 2012, 2:21:15 AM5/4/12
to bosh-dev
I tried it again and now there no error occurs, but whenever I input
¨bosh --version" there's nothing to be shown below. I really confused
now. *_* Whatś the reason?

On 5月4日, 上午2时07分, Oleg Shaldibin <ol...@rbcon.com> wrote:

张 磊

unread,
May 7, 2012, 1:01:03 AM5/7/12
to bosh-dev
My BOSH works now. It seems I should run commands to install bosh
deployer. Thank you all the same.

On 5月4日, 上午2时07分, Oleg Shaldibin <ol...@rbcon.com> wrote:
Reply all
Reply to author
Forward
0 new messages