Hello,
Here's a tip for connecting galaxy to mysql on localhost (if it didn't work for you out of the box):
## Get a clean copy of galaxy $ hg clone http://www.bx.psu.edu/hg/galaxy galaxy
## Create dedicated MySQL database for galaxy, ## with user 'galaxy' and password '12345' $ mysql -u root -p password: mysql> create database galaxy ; mysql> use galaxy ; mysql> grant all on galaxy.* to 'galaxy'@'localhost' identified by '12345';
## Setup Galaxy $ sh setup.sh
## Change universe_wsgi.ini, to use the new database database_connection = mysql://galaxy:12345@localhost/galaxy
## Run Galaxy $ sh run.sh
-----------------
But here's the catch: On a standard debian system, mysql puts the unix socket file in /var/run/mysqld/mysqld.sock
However, SqlAlchemy assumes the socket is in /tmp/mysql.sock.
So when I run galaxy, I get the following exception: OperationalError: (OperationalError) (2002, "Can't connect to local MySQL server through socket '/tmp/mysql.sock' (2)") None None
Two possible solutions for that:
1. Change the socket file in /etc/mysql/my.cnf (not recommended) or 2. Add the following incantation to the SQLAlchemy string in universe_wsgi.ini:
database_connection = mysql://galaxy:12345@localhost/galaxy?unix_socket=/var/run/mysqld/mysqld.sock
With this change, Galaxy runs fine with mysql on localhost.
-Gordon.
galaxy-dev@lists.galaxyproject.org