MYSQL连接方式
来源:互联网 发布:sql语句修改字段 编辑:程序博客网 时间:2024/06/01 23:32
这种方式会在TCP/IP 连接上建立一个基于网络的连接请求,一般是client连接跑在server上的MySQL实例,2台机器通过一个TCP/IP 网络连接。
[root@lucky performance_schema]# mysql -h 192.168.21.210 -uroot -p111111
mysql: [Warning] Using a password on the command line interface can be insecure.
Welcome to the MySQL monitor. Commands end with ; or \g.
Your MySQL connection id is 20
Server version: 5.7.4-m14 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> exit
2.UNIX域套接字
UNIX域套接字并不是网络协议,所以只能在MySQL客户端和数据库实例在一台服务器上使用,用户可以在配置文件中指定套接字文件
--socket=/tmp/mysql.sock
[root@lucky performance_schema]# mysql -S/var/lib/mysql/mysql.sock -uroot -p1111
11
mysql: [Warning] Using a password on the command line interface can be insecure.
Welcome to the MySQL monitor. Commands end with ; or \g.
Your MySQL connection id is 22
Server version: 5.7.4-m14 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>
- MySQL 远程连接方式
- JDBC连接MySql方式
- MySQL连接方式
- MYSQL连接方式
- JDBC方式连接mysql
- mysql连接方式
- MySQL连接方式
- php7连接mysql方式
- java连接mysql 数据库方式
- mysql 之PDO连接方式
- mysql表的连接方式
- PHP 连接 MySQL(MySQLi方式)
- Mysql的各种连接方式
- MySQL连接两种方式
- VS2013通过MySQL方式连接到MySQL
- [mysql]MySQL 两种连接方式
- PHP6中mysql连接方式的改变
- vs2008连接MySQL,采用C API方式
- 九度OJ 1192:回文字符串
- POJ 2823 Sliding Window(单调队列)
- 覆写onSaveInstanceState(),在Activity销毁前保存数据。
- 复习以前写过的知识点
- 几个软件研发团队管理的小问题
- MYSQL连接方式
- HDU 5289 思路+线段树处理
- Weblogic启动报错
- HDU-4552-怪盗基德的挑战书
- ARM寄存器介绍
- zoj 1060 Sorting It All Out(拓扑排序)
- leetCode 82.Remove Duplicates from Sorted List II (删除排序链表的重复II) 解题思路和方法
- Dynamics CRM2015 非基础语言环境下产品无法新建的问题
- Android如何设置圆角按钮