Rails with webrick slow as snails

  • Thread starter Sarah Tanembaum
  • Start date
S

Sarah Tanembaum

I've followed the sample installation
http://www.leetsoft.com/rails/lesson1.html step by step and it works, I
think. I got the same message as the example

BUT

1. when starting the webrick from the command line, IT'S SLOW AS SNAIL
2. when pointing to the http://localhost:3000/hello/index, IT SLOW AS
SNAIL AS WELL. It takes at least 4 minutes to get the result.

What am I doing wrong?


Below are the error on the console:

#<WEBrick::HTTPStatus::NotFound: `/hello/index' not found.>
127.0.0.1 - - [01/Dec/2004:13:20:29 Eastern Standard Time] "GET
/hello/index HTTP/1.1" 200 306
- -> /hello/index
#<WEBrick::HTTPStatus::NotFound: `/favicon.ico' not found.>
[2004-12-01 13:25:19] ERROR `/favicon.ico' not found.
127.0.0.1 - - [01/Dec/2004:13:25:19 Eastern Standard Time] "GET
/favicon.ico HTTP/1.1" 404 281
- -> /favicon.ico
#<WEBrick::HTTPStatus::NotFound: `/hello/index' not found.>
 
D

David Heinemeier Hansson

BUT
1. when starting the webrick from the command line, IT'S SLOW AS SNAIL
2. when pointing to the http://localhost:3000/hello/index, IT SLOW AS
SNAIL AS WELL. It takes at least 4 minutes to get the result.

What am I doing wrong?

What kind of hardware are you running on? 4 minutes sound insane in any
case, though.

The reloading WEBrick dispatcher is indeed dog slow in 0.8.5 (around ~1
second per reload on my G4 1.5ghz). This is being greatly remedied in
the forthcoming 0.9.0 that's already available as beta gems right now.

The new approach uses a two-tiered approach to requiring classes where
your app is reloaded on every request, but the framework remains cached
and the interpreter is reused. This is much, much more efficient and
hence much faster.

One guy reported going from 10s per page load to much less than a
second on his G3 400mhz Mac.

So if you don't find out what's screwing up your current installation,
you might want to try out the beta gems. They can be fetched with:

gem update -s http://gems.rubyonrails.org

For convenience, there's even an executable start_server command in the
root of new apps created with 0.9. Click that and the WEBrick server
starts.
--
David Heinemeier Hansson,
http://www.basecamphq.com/ -- Web-based Project Management
http://www.rubyonrails.org/ -- Web-application framework for Ruby
http://macromates.com/ -- TextMate: Code and markup editor (OS X)
http://www.loudthinking.com/ -- Broadcasting Brain
 
S

Sarah Tanembaum

David said:
What kind of hardware are you running on? 4 minutes sound insane in any
case, though.

The reloading WEBrick dispatcher is indeed dog slow in 0.8.5 (around ~1
second per reload on my G4 1.5ghz). This is being greatly remedied in
the forthcoming 0.9.0 that's already available as beta gems right now.

The new approach uses a two-tiered approach to requiring classes where
your app is reloaded on every request, but the framework remains cached
and the interpreter is reused. This is much, much more efficient and
hence much faster.

One guy reported going from 10s per page load to much less than a second
on his G3 400mhz Mac.

So if you don't find out what's screwing up your current installation,
you might want to try out the beta gems. They can be fetched with:

gem update -s http://gems.rubyonrails.org

For convenience, there's even an executable start_server command in the
root of new apps created with 0.9. Click that and the WEBrick server
starts.
--
David Heinemeier Hansson,
http://www.basecamphq.com/ -- Web-based Project Management
http://www.rubyonrails.org/ -- Web-application framework for Ruby
http://macromates.com/ -- TextMate: Code and markup editor (OS X)
http://www.loudthinking.com/ -- Broadcasting Brain

Hi David, I'm running PIII/800MHz laptop. Perhaps I did exagerate a bit,
but not much. It takes at least 3 minutes for the sample page to come up
and it will take just as long to reload/refresh the same page. Plus,
starting up the "ruby dispatch.servlet -a" takes at least 1 minutes.

I will try what you suggested by updating it to the latest beta.

Thanks
 
D

David Heinemeier Hansson

Hi David, I'm running PIII/800MHz laptop. Perhaps I did exagerate a
bit, but not much. It takes at least 3 minutes for the sample page to
come up and it will take just as long to reload/refresh the same page.
Plus, starting up the "ruby dispatch.servlet -a" takes at least 1
minutes.

I will try what you suggested by updating it to the latest beta.

Something is obviously broken in your setup. Your machine should be
fully capable of reloading that screen in MAX 5 seconds, I'd say. And
I'd think it should be more like 2-3. I wonder if something is trying
to resolve something and waiting for a timeout. Could sound like it.

If that's the case, maybe it won't even help to upgrade to the beta
rails. You should probably try do to a simple test with webrick and see
if you can get that to perform if possible.
--
David Heinemeier Hansson,
http://www.basecamphq.com/ -- Web-based Project Management
http://www.rubyonrails.org/ -- Web-application framework for Ruby
http://macromates.com/ -- TextMate: Code and markup editor (OS X)
http://www.loudthinking.com/ -- Broadcasting Brain
 
L

Lothar Scholz

Hello Sarah,

ST> Hi David, I'm running PIII/800MHz laptop. Perhaps I did exagerate a bit,
ST> but not much. It takes at least 3 minutes for the sample page to come up
ST> and it will take just as long to reload/refresh the same page. Plus,
ST> starting up the "ruby dispatch.servlet -a" takes at least 1 minutes.

ST> I will try what you suggested by updating it to the latest beta.

Do you have the Windows SP2 firewall enabled ? I also got a 20 sec
delay for the first connect on my 2,8Ghz PIV machine (VMWare sandbox)
before i turned the firewall off.

3 minutes is a clear sign that the problem is your envrionment and not
inside ruby/rails.
 
S

Sarah Tanembaum

Lothar said:
Hello Sarah,

ST> Hi David, I'm running PIII/800MHz laptop. Perhaps I did exagerate a bit,
ST> but not much. It takes at least 3 minutes for the sample page to come up
ST> and it will take just as long to reload/refresh the same page. Plus,
ST> starting up the "ruby dispatch.servlet -a" takes at least 1 minutes.

ST> I will try what you suggested by updating it to the latest beta.

Do you have the Windows SP2 firewall enabled ? I also got a 20 sec
delay for the first connect on my 2,8Ghz PIV machine (VMWare sandbox)
before i turned the firewall off.

3 minutes is a clear sign that the problem is your envrionment and not
inside ruby/rails.

Dear David & Lothar, I did try using the Webrick's Hello servlet sample
script and the response is much faster, both the startup and http
access. Any idea?

Thanks
 
S

Sarah Tanembaum

Lothar said:
Hello Sarah,

ST> Hi David, I'm running PIII/800MHz laptop. Perhaps I did exagerate a bit,
ST> but not much. It takes at least 3 minutes for the sample page to come up
ST> and it will take just as long to reload/refresh the same page. Plus,
ST> starting up the "ruby dispatch.servlet -a" takes at least 1 minutes.

ST> I will try what you suggested by updating it to the latest beta.

Do you have the Windows SP2 firewall enabled ? I also got a 20 sec
delay for the first connect on my 2,8Ghz PIV machine (VMWare sandbox)
before i turned the firewall off.

3 minutes is a clear sign that the problem is your envrionment and not
inside ruby/rails.

Below are the log from the console of '%> ruby dispatch.servlet -a'

C:\rails\public>ruby dispatch.servlet -a
dispatch: invalid option: -a
[2004-12-01 17:18:46] INFO WEBrick 1.3.1
[2004-12-01 17:18:46] INFO ruby 1.8.2 (2004-11-06) [i386-mswin32]
[2004-12-01 17:18:46] INFO WEBrick::HTTPServer#start: pid=2620 port=3000
#<WEBrick::HTTPStatus::NotFound: `/favicon.ico' not found.>
[2004-12-01 17:21:18] ERROR `/favicon.ico' not found.
127.0.0.1 - - [01/Dec/2004:17:21:18 Eastern Standard Time] "GET
/favicon.ico HTTP/1.1" 404 281
- -> /favicon.ico
#<WEBrick::HTTPStatus::NotFound: `/hello/index' not found.>
X:/websites/rails/public/../config/environments/shared.rb:1: warning:
already initialized constant ADDITIONAL_LOAD_PATHS
#<NameError: undefined method `database_configurations' for class
`Builder::BlankSlate'>
["x:/apps/ruby/ruby-1.8/lib/ruby/gems/1.8/gems/actionpack-0.9.5.200412010045/lib/action_view/vendor/builder/blankslate.rb:20:in
`un
ef_method'",
"x:/apps/ruby/ruby-1.8/lib/ruby/gems/1.8/gems/actionpack-0.9.5.200412010045/lib/action_view/vendor/builder/blankslate.
b:20:in `hide'",
"x:/apps/ruby/ruby-1.8/lib/ruby/gems/1.8/gems/actionpack-0.9.5.200412010045/lib/action_view/vendor/builder/blanksl
te.rb:48:in `method_added'",
"X:/websites/rails/public/../config/environments/shared.rb:15",
"x:/apps/ruby/ruby-1.8/lib/ruby/site_r
by/1.8/rubygems/loadpath_manager.rb:5:in `require__'",
"x:/apps/ruby/ruby-1.8/lib/ruby/site_ruby/1.8/rubygems/loadpath_manager.rb:5
in `require'",
"X:/websites/rails/public/../config/environments/production.rb:1",
"x:/apps/ruby/ruby-1.8/lib/ruby/site_ruby/1.8/rub
gems/loadpath_manager.rb:5:in `require__'",
"x:/apps/ruby/ruby-1.8/lib/ruby/site_ruby/1.8/rubygems/loadpath_manager.rb:5:in
`requir
'", "X:/websites/rails/public/dispatch.rb:3",
"x:/apps/ruby/ruby-1.8/lib/ruby/gems/1.8/gems/rails-0.8.5.200412010045/lib/webrick_se
ver.rb:122:in `load'",
"x:/apps/ruby/ruby-1.8/lib/ruby/gems/1.8/gems/rails-0.8.5.200412010045/lib/webrick_server.rb:122:in
`handle_
ispatch'",
"x:/apps/ruby/ruby-1.8/lib/ruby/gems/1.8/gems/rails-0.8.5.200412010045/lib/webrick_server.rb:101:in
`handle_mapped'", "x
/apps/ruby/ruby-1.8/lib/ruby/gems/1.8/gems/rails-0.8.5.200412010045/lib/webrick_server.rb:53:in
`do_GET'", "x:/apps/ruby/ruby-1.8/l
b/ruby/1.8/webrick/httpservlet/abstract.rb:35:in `__send__'",
"x:/apps/ruby/ruby-1.8/lib/ruby/1.8/webrick/httpservlet/abstract.rb:3
:in `service'",
"x:/apps/ruby/ruby-1.8/lib/ruby/1.8/webrick/httpserver.rb:97:in
`service'", "x:/apps/ruby/ruby-1.8/lib/ruby/1.8/web
ick/httpserver.rb:58:in `run'",
"x:/apps/ruby/ruby-1.8/lib/ruby/1.8/webrick/server.rb:153:in
`start_thread'", "x:/apps/ruby/ruby-1.
/lib/ruby/1.8/webrick/server.rb:147:in `start'",
"x:/apps/ruby/ruby-1.8/lib/ruby/1.8/webrick/server.rb:147:in
`start_thread'", "x:/
pps/ruby/ruby-1.8/lib/ruby/1.8/webrick/server.rb:97:in `start'",
"x:/apps/ruby/ruby-1.8/lib/ruby/1.8/webrick/server.rb:89:in `each'
, "x:/apps/ruby/ruby-1.8/lib/ruby/1.8/webrick/server.rb:89:in `start'",
"x:/apps/ruby/ruby-1.8/lib/ruby/1.8/webrick/server.rb:79:in
`start'", "x:/apps/ruby/ruby-1.8/lib/ruby/1.8/webrick/server.rb:79:in
`start'", "x:/apps/ruby/ruby-1.8/lib/ruby/gems/1.8/gems/rails
0.8.5.200412010045/lib/webrick_server.rb:37:in `dispatch'",
"dispatch.servlet:45"]
[2004-12-01 17:21:40] ERROR `/hello/index' not found.
127.0.0.1 - - [01/Dec/2004:17:21:30 Eastern Standard Time] "GET
/hello/index HTTP/1.1" 404 281
- -> /hello/index
#<WEBrick::HTTPStatus::NotFound: `/favicon.ico' not found.>
[2004-12-01 17:21:41] ERROR `/favicon.ico' not found.
127.0.0.1 - - [01/Dec/2004:17:21:40 Eastern Standard Time] "GET
/favicon.ico HTTP/1.1" 404 281
- -> /favicon.ico
#<WEBrick::HTTPStatus::NotFound: `/hello/index' not found.>
127.0.0.1 - - [01/Dec/2004:17:22:42 Eastern Standard Time] "GET
/hello/index HTTP/1.1" 200 306
- -> /hello/index
#<WEBrick::HTTPStatus::NotFound: `/favicon.ico' not found.>
[2004-12-01 17:22:48] ERROR `/favicon.ico' not found.
127.0.0.1 - - [01/Dec/2004:17:22:48 Eastern Standard Time] "GET
/favicon.ico HTTP/1.1" 404 281
- -> /favicon.ico
#<WEBrick::HTTPStatus::NotFound: `/hello/index' not found.>
127.0.0.1 - - [01/Dec/2004:17:23:05 Eastern Standard Time] "GET
/hello/index HTTP/1.1" 200 306
- -> /hello/index
#<WEBrick::HTTPStatus::NotFound: `/favicon.ico' not found.>
[2004-12-01 17:23:07] ERROR `/favicon.ico' not found.
127.0.0.1 - - [01/Dec/2004:17:23:07 Eastern Standard Time] "GET
/favicon.ico HTTP/1.1" 404 281
- -> /favicon.ico
#<WEBrick::HTTPStatus::NotFound: `/hello/index' not found.>
127.0.0.1 - - [01/Dec/2004:17:23:25 Eastern Standard Time] "GET
/hello/index HTTP/1.1" 200 306
- -> /hello/index
#<WEBrick::HTTPStatus::NotFound: `/favicon.ico' not found.>
[2004-12-01 17:23:31] ERROR `/favicon.ico' not found.
127.0.0.1 - - [01/Dec/2004:17:23:31 Eastern Standard Time] "GET
/favicon.ico HTTP/1.1" 404 281
- -> /favicon.ico
 
T

Tobias Luetke

under windows it seems to be very important to use rubyw.exe and not
ruby.exe for performance. Maybe thats it ?


Lothar Scholz wrote:

Hello Sarah,

ST> Hi David, I'm running PIII/800MHz laptop. Perhaps I did exagerate a bit,
ST> but not much. It takes at least 3 minutes for the sample page to come up
ST> and it will take just as long to reload/refresh the same page. Plus,
ST> starting up the "ruby dispatch.servlet -a" takes at least 1 minutes.

ST> I will try what you suggested by updating it to the latest beta.

Do you have the Windows SP2 firewall enabled ? I also got a 20 sec
delay for the first connect on my 2,8Ghz PIV machine (VMWare sandbox)
before i turned the firewall off.

3 minutes is a clear sign that the problem is your envrionment and not
inside ruby/rails.

Below are the log from the console of '%> ruby dispatch.servlet -a'

C:\rails\public>ruby dispatch.servlet -a
dispatch: invalid option: -a
[2004-12-01 17:18:46] INFO WEBrick 1.3.1
[2004-12-01 17:18:46] INFO ruby 1.8.2 (2004-11-06) [i386-mswin32]
[2004-12-01 17:18:46] INFO WEBrick::HTTPServer#start: pid=2620 port=3000
#<WEBrick::HTTPStatus::NotFound: `/favicon.ico' not found.>
[2004-12-01 17:21:18] ERROR `/favicon.ico' not found.
127.0.0.1 - - [01/Dec/2004:17:21:18 Eastern Standard Time] "GET
/favicon.ico HTTP/1.1" 404 281
- -> /favicon.ico
#<WEBrick::HTTPStatus::NotFound: `/hello/index' not found.>
X:/websites/rails/public/../config/environments/shared.rb:1: warning:
already initialized constant ADDITIONAL_LOAD_PATHS
#<NameError: undefined method `database_configurations' for class
`Builder::BlankSlate'>
["x:/apps/ruby/ruby-1.8/lib/ruby/gems/1.8/gems/actionpack-0.9.5.200412010045/lib/action_view/vendor/builder/blankslate.rb:20:in
`un
ef_method'",
"x:/apps/ruby/ruby-1.8/lib/ruby/gems/1.8/gems/actionpack-0.9.5.200412010045/lib/action_view/vendor/builder/blankslate.
b:20:in `hide'",
"x:/apps/ruby/ruby-1.8/lib/ruby/gems/1.8/gems/actionpack-0.9.5.200412010045/lib/action_view/vendor/builder/blanksl
te.rb:48:in `method_added'",
"X:/websites/rails/public/../config/environments/shared.rb:15",
"x:/apps/ruby/ruby-1.8/lib/ruby/site_r
by/1.8/rubygems/loadpath_manager.rb:5:in `require__'",
"x:/apps/ruby/ruby-1.8/lib/ruby/site_ruby/1.8/rubygems/loadpath_manager.rb:5
in `require'",
"X:/websites/rails/public/../config/environments/production.rb:1",
"x:/apps/ruby/ruby-1.8/lib/ruby/site_ruby/1.8/rub
gems/loadpath_manager.rb:5:in `require__'",
"x:/apps/ruby/ruby-1.8/lib/ruby/site_ruby/1.8/rubygems/loadpath_manager.rb:5:in
`requir
'", "X:/websites/rails/public/dispatch.rb:3",
"x:/apps/ruby/ruby-1.8/lib/ruby/gems/1.8/gems/rails-0.8.5.200412010045/lib/webrick_se
ver.rb:122:in `load'",
"x:/apps/ruby/ruby-1.8/lib/ruby/gems/1.8/gems/rails-0.8.5.200412010045/lib/webrick_server.rb:122:in
`handle_
ispatch'",
"x:/apps/ruby/ruby-1.8/lib/ruby/gems/1.8/gems/rails-0.8.5.200412010045/lib/webrick_server.rb:101:in
`handle_mapped'", "x
/apps/ruby/ruby-1.8/lib/ruby/gems/1.8/gems/rails-0.8.5.200412010045/lib/webrick_server.rb:53:in
`do_GET'", "x:/apps/ruby/ruby-1.8/l
b/ruby/1.8/webrick/httpservlet/abstract.rb:35:in `__send__'",
"x:/apps/ruby/ruby-1.8/lib/ruby/1.8/webrick/httpservlet/abstract.rb:3
:in `service'",
"x:/apps/ruby/ruby-1.8/lib/ruby/1.8/webrick/httpserver.rb:97:in
`service'", "x:/apps/ruby/ruby-1.8/lib/ruby/1.8/web
ick/httpserver.rb:58:in `run'",
"x:/apps/ruby/ruby-1.8/lib/ruby/1.8/webrick/server.rb:153:in
`start_thread'", "x:/apps/ruby/ruby-1.
/lib/ruby/1.8/webrick/server.rb:147:in `start'",
"x:/apps/ruby/ruby-1.8/lib/ruby/1.8/webrick/server.rb:147:in
`start_thread'", "x:/
pps/ruby/ruby-1.8/lib/ruby/1.8/webrick/server.rb:97:in `start'",
"x:/apps/ruby/ruby-1.8/lib/ruby/1.8/webrick/server.rb:89:in `each'
, "x:/apps/ruby/ruby-1.8/lib/ruby/1.8/webrick/server.rb:89:in `start'",
"x:/apps/ruby/ruby-1.8/lib/ruby/1.8/webrick/server.rb:79:in
`start'", "x:/apps/ruby/ruby-1.8/lib/ruby/1.8/webrick/server.rb:79:in
`start'", "x:/apps/ruby/ruby-1.8/lib/ruby/gems/1.8/gems/rails
0.8.5.200412010045/lib/webrick_server.rb:37:in `dispatch'",
"dispatch.servlet:45"]
[2004-12-01 17:21:40] ERROR `/hello/index' not found.
127.0.0.1 - - [01/Dec/2004:17:21:30 Eastern Standard Time] "GET
/hello/index HTTP/1.1" 404 281
- -> /hello/index
#<WEBrick::HTTPStatus::NotFound: `/favicon.ico' not found.>
[2004-12-01 17:21:41] ERROR `/favicon.ico' not found.
127.0.0.1 - - [01/Dec/2004:17:21:40 Eastern Standard Time] "GET
/favicon.ico HTTP/1.1" 404 281
- -> /favicon.ico
#<WEBrick::HTTPStatus::NotFound: `/hello/index' not found.>
127.0.0.1 - - [01/Dec/2004:17:22:42 Eastern Standard Time] "GET
/hello/index HTTP/1.1" 200 306
- -> /hello/index
#<WEBrick::HTTPStatus::NotFound: `/favicon.ico' not found.>
[2004-12-01 17:22:48] ERROR `/favicon.ico' not found.
127.0.0.1 - - [01/Dec/2004:17:22:48 Eastern Standard Time] "GET
/favicon.ico HTTP/1.1" 404 281
- -> /favicon.ico
#<WEBrick::HTTPStatus::NotFound: `/hello/index' not found.>
127.0.0.1 - - [01/Dec/2004:17:23:05 Eastern Standard Time] "GET
/hello/index HTTP/1.1" 200 306
- -> /hello/index
#<WEBrick::HTTPStatus::NotFound: `/favicon.ico' not found.>
[2004-12-01 17:23:07] ERROR `/favicon.ico' not found.
127.0.0.1 - - [01/Dec/2004:17:23:07 Eastern Standard Time] "GET
/favicon.ico HTTP/1.1" 404 281
- -> /favicon.ico
#<WEBrick::HTTPStatus::NotFound: `/hello/index' not found.>
127.0.0.1 - - [01/Dec/2004:17:23:25 Eastern Standard Time] "GET
/hello/index HTTP/1.1" 200 306
- -> /hello/index
#<WEBrick::HTTPStatus::NotFound: `/favicon.ico' not found.>
[2004-12-01 17:23:31] ERROR `/favicon.ico' not found.
127.0.0.1 - - [01/Dec/2004:17:23:31 Eastern Standard Time] "GET


/favicon.ico HTTP/1.1" 404 281
- -> /favicon.ico
 
C

Carl Youngblood

Tobias said:
under windows it seems to be very important to use rubyw.exe and not
ruby.exe for performance. Maybe thats it ?
Question: I've seen this mentioned a few times now. If this is the
case, does the ruby installer for Windows associate .rb files with
ruby.exe or rubyw.exe? It would seem silly to be saying it should be
one way and then have all the default behaviors do it the other way. If
there is no good use for ruby.exe, then we should simply rename
rubyw.exe to ruby.exe.
 
L

Lothar Scholz

Hello Carl,

CY> Question: I've seen this mentioned a few times now. If this is the
CY> case, does the ruby installer for Windows associate .rb files with
CY> ruby.exe or rubyw.exe? It would seem silly to be saying it should be
CY> one way and then have all the default behaviors do it the other way. If
CY> there is no good use for ruby.exe, then we should simply rename
CY> rubyw.exe to ruby.exe.

rubyw.exe is faster if you don't need standart output, because everything
is going to /dev/null.

I believe that most programs are still command line programs that
write something useful to standart output. So ther current
associations are correct.
 
H

Henrik Horneber

Lothar said:
Hello Carl,

CY> Tobias Luetke wrote:



CY> Question: I've seen this mentioned a few times now. If this is the
CY> case, does the ruby installer for Windows associate .rb files with
CY> ruby.exe or rubyw.exe? It would seem silly to be saying it should be
CY> one way and then have all the default behaviors do it the other way. If
CY> there is no good use for ruby.exe, then we should simply rename
CY> rubyw.exe to ruby.exe.

rubyw.exe is faster if you don't need standart output, because everything
is going to /dev/null.

I believe that most programs are still command line programs that
write something useful to standart output. So ther current
associations are correct.

I agree with Lothar.

method_scope is just a simple test script that prints stuff to stdout.
first with original ruby

H:\ruby\Spielwiese>method_scope.rb
bar
A.moo
instance moo

now I renamed rubyw to ruby
H:\ruby\Spielwiese>method_scope.rb


H:\ruby\Spielwiese>


I'd like to see the output. :)

regards,
Henrik
 
C

Carl Youngblood

Lothar said:
rubyw.exe is faster if you don't need standart output, because everything
is going to /dev/null.

I believe that most programs are still command line programs that
write something useful to standart output. So ther current
associations are correct.
Okay. I didn't realize there was this difference. Thanks
 
C

Curt Hibbs

I'm running webrick with ruby.exe without any slowdown problem.
Question: I've seen this mentioned a few times now. If this is the
case, does the ruby installer for Windows associate .rb files with
ruby.exe or rubyw.exe? It would seem silly to be saying it should be
one way and then have all the default behaviors do it the other way. If
there is no good use for ruby.exe, then we should simply rename
rubyw.exe to ruby.exe.

The one-click installer associates *.rb files with ruby.exe and *.rbw files
with rubyw.exe.

Curt
 
N

Nicholas Van Weerdenburg

I see a X: drive in your log. Are you running the ruby and rails files
off of a network drive?

Regards,
Nick

Sarah said:
Lothar said:
Hello Sarah,

ST> Hi David, I'm running PIII/800MHz laptop. Perhaps I did exagerate
a bit,
ST> but not much. It takes at least 3 minutes for the sample page to
come up
ST> and it will take just as long to reload/refresh the same page. Plus,
ST> starting up the "ruby dispatch.servlet -a" takes at least 1 minutes.

ST> I will try what you suggested by updating it to the latest beta.

Do you have the Windows SP2 firewall enabled ? I also got a 20 sec
delay for the first connect on my 2,8Ghz PIV machine (VMWare sandbox)
before i turned the firewall off.

3 minutes is a clear sign that the problem is your envrionment and not
inside ruby/rails.

Below are the log from the console of '%> ruby dispatch.servlet -a'

C:\rails\public>ruby dispatch.servlet -a
dispatch: invalid option: -a
[2004-12-01 17:18:46] INFO WEBrick 1.3.1
[2004-12-01 17:18:46] INFO ruby 1.8.2 (2004-11-06) [i386-mswin32]
[2004-12-01 17:18:46] INFO WEBrick::HTTPServer#start: pid=2620 port=3000
#<WEBrick::HTTPStatus::NotFound: `/favicon.ico' not found.>
[2004-12-01 17:21:18] ERROR `/favicon.ico' not found.
127.0.0.1 - - [01/Dec/2004:17:21:18 Eastern Standard Time] "GET
/favicon.ico HTTP/1.1" 404 281
- -> /favicon.ico
#<WEBrick::HTTPStatus::NotFound: `/hello/index' not found.>
X:/websites/rails/public/../config/environments/shared.rb:1: warning:
already initialized constant ADDITIONAL_LOAD_PATHS
#<NameError: undefined method `database_configurations' for class
`Builder::BlankSlate'>
["x:/apps/ruby/ruby-1.8/lib/ruby/gems/1.8/gems/actionpack-0.9.5.200412010045/lib/action_view/vendor/builder/blankslate.rb:20:in
`un
ef_method'",
"x:/apps/ruby/ruby-1.8/lib/ruby/gems/1.8/gems/actionpack-0.9.5.200412010045/lib/action_view/vendor/builder/blankslate.

b:20:in `hide'",
"x:/apps/ruby/ruby-1.8/lib/ruby/gems/1.8/gems/actionpack-0.9.5.200412010045/lib/action_view/vendor/builder/blanksl

te.rb:48:in `method_added'",
"X:/websites/rails/public/../config/environments/shared.rb:15",
"x:/apps/ruby/ruby-1.8/lib/ruby/site_r
by/1.8/rubygems/loadpath_manager.rb:5:in `require__'",
"x:/apps/ruby/ruby-1.8/lib/ruby/site_ruby/1.8/rubygems/loadpath_manager.rb:5

in `require'",
"X:/websites/rails/public/../config/environments/production.rb:1",
"x:/apps/ruby/ruby-1.8/lib/ruby/site_ruby/1.8/rub
gems/loadpath_manager.rb:5:in `require__'",
"x:/apps/ruby/ruby-1.8/lib/ruby/site_ruby/1.8/rubygems/loadpath_manager.rb:5:in
`requir
'", "X:/websites/rails/public/dispatch.rb:3",
"x:/apps/ruby/ruby-1.8/lib/ruby/gems/1.8/gems/rails-0.8.5.200412010045/lib/webrick_se

ver.rb:122:in `load'",
"x:/apps/ruby/ruby-1.8/lib/ruby/gems/1.8/gems/rails-0.8.5.200412010045/lib/webrick_server.rb:122:in
`handle_
ispatch'",
"x:/apps/ruby/ruby-1.8/lib/ruby/gems/1.8/gems/rails-0.8.5.200412010045/lib/webrick_server.rb:101:in
`handle_mapped'", "x
/apps/ruby/ruby-1.8/lib/ruby/gems/1.8/gems/rails-0.8.5.200412010045/lib/webrick_server.rb:53:in
`do_GET'", "x:/apps/ruby/ruby-1.8/l
b/ruby/1.8/webrick/httpservlet/abstract.rb:35:in `__send__'",
"x:/apps/ruby/ruby-1.8/lib/ruby/1.8/webrick/httpservlet/abstract.rb:3
:in `service'",
"x:/apps/ruby/ruby-1.8/lib/ruby/1.8/webrick/httpserver.rb:97:in
`service'", "x:/apps/ruby/ruby-1.8/lib/ruby/1.8/web
ick/httpserver.rb:58:in `run'",
"x:/apps/ruby/ruby-1.8/lib/ruby/1.8/webrick/server.rb:153:in
`start_thread'", "x:/apps/ruby/ruby-1.
/lib/ruby/1.8/webrick/server.rb:147:in `start'",
"x:/apps/ruby/ruby-1.8/lib/ruby/1.8/webrick/server.rb:147:in
`start_thread'", "x:/
pps/ruby/ruby-1.8/lib/ruby/1.8/webrick/server.rb:97:in `start'",
"x:/apps/ruby/ruby-1.8/lib/ruby/1.8/webrick/server.rb:89:in `each'
, "x:/apps/ruby/ruby-1.8/lib/ruby/1.8/webrick/server.rb:89:in
`start'", "x:/apps/ruby/ruby-1.8/lib/ruby/1.8/webrick/server.rb:79:in
`start'", "x:/apps/ruby/ruby-1.8/lib/ruby/1.8/webrick/server.rb:79:in
`start'", "x:/apps/ruby/ruby-1.8/lib/ruby/gems/1.8/gems/rails
0.8.5.200412010045/lib/webrick_server.rb:37:in `dispatch'",
"dispatch.servlet:45"]
[2004-12-01 17:21:40] ERROR `/hello/index' not found.
127.0.0.1 - - [01/Dec/2004:17:21:30 Eastern Standard Time] "GET
/hello/index HTTP/1.1" 404 281
- -> /hello/index
#<WEBrick::HTTPStatus::NotFound: `/favicon.ico' not found.>
[2004-12-01 17:21:41] ERROR `/favicon.ico' not found.
127.0.0.1 - - [01/Dec/2004:17:21:40 Eastern Standard Time] "GET
/favicon.ico HTTP/1.1" 404 281
- -> /favicon.ico
#<WEBrick::HTTPStatus::NotFound: `/hello/index' not found.>
127.0.0.1 - - [01/Dec/2004:17:22:42 Eastern Standard Time] "GET
/hello/index HTTP/1.1" 200 306
- -> /hello/index
#<WEBrick::HTTPStatus::NotFound: `/favicon.ico' not found.>
[2004-12-01 17:22:48] ERROR `/favicon.ico' not found.
127.0.0.1 - - [01/Dec/2004:17:22:48 Eastern Standard Time] "GET
/favicon.ico HTTP/1.1" 404 281
- -> /favicon.ico
#<WEBrick::HTTPStatus::NotFound: `/hello/index' not found.>
127.0.0.1 - - [01/Dec/2004:17:23:05 Eastern Standard Time] "GET
/hello/index HTTP/1.1" 200 306
- -> /hello/index
#<WEBrick::HTTPStatus::NotFound: `/favicon.ico' not found.>
[2004-12-01 17:23:07] ERROR `/favicon.ico' not found.
127.0.0.1 - - [01/Dec/2004:17:23:07 Eastern Standard Time] "GET
/favicon.ico HTTP/1.1" 404 281
- -> /favicon.ico
#<WEBrick::HTTPStatus::NotFound: `/hello/index' not found.>
127.0.0.1 - - [01/Dec/2004:17:23:25 Eastern Standard Time] "GET
/hello/index HTTP/1.1" 200 306
- -> /hello/index
#<WEBrick::HTTPStatus::NotFound: `/favicon.ico' not found.>
[2004-12-01 17:23:31] ERROR `/favicon.ico' not found.
127.0.0.1 - - [01/Dec/2004:17:23:31 Eastern Standard Time] "GET
/favicon.ico HTTP/1.1" 404 281
- -> /favicon.ico
 
S

Sarah Tanembaum

Nicholas said:
I see a X: drive in your log. Are you running the ruby and rails files
off of a network drive?

Regards,
Nick
Nope! I have a disks and a few partitions. All in one machine.

Regards,
Sarah
 

Ask a Question

Want to reply to this thread or ask your own question?

You'll need to choose a username for the site, which only take a couple of moments. After that, you can post your question and our members will help you out.

Ask a Question

Members online

No members online now.

Forum statistics

Threads
473,744
Messages
2,569,484
Members
44,903
Latest member
orderPeak8CBDGummies

Latest Threads

Top