Install mysql compressed package records

Source: Internet
Author: User

Install mysql compressed package record install mysql record [root @ eegooserver3 ~] # Groupadd mysql [root @ eegooserver3 ~] # Useradd-g mysql [root @ eegooserver3 ~] # Cd/opt [root @ eegooserver3 opt] # tar zxvf mysql-5.1.63-linux-x86_64-glibc23.tar.gz [root @ eegooserver3 opt] # mv/opt/mysql-5.1.63-linux-x86_64-glibc23/usr/local/mysql [root @ eegooserver3 opt] # cd /usr/local/mysql/[root @ eegooserver3 mysql] # lltotal 76drwxr-xr-x. 2 7155 wheel 4096 Apr 16 bin-rw-r --. 1 7155 wheel 17987 Apr 16 COPYINGdrwxr-x ---. 4 7155 wheel 4096 Apr 16 datadrwxr-xr- X. 2 7155 wheel 4096 Apr 16 docsdrwxr-xr-x. 2 7155 wheel 4096 Apr 16 include-rw-r --. 1 7155 wheel 7605 Apr 16 INSTALL-BINARYdrwxr-xr-x. 3 7155 wheel 4096 Apr 16 libdrwxr-xr-x. 4 7155 wheel 4096 Apr 16 mandrwxr-xr-x. 10 7155 wheel 4096 Apr 16 mysql-test-rw-r --. 1 7155 wheel 2552 Apr 16 READMEdrwxr-xr-x. 2 7155 wheel 4096 Apr 16 scriptsdrwxr-xr-x. 27 7155 wheel 4096 Apr 16 sharedrwxr-xr-x. 5 7155 wheel 4096 Apr 16 SQL-benchdrwxr-xr-x. 2 7155 wheel 4096 Apr 16 support-files [root @ eegooserver3 mysql] # chown-R mysql. [root @ eegooserver3 mysql] # chgrp-R mysql. [root @ eegooserver3 mysql] # cp support-files/my-huge.cnf/etc/my. cnf [root @ eegooserver3 mysql] # scripts/mysql_install_db -- user = mysqlInstalling MySQL system tables... OK Filling help tables... OK To start mysqld at boot time you have to copysupport-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 eegooserver3 password 'new-password' Alternatively you can run :. /bin/mysql_secure_installation which will also give you the option of removing the testdatabases and anonymous user created by default. this isstronugly recommended for production servers. see the ma Nual for more instructions. you can start the MySQL daemon with: cd .;. /bin/mysqld_safe & You can test the MySQL daemon with mysql-test-run.plcd. /mysql-test; perl mysql-test-run.pl Please report any problems with. /bin/mysqlbug script! [Root @ eegooserver3 mysql] # chown-R root. [root @ eegooserver3 mysql] # chown-R mysql data [root @ eegooserver3 mysql] # ln-s/usr/local/mysql/bin/mysqld_safe/usr/local/bin [root @ eegooserver3 mysql] # ln-s/usr/local/mysql/bin/mysql/usr/local/bin [root @ eegooserver3 mysql] # ln-s/usr/local/mysql /bin/mysqldump/usr/local/bin [root @ eegooserver3 mysql] # bin/mysqld_safe -- user = mysql & [1] 5425 [root @ eegooserver3 mysql] #120827 22:43:45 mysqld_safe Logging to '/usr/local/mysql/data/eegooserver3.err '. 120827 22:43:45 mysqld_safe Starting mysqld daemon with databases from/usr/local/mysql/data ^ C [root @ eegooserver3 mysql] #/usr/local/mysql/bin/mysqladmin-u root password 123456 [root @ eegooserver3 mysql] # mysql-u root-pEnter password: 123456 Welcome to the MySQL monitor. commands end with; or \ g. your MySQL connection id is 2 Server version: 5.1.63-log MySQL Community Server (GPL) Copyright (c) 2000,201 1, Oracle and/or its affiliates. all rights reserved. oracle is a registered trademark of Oracle Corporation and/or itsaffiliates. other names may be trademarks of their respectiveowners. type 'help; 'or' \ H' for help. type '\ C' to clear the current input statement. mysql> select user, host, password from mysql. user; + ------ + -------------- + ---------- + | user | host | password | + ------ + -------------- + ---------- + | root | localhost | root | eegooserver3 | root | 127.0.0.1 | | localhost | eegooserver3 | + ------ + -------------- + ---------- + 5 rows in set (0.00 sec) mysql> grant all on *. * to root @ '%' identified by '000000'; Query OK, 0 rows affected (123456 sec) mysql> flush privileges; Query OK, 0 rows affected (0.00 sec) mysql> exit; Bye [root @ eegooserver3 mysql] # cp support-files/mysql. server/etc/rc. d/init. d/mysqld [root @ eegooserver3 mysql] # chmod 700/etc/init. d/mysqld [root @ eegooserver3 mysql] # chkconfig -- add mysqld [root @ eegooserver3 mysql] # chkconfig -- level 345 mysqld on [root @ eegooserver3 mysql] # chkconfig -- list mysqld

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.