mysqladmin
Differences
This shows you the differences between two versions of the page.
mysqladmin [2016/12/15 10:53] – [Install from source] admin | mysqladmin [2022/10/29 16:15] (current) – external edit 127.0.0.1 | ||
---|---|---|---|
Line 8: | Line 8: | ||
==== Install from source ==== | ==== Install from source ==== | ||
refer: | refer: | ||
- | * http:// | + | * http:// |
- | * https:// | + | * http:// |
- | * http:// | + | |
Download source: Plsease select Generic Linux (Architecture Independent), | Download source: Plsease select Generic Linux (Architecture Independent), | ||
* newest source: https:// | * newest source: https:// | ||
* version 5.6: https:// | * version 5.6: https:// | ||
- | Below are steps to install MySQL Server: | + | Below are steps to install MySQL Server |
- Step1: Add mysql user:< | - Step1: Add mysql user:< | ||
useradd -r -U mysql -M -d / | useradd -r -U mysql -M -d / | ||
Line 35: | Line 34: | ||
- Step5:chown to mysql:< | - Step5:chown to mysql:< | ||
chown -R mysql.mysql /onec/mysql | chown -R mysql.mysql /onec/mysql | ||
+ | </ | ||
+ | - Step6: copy my.cnf to /etc/my.cnf | ||
+ | - Step7: Init database< | ||
+ | cd /onec/mysql | ||
+ | scripts/ | ||
+ | </ | ||
+ | - Step8: Start Server:< | ||
+ | bin/ | ||
+ | </ | ||
+ | # Next command is optional | ||
+ | cp support-files/ | ||
+ | / | ||
+ | </ | ||
+ | - Step9: Login to Mysql server< | ||
+ | mysql -uroot | ||
+ | </ | ||
+ | - Step10: Reset password root< | ||
+ | mysqladmin password ' | ||
</ | </ | ||
==== Installing MySQL on Microsoft Windows Using a noinstall Zip Archive ==== | ==== Installing MySQL on Microsoft Windows Using a noinstall Zip Archive ==== | ||
Line 52: | Line 69: | ||
bin\mysqld --initialize | bin\mysqld --initialize | ||
bin\mysqld --initialize-insecure | bin\mysqld --initialize-insecure | ||
- | </ | + | </ |
- | A temporary password is generated for root@localhost: | + | </ |
+ | ./ | ||
+ | ./ | ||
</ | </ | ||
- Step5: Start the MySQL server:< | - Step5: Start the MySQL server:< | ||
Line 186: | Line 205: | ||
SHOW CREATE PROCEDURE `sp_gold_update_transaction`; | SHOW CREATE PROCEDURE `sp_gold_update_transaction`; | ||
</ | </ | ||
+ | * change definer to **root@localhost** before import sql from sql dump file | ||
==== Create database from script .sql ==== | ==== Create database from script .sql ==== | ||
commands:< | commands:< | ||
Line 378: | Line 398: | ||
</ | </ | ||
==== Query log of mysql server ==== | ==== Query log of mysql server ==== | ||
- | * [windows]< | + | * [windows] |
[mysqld] | [mysqld] | ||
....... | ....... | ||
Line 451: | Line 471: | ||
===== Tunning Mysql Server ===== | ===== Tunning Mysql Server ===== | ||
Before run script check, we need to run automatic all pages of websites for running all queries in mysql | Before run script check, we need to run automatic all pages of websites for running all queries in mysql | ||
+ | ==== MySQL table limit ==== | ||
+ | https:// | ||
==== Run script check ==== | ==== Run script check ==== | ||
Download script from https:// | Download script from https:// | ||
Line 685: | Line 707: | ||
</ | </ | ||
* step2: Loading this file using:< | * step2: Loading this file using:< | ||
- | mysql -f --default-character-set=utf8 -u username -p backup_mysql < backup.sql | + | mysql -f --default-character-set=utf8 |
</ | </ | ||
==== Use the mysqlhotcopy script ==== | ==== Use the mysqlhotcopy script ==== |
mysqladmin.1481799228.txt.gz · Last modified: 2022/10/29 16:15 (external edit)