Since server change, rails application won't start


#1

Hello everyone,

So, I had a rails application that was working really fine since really long, when I was hosted on the achilles server. The application is frozen.

Then, DH decided to move me to a new server, called tirane. Since that time, my rails application doesn’t work. Then later on, they decided to move me to bugsy (sic), and it still doesn’t work.

I don’t really know what the problem is. From the production.log, I get messages like this, from the start of the application:

has_many_polymorphs: Rails environment detected
error preloading Tag: #<NoMethodError: undefined method `[]’ for #Enumerable::Enumerator:0x7f803a600c40>

Processing TotozController#index (for 129.129.128.182 at 2009-10-05 04:36:30) [GET]
Session ID: aee4c365f803ddf9651384f320e592c3
Parameters: {“action”=>“index”, “controller”=>“totoz”}

LoadError (Expected /home/loico/totoz/releases/20080104115117/app/models/totoz.rb to define Totoz):
/home/loico/totoz/releases/20080104115117/vendor/rails/activerecord/lib/…/…/activesupport/lib/active_support/dependencies.rb:249:in load_missing_constant ' /home/loico/totoz/releases/20080104115117/vendor/rails/activerecord/lib/../../activesupport/lib/active_support/dependencies.rb:452:inconst_missing’
/home/loico/totoz/releases/20080104115117/vendor/rails/activerecord/lib/…/…/activesupport/lib/active_support/dependencies.rb:464:in const_missing' /home/loico/totoz/releases/20080104115117/vendor/rails/activerecord/lib/../../activesupport/lib/active_support/dependencies.rb:260:inload_missing_constant

/home/loico/totoz/releases/20080104115117/vendor/rails/activerecord/lib/…/…/activesupport/lib/active_support/dependencies.rb:468:in const_missing' /home/loico/totoz/releases/20080104115117/app/controllers/application.rb:8:ininfo’
/home/loico/totoz/releases/20080104115117/app/controllers/totoz_controller.rb:24:in list' /home/loico/totoz/releases/20080104115117/app/controllers/totoz_controller.rb:6:inindex’
/home/loico/totoz/releases/20080104115117/vendor/rails/actionpack/lib/action_controller/base.rb:1101:in send' /home/loico/totoz/releases/20080104115117/vendor/rails/actionpack/lib/action_controller/base.rb:1101:inperform_action_without_filters’
/home/loico/totoz/releases/20080104115117/vendor/rails/actionpack/lib/action_controller/filters.rb:696:in call_filters' /home/loico/totoz/releases/20080104115117/vendor/rails/actionpack/lib/action_controller/filters.rb:688:inperform_action_without_benchmark’
/home/loico/totoz/releases/20080104115117/vendor/rails/actionpack/lib/action_controller/benchmarking.rb:66:in perform_action_without_rescue' /usr/lib/ruby/1.8/benchmark.rb:293:inmeasure’
/home/loico/totoz/releases/20080104115117/vendor/rails/actionpack/lib/action_controller/benchmarking.rb:66:in perform_action_without_rescue' /home/loico/totoz/releases/20080104115117/vendor/rails/actionpack/lib/action_controller/rescue.rb:83:inperform_action’
/home/loico/totoz/releases/20080104115117/vendor/rails/actionpack/lib/action_controller/base.rb:435:in send' /home/loico/totoz/releases/20080104115117/vendor/rails/actionpack/lib/action_controller/base.rb:435:inprocess_without_filters’
/home/loico/totoz/releases/20080104115117/vendor/rails/actionpack/lib/action_controller/filters.rb:684:in process_without_session_management_support' /home/loico/totoz/releases/20080104115117/vendor/rails/actionpack/lib/action_controller/session_management.rb:114:inprocess’
/home/loico/totoz/releases/20080104115117/vendor/rails/actionpack/lib/action_controller/base.rb:334:in process' /home/loico/totoz/releases/20080104115117/vendor/rails/railties/lib/dispatcher.rb:41:indispatch’
/home/loico/totoz/releases/20080104115117/vendor/rails/railties/lib/fcgi_handler.rb:168:in process_request' /home/loico/totoz/releases/20080104115117/vendor/rails/railties/lib/fcgi_handler.rb:143:inprocess_each_request!’
/home/loico/totoz/releases/20080104115117/vendor/rails/railties/lib/fcgi_handler.rb:109:in with_signal_handler' /home/loico/totoz/releases/20080104115117/vendor/rails/railties/lib/fcgi_handler.rb:142:inprocess_each_request!’
/usr/lib/ruby/1.8/fcgi.rb:612:in each_cgi' /usr/lib/ruby/1.8/fcgi.rb:609:ineach’
/usr/lib/ruby/1.8/fcgi.rb:609:in each_cgi' /home/loico/totoz/releases/20080104115117/vendor/rails/railties/lib/fcgi_handler.rb:141:inprocess_each_request!’
/home/loico/totoz/releases/20080104115117/vendor/rails/railties/lib/fcgi_handler.rb:55:in process!' /home/loico/totoz/releases/20080104115117/vendor/rails/railties/lib/fcgi_handler.rb:25:inprocess!'
dispatch.fcgi:26

Any tips from anyone ?

Cheers.


#2

I have similar problem. All my paths are fine. Rails appears to start after a “touch tmp/restart.txt”, as usual, but nothing gets written to logs/production.html (no clue why not). Nothing in http logs file either. Yet, the site “appears” to work, and much faster than previously.

Dreamhost put me on the server whose name is: No clue. Dreamhost staff did not tell me where my site got moved to. A “hostname” indicates edendale.

Gordon Erlebacher
School of Computational Science
Florida State University
Tallahassee, Florida


#3

I have more information that might help those from Dreamhost, who do not appear to be listening :frowning:

On the new server (I do not have the name; it was not given), my rails application appears to be different than the one that is running. In other words, nothing I do affect the one running, even if I remove a controller and restart the rails program. This implies that it is still running from the old location and that the Dreamhost guys did not stop it and retart it, or something like that. It explains why production.log remains empty. The log is being written out somewhere else.

The problem: I have no way to figure out where the old files are (probably on the old server).

Gordon

Gordon Erlebacher
School of Computational Science
Florida State University
Tallahassee, Florida


#4

Dreamhost tells me that they changed my server, yet they never told me the new name was belmopan. So I kept logging into edendale, and everything “seemed” to work. Eventually, I changed in my aliases (to help me log in remotely), edendale to belmopan everywhere. I figured out the name of the server by going to the web panel. They never told me to do that!!! Imagine how many people got confused?

So as I said, my rails was operating from a different server: the new server. So the point is: Dreamhost never disabled my account on the old server: both accounts are still functional.

I wonder if anybody is listening.

A dissatisfied customer,

Gordon

Gordon Erlebacher
School of Computational Science
Florida State University
Tallahassee, Florida


#5

[quote]So I kept logging into edendale, and everything “seemed” to work. Eventually, I changed in my aliases (to help me log in remotely), edendale to belmopan everywhere.

So as I said, my rails was operating from a different server: the new server. So the point is: Dreamhost never disabled my account on the old server: both accounts are still functional.

I wonder if anybody is listening.[/quote]

Sorry to hear you had trouble. I’m curious - is there something in particular that DreamHost has published that tells you to login using the server hostname instead of your domain? It is for this very reason with server moves and IP address changes that they usually are very good at pointing out to use your domain instead of their server name.

As was pointed in in the forum before, when a server move is done the old server is not flushed for a while in case something went wrong with the move.

Customer since 2000 :cool: openvein.org


#6

Thank for the reply. Problem is only partially dealt with with your solution. I replaced erlebach@belmopan.dreamhost.com by erlebach@gorerle.com and I could do a remote login.

However, my rails account is on a subdomain: sci-prog09.goerle.com, with user name erlebach_sciprog. The following works:

erlebach_sciprog@belmopan.dreamhost.com

However, your recommended approach does not work:

erlebach_sciprog@sci-prog09.gorerle.com

and nor does

erlebach_sciprog@gorerle.com

What is your recommended solution, if I am not to hardcode the server name? Thanks.

Gordon

Gordon Erlebacher
School of Computational Science
Florida State University
Tallahassee, Florida


#7

[quote]However, my rails account is on a subdomain: sci-prog09.goerle.com, with user name erlebach_sciprog. The following works:

erlebach_sciprog@belmopan.dreamhost.com

However, your recommended approach does not work:

erlebach_sciprog@sci-prog09.gorerle.com

and nor does

erlebach_sciprog@gorerle.com

What is your recommended solution, if I am not to hardcode the server name? Thanks.[/quote]
Well since belmopan.dreamhost.com resolves to a different IP than gorerle.com/sci-prog09.gorerle.com, it would appear then that your users have been separated somehow. I’d contact Support. Are you getting different banners when you login?

Customer since 2000 :cool: openvein.org