Installing & Configuring MySQL

If you were careful, you installed MySQL during the Linux installation process. Otherwise, you'll have to grab MySQL-3.23.55-1.i386.rpm and install it manually. There is full documentation of the process at http://www.mysql.com/doc/en/Linux-RPM.html. To do that:

  1. Put MySQL-3.23.55-1.i386.rpm into /usr/local, and cd to there.
  2. Switch to superuser mode.
  3. rpm -i MySQL-3.23.55-1.i386.rpm.

Okay, now you have to enable SQL. Full documentatin of this process is at http://www.mysql.com/doc/en/Post-installation.html, but here are the highlights:

  1. shell> cd mysql_installation_directory
  2. shell> ./scripts/mysql_install_db
  3. shell> ./bin/safe_mysqld --user=mysql &

This creates the mysql database which will hold all database privileges, the test database which you can use to test MySQL, and also privilege entries for the user that run mysql_install_db and a root user (without any passwords). This also starts the mysqld server.

# Verify that you can shut down the server:

shell> BINDIR/mysqladmin -u root shutdown

# Verify that you can restart the server. Do this using safe_mysqld or by invoking mysqld directly. For example:

shell> BINDIR/safe_mysqld --log &

If safe_mysqld fails, try running it from the MySQL installation directory (if you are not already there).

Full documentation of SQL can be found at http://www.mysql.com/doc/en/index.html.