aspose file tools*
The moose likes Ruby and the fly likes ruby script/server is not working Big Moose Saloon
  Search | Java FAQ | Recent Topics | Flagged Topics | Hot Topics | Zero Replies
Register / Login
JavaRanch » Java Forums » Languages » Ruby
Bookmark "ruby script/server is not working" Watch "ruby script/server is not working" New topic
Author

ruby script/server is not working

Selva Chezhian Labam
Greenhorn

Joined: Sep 08, 2010
Posts: 11
Hi All,

I am using ubuntu. I have installed rails in my computer. And I have installed all the required gems. But while I am starting the server by using the command ruby script/server it is returning the following error. Can anybody give the solution for the problem?

=> Booting Mongrel (use 'script/server webrick' to force WEBrick)
=> Rails 2.2.2 application starting on http://0.0.0.0:3000
=> Call with -d to detach
=> Ctrl-C to shutdown server
Exiting
/usr/lib/ruby/gems/1.8/gems/activesupport-2.2.2/lib/active_support/dependencies.rb:142:in `load_without_new_constant_marking': no such file to load -- mongrel_rails (MissingSourceFile)
from /usr/lib/ruby/gems/1.8/gems/activesupport-2.2.2/lib/active_support/dependencies.rb:142:in `load'
from /usr/lib/ruby/gems/1.8/gems/activesupport-2.2.2/lib/active_support/dependencies.rb:521:in `new_constants_in'
from /usr/lib/ruby/gems/1.8/gems/activesupport-2.2.2/lib/active_support/dependencies.rb:142:in `load'
from /usr/lib/ruby/gems/1.8/gems/rails-2.2.2/lib/commands/servers/mongrel.rb:64
from /usr/local/lib/site_ruby/1.8/rubygems/custom_require.rb:29:in `gem_original_require'
from /usr/local/lib/site_ruby/1.8/rubygems/custom_require.rb:29:in `require'
from /usr/lib/ruby/gems/1.8/gems/activesupport-2.2.2/lib/active_support/dependencies.rb:153:in `require'
from /usr/lib/ruby/gems/1.8/gems/activesupport-2.2.2/lib/active_support/dependencies.rb:521:in `new_constants_in'
from /usr/lib/ruby/gems/1.8/gems/activesupport-2.2.2/lib/active_support/dependencies.rb:153:in `require'
from /usr/lib/ruby/gems/1.8/gems/rails-2.2.2/lib/commands/server.rb:49
from /usr/local/lib/site_ruby/1.8/rubygems/custom_require.rb:29:in `gem_original_require'
from /usr/local/lib/site_ruby/1.8/rubygems/custom_require.rb:29:in `require'
from script/server:3

Thanks & Regards,
Selva Chezhian L.
santoshkumar savadatti
Ranch Hand

Joined: Apr 27, 2010
Posts: 95
Iam a RoR newbie myself, but I think you cannot start the server without creating a Project.
First create a project.Then, make sure you are in project's directory.For e.g, my project is blog.It is situated in c:\sites.
So, i need to be in c:\sites\blog>
Also, please note that the command to launch the server in Rails3 is
Rails Server
Try it

EDIT:My bad, failed to notice you are running Rails 2 . But still I believe, the creating project to launch server is valid for Rails 2 Also.
Katrina Owen
Sheriff

Joined: Nov 03, 2006
Posts: 1362
    
  17
santoshkumar is correct, you need to create a project first. With rails 2 that is:

rails yourprojectname

then change directory into your project

cd yourprojectname

and start the server with

./script/server
Selva Chezhian Labam
Greenhorn

Joined: Sep 08, 2010
Posts: 11
I have already done the suggestion given by you....

I have created a project and sure I am inside my project only.

I am using rails 2.2.2 only.
Katrina Owen
Sheriff

Joined: Nov 03, 2006
Posts: 1362
    
  17
Would you walk me through exactly what you are doing to create a new project and start the server?
santoshkumar savadatti
Ranch Hand

Joined: Apr 27, 2010
Posts: 95
It looks like a problem with Mongrel.

try typing .script/server webrick.
I'm sure that'll solve the issue
 
I agree. Here's the link: http://aspose.com/file-tools
 
subject: ruby script/server is not working