Sun N1 Grid Engine 6.1 Installation Guide

ProcedureHow to Install MySQL Database on UNIX Systems

  1. Download the appropriate MySQL software for your system from http://www.mysql.com.

    The standard installation directory for UNIX systems is /usr/local/mysql. If you install the software into a different directory, you have to change the settings for the scripts provided in the package.


    Note –

    ARCo is a Java web-based application and needs the JavaTM DataBase connectivity (JDBCTM) driver for converting JDBC calls into the network protocol used by the MySQL database. You can download the JDBC driver from http://www.mysql.com/products/connector.


  2. Create a symbolic link from the installation directory to mysql.


    # ln -s $installation_directory/mysql-standard-5.0.26-solaris10-i386 mysql

    The mysql directory contains several files and subdirectories:

    • The bin subdirectory contains client programs and the server.

      • The MySQL server and server startup scripts:

        • mysqld is the MySQL server.

        • mysqld_safe, mysql.server, and mysqld_multi are server startup scripts.

        • mysql_install_db initializes the data directory and the initial databases.

        • mysqlmanager is the MySQL instance manager.

      • Client programs that access the server:

        • mysql is a command-line client for executing SQL statements interactively or in batch mode.

        • mysqladmin is an administrative client.

        • mysqlcheck performs table maintenance operations.

        • mysqldump and mysqlhotcopy make database backups.

        • mysqlimport imports data files.

        • mysqlshow displays information about databases and tables.

      • Utility programs that operate independently of the server:

        • myisamchk performs table maintenance operations.

        • myisampack produces compressed, read-only tables.

        • mysqlbinlog is a tool for processing binary log files.

        • perror displays the meaning of error codes.

    • The scripts subdirectory contains the mysql_install_db script used to initialize the mysql database containing the grant tables that store the server access permissions.

  3. Add a login user and group for mysqld.


    # groupadd mysql
    # useradd -g mysql mysql
  4. Change the ownership of program binaries to root and ownership of the data directory to the user that you use to run mysqld.


    # chown -R root .
    # chown -R mysql data
    # chgrp -R mysql .
  5. Create the MySQL grant tables.


    # scripts/mysql_install_db --user=mysql
  6. Start the MySQL server.


    # bin/mysqld_safe --user=mysql &
  7. Assign the root password.


    # ./bin/mysqladmin -u root password 'new-password'
    # ./bin/mysqladmin -u root -h ${hostname} password 'new-password'
MySQL Installation Tips