# Rails looking for development db in production

**URL:** <https://www.ruby-forum.com/t/rails-looking-for-development-db-in-production/150025>\
**Category:** Rails\
**Created:** [October 2, 2008, 4:43pm UTC](https://www.ruby-forum.com/t/rails-looking-for-development-db-in-production/150025 "2008-10-02T16:43:41Z")\
**Posts on this page:** 5\
**Page:** 1

<div class="post-metadata">

**Author:** ![Schalk\_N](https://www.ruby-forum.com/letter_avatar_proxy/v4/letter/s/b782af/32.png) [@Schalk\_N](https://www.ruby-forum.com/u/Schalk_N)\
**Post date:** [October 2, 2008, 4:43pm UTC](https://www.ruby-forum.com/t/rails-looking-for-development-db-in-production/150025/1 "2008-10-02T16:43:41Z")

</div>

Hi there everyone,

On my production server I start the mongrel server as follows:

mongrel\_rails start -e production -a 127.0.0.1 -p 3001 -d

However when going to the domain I get the following error:

#42000Unknown database ‘satechevents\_development’

Why is rails looking for the development database in production mode.

Thanks for the help,  
Schalk

---

<div class="post-metadata">

**Author:** ![Schalk\_N](https://www.ruby-forum.com/letter_avatar_proxy/v4/letter/s/b782af/32.png) [@Schalk\_N](https://www.ruby-forum.com/u/Schalk_N)\
**Post date:** [October 2, 2008, 6:20pm UTC](https://www.ruby-forum.com/t/rails-looking-for-development-db-in-production/150025/2 "2008-10-02T18:20:33Z")

</div>

I’ve seen an issue before where non-root mysql accounts just don’t  
work. Even with full GRANT on the database in question. I can’t  
explain it. But for troubleshooting, try your root account in your  
production database.yml and retry. Secondly, in the same manner,  
database migrations sometimes give the same problem AFTER you get your  
app working. Lastly, you can try to give the production connection the  
path to your mysql.sock socket file. (find / -name mysql.sock) I’ve  
seen that cause issues as well.

Good luck.  
H

---

<div class="post-metadata">

**Author:** ![Schalk\_N](https://www.ruby-forum.com/letter_avatar_proxy/v4/letter/s/b782af/32.png) [@Schalk\_N](https://www.ruby-forum.com/u/Schalk_N)\
**Post date:** [October 3, 2008, 9:55am UTC](https://www.ruby-forum.com/t/rails-looking-for-development-db-in-production/150025/3 "2008-10-03T09:55:26Z")

</div>

Thanks Fred,

I will look into this. How can I ensure that all instances of mongrel is  
stopped?

Schalk

---

<div class="post-metadata">

**Author:** ![Schalk\_N](https://www.ruby-forum.com/letter_avatar_proxy/v4/letter/s/b782af/32.png) [@Schalk\_N](https://www.ruby-forum.com/u/Schalk_N)\
**Post date:** [October 3, 2008, 10:19am UTC](https://www.ruby-forum.com/t/rails-looking-for-development-db-in-production/150025/4 "2008-10-03T10:19:29Z")

</div>

ps -ef | grep ‘mongrel’

On Oct 2, 4:01 pm, Frederick C. [removed\_email\_address@domain.invalid](mailto:removed_email_address@domain.invalid)

---

<div class="post-metadata">

**Author:** ![Schalk\_N](https://www.ruby-forum.com/letter_avatar_proxy/v4/letter/s/b782af/32.png) [@Schalk\_N](https://www.ruby-forum.com/u/Schalk_N)\
**Post date:** [October 3, 2008, 10:04am UTC](https://www.ruby-forum.com/t/rails-looking-for-development-db-in-production/150025/5 "2008-10-03T10:04:50Z")

</div>

On 2 Oct 2008, at 15:51, Schalk N. wrote:

> Thanks Fred,
> 
> I will look into this. How can I ensure that all instances of  
> mongrel is  
> stopped?

look at the output of ps ?

Fred
