views:

110

answers:

1

I'm trying to install a Rails app on a Cygwin Rails + WAMP MySQL setup, but rake trows an error :

Can't connect to local MySQL server through socket '/tmp/mysql.sock' (2)

Of course, it's trying to connect to MySQL trought a Cygwin socket, and since there's no MySQL server running on Cygwin, it fails.

How do I get Rails to connect to WAMP's MySQL (perhaps through TCP/IP instead of a socket) ?

A: 

Adding host:127.0.0.1 to database.yml, forcing it to use TCP instead of a socket solved the problem.

Andrei