欢迎您访问程序员文章站本站旨在为大家提供分享程序员计算机编程知识!
您现在的位置是: 首页  >  数据库

MySQL实例管理器识别的命令_MySQL

程序员文章站 2024-01-22 17:56:16
...
  一旦你已经为MySQL实例管理器设置了一个密码文件并且IM正在运行,你可以连接它。你可以使用mysql客户端工具通过标准MySQL API来连接。以下是MySQL实例管理器目前可以接收的命令的清单和例子。

?START INSTANCE

  该命令将试图启动一个实例:

mysql> START INSTANCE mysqld4;
Query OK, 0 rows affected (0,00 sec)
?STOP INSTANCE

  将试图停止一个实例:

mysql> STOP INSTANCE mysqld4;
Query OK, 0 rows affected (0,00 sec)
?SHOW INSTANCES

  显示所有载入的实例名:

mysql> show instances;
+---------------+---------+
| instance_name | status |
+---------------+---------+
| mysqld3    | offline |
| mysqld4    | online |
| mysqld2    | offline |
+---------------+---------+
3 rows in set (0,04 sec)
?SHOW INSTANCE STATUS

  显示选定的实例的状态和版本信息:

mysql> SHOW INSTANCE STATUS mysqld3;
+---------------+--------+---------+
| instance_name | status | version |
+---------------+--------+---------+
| mysqld3    | online | unknown |
+---------------+--------+---------+
1 row in set (0.00 sec)
?SHOW INSTANCE OPTIONS

  显示实例使用的选项:

mysql> SHOW INSTANCE OPTIONS mysqld3;
+-------------+--------------------------------------------------+
|option_name | value                      |
+-------------+--------------------------------------------------+
|instance_name| mysqld3                     |
|mysqld-path | /home/cps/mysql/trees/mysql-4.1/sql/mysqld    |
|port     | 3309                       |
|socket    | /tmp/mysql.sock3                 |
|pid-file   | hostname.pid3                  |
|datadir   | /home/cps/mysql_data/data_dir1/         |
|language   | /home/cps/mysql/trees/mysql-4.1/sql/share/english|
+-------------+--------------------------------------------------+
7 rows in set (0.01 sec)
?SHOW LOG FILES

相关标签: 客户端