# Change\_table is not working on production server

**URL:** <https://www.ruby-forum.com/t/change-table-is-not-working-on-production-server/148928>\
**Category:** Rails\
**Created:** [September 18, 2008, 12:43pm UTC](https://www.ruby-forum.com/t/change-table-is-not-working-on-production-server/148928 "2008-09-18T12:43:13Z")\
**Posts on this page:** 3\
**Page:** 1

<div class="post-metadata">

**Author:** ![fipa](https://www.ruby-forum.com/letter_avatar_proxy/v4/letter/f/9e8a1a/32.png) [@fipa](https://www.ruby-forum.com/u/fipa)\
**Post date:** [September 18, 2008, 12:43pm UTC](https://www.ruby-forum.com/t/change-table-is-not-working-on-production-server/148928/1 "2008-09-18T12:43:13Z")

</div>

Hi,

I have added to my migration a change\_table action. It works fine on my  
local dev machine, but on the production server the migration does not  
happen although the schema.rb file gets correctly updated.

I am running Rails 2.1.1

---

<div class="post-metadata">

**Author:** ![fipa](https://www.ruby-forum.com/letter_avatar_proxy/v4/letter/f/9e8a1a/32.png) [@fipa](https://www.ruby-forum.com/u/fipa)\
**Post date:** [September 18, 2008, 5:21pm UTC](https://www.ruby-forum.com/t/change-table-is-not-working-on-production-server/148928/2 "2008-09-18T17:21:34Z")

</div>

Thank you blasterpal,

I will have a look at your options.

---

<div class="post-metadata">

**Author:** ![fipa](https://www.ruby-forum.com/letter_avatar_proxy/v4/letter/f/9e8a1a/32.png) [@fipa](https://www.ruby-forum.com/u/fipa)\
**Post date:** [September 18, 2008, 3:08pm UTC](https://www.ruby-forum.com/t/change-table-is-not-working-on-production-server/148928/3 "2008-09-18T15:08:52Z")

</div>

To debug this I would:

1. verify schema versions match on dev compared to prod: “select \*  
from schema\_migrations;”
2. turn up debug on prod logging: in evironment.rb uncomment this  
line: “# config.log\_level = :debug” and tail -f log/\* when running  
migrations. see if it is even doing what you think it is doing.
3. I’ve found in Rails 2 this statement causes issues when I migrate  
on non-development environments. And I sometimes comment it before I  
do migrations:  
environments/production.rb : “config.cache\_classes = true”

I hope this helps.  
H
