Notes on installing MySQL5 in Solaris

Source: Internet
Author: User

The installation of MySQL5 In the Solaris operating system is based on the official MySQL5.1 Reference Manual section 2.7 "Install MySQL in other Unix-like systems" steps, and the official information is reliable, sort it out for easy reference.

Unix:
$ Uname-
SunOS fs-cluster1 5.8 Generic_108528-13 sun4u iSCSI SUNW, Sun-Fire-280R

MySQL:
Mysql-5.0.45-solaris8-sparc-64bit.tar.gz

1. Add a logon user and group for mysqld:

# Groupadd mysql

# Useradd-d/opt/mysql-g mysql-m mysql

2. Select a directory where you want to unbind the package and go to the directory. In the following example, we will release the package under "/usr/local:

# Cd/usr/local

3. The installation directory will be created for the Unpack distribution edition. Then generate a symbolic link to the directory:

# Gunzip </opt/mysql-5.0.45-solaris8-sparc-64bit.tar.gz | tar-xvf-

# Ln-s mysql-5.0.45-solaris8-sparc-64bit mysql

4. Go to the installation directory:

# Cd mysql

You will find several files and subdirectories in the mysql directory. The most important for installation is the "bin" and "scripts" subdirectories.

· Bin
This directory contains the client program and server. You should add the full PATH of this directory to the path environment variable so that shell can find the MySQL program correctly.

· Scripts
This directory contains the mysql_install_db script, which is used to initialize the mysql database authorization table, where server access is allowed.

5. If MySQL has not been installed, you must create a MySQL authorization table:

# Scripts/mysql_install_db -- user = mysql
Installing MySQL system tables...
OK
Filling help tables...
OK

To start mysqld at boot time you have to copy
Support-files/mysql. server to the right place for your system

Please remember to set a password for the MySQL root USER!
To do so, start the server, then issue the following commands:
./Bin/mysqladmin-u root password 'new-password'
./Bin/mysqladmin-u root-h fs-cluster1 password 'new-password'
See the manual for more instructions.
You can start the MySQL daemon:
Cd ..;./bin/mysqld_safe &

You can test the MySQL daemon with mysql-test-run.pl
Cd mysql-test; perl mysql-test-run.pl

Please report any problems with the./bin/mysqlbug script!

The latest information about MySQL is available on the web
Http://www.mysql.com
Support MySQL by buying support/licenses at http://shop.mysql.com
#

If you use root to run the command, you should use the -- user option. The option value should be the same as the login account you created for the running server in the first step. If you use this user to log on to run the command, you can omit the -- user option.

  • 1
  • 2
  • Next Page

Related Article

Contact Us

The content source of this page is from Internet, which doesn't represent Alibaba Cloud's opinion; products and services mentioned on that page don't have any relationship with Alibaba Cloud. If the content of the page makes you feel confusing, please write us an email, we will handle the problem within 5 days after receiving your email.

If you find any instances of plagiarism from the community, please send an email to: info-contact@alibabacloud.com and provide relevant evidence. A staff member will contact you within 5 working days.

A Free Trial That Lets You Build Big!

Start building with 50+ products and up to 12 months usage for Elastic Compute Service

  • Sales Support

    1 on 1 presale consultation

  • After-Sales Support

    24/7 Technical Support 6 Free Tickets per Quarter Faster Response

  • Alibaba Cloud offers highly flexible support services tailored to meet your exact needs.