Skip to content
Chris edited this page Apr 9, 2012 · 5 revisions

MySQL

sudo aptitude -y install mysql mysql-server libmysqlclient16-dev libmysqlclient16
mysql_secure_installation

Note that you will be prompted to enter a password for the mysql root user, which will be needed to access the database using the mysql client during later installations.

Add a new user just for the rails app and grant it all privileges on the snort database

mysql -u root -p
create user 'osprotect'@'%' IDENTIFIED BY 'CHANGE_ME';
grant all on snort.* to 'osprotect' identified by 'CHANGE_ME';
flush privileges;

To find the unix socket (usually it's /var/run/mysqld/mysqld.sock), or make other configuration changes:

sudo nano /etc/mysql/my.cnf

The value for socket is used in the rails app config/database.yml file to connect to MySQL.