Are you sure the rubies are identical machine-to-machine? I hear that the
Ubuntu binaries are pretty terrible and that compiling ruby is the best bet
(preferably via RVM).

This might have something to do with garbage collection - many
hard-to-diagnose performance issues do. Are you dealing with a ton of Ruby
objects whereby the garbage collector might be running mid-action and
wreaking havoc?

Still though, that is an enormous difference. Are you able to share the code
for that particular action?


On Thu, Apr 28, 2011 at 4:11 PM, Guyren Howe <[email protected]> wrote:

> This has me bamboozled. Check it. This is a typical report running on an
> Ubuntu server on slicehost:
>
> Completed 200 OK in 274704ms (Views: 6039.7ms | ActiveRecord: 931.5ms)
>
> Here is the same report running on my iMac:
>
> Completed 200 OK in 4543ms (Views: 2014.2ms | ActiveRecord: 406.8ms)
>
> And I mean it’s the *same* code. Fresh git checkout. Same version of Rails.
> Same version of Postgres and pg gem. Same data.
>
> Sure, the SliceHost server is slower (it’s a 512MB slice vs a 12GB 3.2GHz
> iMac), but it’s not *that* much slower. And it’s not memory bound, either
> (checked with top while it was running). The cpu is pegged at 100% the
> entire time.
>
> The log is not terribly helpful. The slowest SQL operation is about half a
> second. And it’s not like it’s amazingly long, either, so it’s not stuck in
> some loop. And again: same code as runs in 4 seconds on my iMac.
>
> --
> SD Ruby mailing list
> [email protected]
> http://groups.google.com/group/sdruby
>

-- 
SD Ruby mailing list
[email protected]
http://groups.google.com/group/sdruby

Reply via email to