这里是登录3308端口数据库
[root@HE1 bin]#mysql -uroot -p -P3308 -h 192.168.1.48
Enter password:
Welcome to the MySQL monitor. Commands end with ; or \g.
Your MySQL connection id is 8 Server version: 5.6.16-log MySQL Community Server (GPL)
Copyright (c) 2000,
2014, Oracle and/or its affiliates. All rights reserved.
Oracle is a
registered trademark of Oracle Corporation and/or its affiliates. Other names may be trademarks of their respective owners.
Type 'help;' or '\h'
for help. Type '\c' to clear the current input statement.
Type 'help;' or '\h'
for help. Type '\c' to clear the current input statement.
mysql> show databases;
+--------------------+
| Database |
+--------------------+
| information_schema
|
| 3308db |
| mysql |
| performance_schema
|
| test |
+--------------------+
5 rows in set (0.00sec)
mysql> quit
Bye
利用3308端口的socket文件登录数据库
[root@HE1 bin]#mysql -uroot -p -S /data/mysql_3308/mysql_3308.sock
Enter password:
Welcome to the MySQL monitor. Commands end with ; or \g.
Your MySQL connection id is 9 Server version: 5.6.16-log MySQL Community Server (GPL)
Copyright (c) 2000,
2014, Oracle and/or its affiliates. All rights reserved.
Oracle is a
registered trademark of Oracle Corporation and/or its affiliates. Other names may be trademarks of their respective owners.
Type 'help;' or '\h'
for help. Type '\c' to clear the current input statement.
mysql> show databases;
+--------------------+
| Database |
+--------------------+
| information_schema
|
| 3308db |
| mysql |
| performance_schema
|
| test |
+--------------------+
5 rows in set (0.00sec)
至此,MySQL5.6多实例部署完成。