MySQL实例管理器识别的命令
2007-10-29 11:02:20 来源:WEB开发网一旦你已经为MySQL实例管理器设置了一个密码文件并且IM正在运行,你可以连接它。你可以使用mysql客户端工具通过标准MySQL API来连接。以下是MySQL实例管理器目前可以接收的命令的清单和例子。
·START INSTANCE <instance_name>
该命令将试图启动一个实例:
mysql> START INSTANCE mysqld4;
Query OK, 0 rows affected (0,00 sec)
·STOP INSTANCE <instance_name>
将试图停止一个实例:
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 <instance_name>
显示选定的实例的状态和版本信息:
mysql> SHOW INSTANCE STATUS mysqld3;
+---------------+--------+---------+
| instance_name | status | version |
+---------------+--------+---------+
| mysqld3 | online | unknown |
+---------------+--------+---------+
1 row in set (0.00 sec)
·SHOW INSTANCE OPTIONS <instance_name>
显示实例使用的选项:
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 <instance_name> LOG FILES
更多精彩
赞助商链接