MCSR_logo.jpg (56K)
Home My MCSR Supercomputers Software Research Education
Login
Quick Links:

FAQs
Minicamp
Chemistry
insideHPC Blog
Current Jobs
Job History
Mathematica
Training
News
Contact Us

Getting Started with MySQL on the UM Research Server

The MySQL relational database management system is installed on willow, for the instructional and research use of University of Mississippi faculty and students.

Frequently Asked Questions about MySQL on UM Research Server

  1. What version of MySQL is installed on willow, and where is it located?
  2. What environment variable settings are necessary to bring up a MySQL session on willow?
  3. How can I launch a MySQL session?
  4. How can I exit MySQL?
  5. How do I select a database for use?
  6. How can I see what tables are available within my database, and/or what columns are defined for a particular table within the database?
  7. How can I use MySQL in batch mode, and why would I want to?
  8. How can I get a MySQL account on willow?
  9. Where can I learn more about how to use MySQL?
  10. Is there a simple, read-only database available on willow that I can let my students query for instructional purposes?

Frequently Asked Questions and Answers about MySQL on the UM Research Server

  1. What version of MySQL is installed on willow, and where is it located?
    MySQL 4.0.11, located in /usr/local/mysql (which is a symbolic link pointing to /usr/local/mysql-standard-4.0.11-gamma-sun-solaris2.8-sparc)

  1. What environment variable settings are necessary for me to run a MySQL command-line session?
    If you want to launch a MySQL session from your current directory, you must either:

    • Include the full pathname when running the MySQL program:
      > /usr/local/mysql/bin/mysql
      or

    • Ensure that your PATH environment variable includes the directory: /usr/local/mysql/bin
      For more information on setting environment variables in general, and the PATH variable in particular, see UNIXhelp for Users: Managing your Environment.

    back to top

  1. How can I launch a MySQL session?
    > mysql -u <your_mysql_account_id> -p
    Substituting your actual MySQL account id for <your_mysql_account_id>.
    NOTE
    : Your MySQL account id and password are separate account from your Unix account that you use to login to willow.
    For example, if you user id is "rocky" and your password is "racoon1", and your PATH environment variable is set as described above, you would start MySQL as follows:
    > mysql -u rocky -p
    Enter password: racoon1
    (your password will not show up when typed)
    Welcome to the MySQL monitor. Commands end with ; or \g.
    Your MySQL connection id is 3 to server version: 4.0.11

    Type 'help;' or '\h' for help. Type '\c' to clear the buffer

    mysql>

    If you do not know the class MySQL account name and password, see your instructor.
    back to top

  2. How can I exit MySQL?

    You can disconnect any time by typing QUIT at the mysql> prompt:

    mysql> QUIT
    Bye

    You can also disconnect by pressing Control-D.

    back to top

  3. How do I select a database for use?
    You will likely be granted use for only one database on willow. Before you can query or manipulate any tables within your database, you must select it. If, for instance, your database was called instruct, you would select it for use as follows:

    mysql> USE instruct;
    Database changed

    back to top
  4. How can I see what tables are available within my database, and/or what columns are defined for a particular table within the database?
    Once you have selected your database for use:

    mysql> show tables;
    mysql> describe <tablename>;

    For more information, see the MySQL Tutorial.

    back to top
  5. How can I use MySQL in batch mode, and why would I want to?
    See the MySQL Tutorial: Using mysql in Batch Mode

    back to top
  1. How can I get a MySQL account on willow?
    UM Instructors may request class accounts by emailing their electronic class rolls to assist@olemiss.edu. For individual users who already have willow accounts, MySQL account requests will be considered on a case-by-case basis, and should also be made to assist@olemiss.edu.

    back to top

  2. Where can I learn more about how to use MySQL?
    In general, see the MySQL Reference Manual. In particular, see the MySQL Tutorial. Also, from a MySQL session:

    mysql> help;

    back to top

  3. Is there a simple, read-only database available on willow that I can let my students query for instructional purposes?
    Yes. The EMP employee database is available in MySQL database instruct on willow. Email assist@olemiss.edu to negotiate read access for your class.

  4. back to top



Last Modified:June 08, 2007 10:31:53.   Copyright © 1997-2012 The Mississippi Center for Supercomputing Research. All Rights Reserved.   The University of Mississippi
Valid RSS