MySQL/MariaDB数据库的并发控制
MySQL/MariaDB数据库的并发控制
作者:尹正杰
版权声明:原创作品,谢绝转载!否则将追究法律责任。
一.并发控制概述
1>.什么是并发控制
MySQL是一个服务器级别的数据库,它通常放在网络上有很多用户并发访问的,因此并发控制很关键。
2>.锁粒度
表级锁(MyISAM和Innodb都支持) 行级锁(仅Innodb支持,MyISAM不支持)
3>.锁
读锁:
共享锁,只读不可写(包括当前事务) ,多个读互不阻塞
写锁:
独占锁,排它锁,写锁会阻塞其它事务(不包括当前事务)的读和它锁
4>.实现
存储引擎:
自行实现其锁策略和锁粒度
服务器级:实现了锁,表级锁,用户可显式请求
5>.分类
隐式锁:
由存储引擎自动施加锁
显式锁:
用户手动请求
6>.锁策略
在锁粒度及数据安全性寻求的平衡机制
7>.死锁
两个或多个事务在同一资源相互占用,并请求锁定对方占用的资源的状态
二.针对表级别显式使用锁实战案例
1>.查看锁帮助信息
MariaDB [yinzhengjie]> HELP LOCK
Name: 'LOCK'
Description:
Syntax:
LOCK TABLES
tbl_name [[AS] alias] lock_type
[, tbl_name [[AS] alias] lock_type] ... lock_type:
READ [LOCAL]
| [LOW_PRIORITY] WRITE UNLOCK TABLES MySQL enables client sessions to acquire table locks explicitly for the
purpose of cooperating with other sessions for access to tables, or to
prevent other sessions from modifying tables during periods when a
session requires exclusive access to them. A session can acquire or
release locks only for itself. One session cannot acquire locks for
another session or release locks held by another session. Locks may be used to emulate transactions or to get more speed when
updating tables. This is explained in more detail later in this
section. LOCK TABLES explicitly acquires table locks for the current client
session. Table locks can be acquired for base tables or views. You must
have the LOCK TABLES privilege, and the SELECT privilege for each
object to be locked. For view locking, LOCK TABLES adds all base tables used in the view to
the set of tables to be locked and locks them automatically. If you
lock a table explicitly with LOCK TABLES, any tables used in triggers
are also locked implicitly, as described in
https://mariadb.com/kb/en/triggers-and-implicit-locks/. UNLOCK TABLES explicitly releases any table locks held by the current
session. LOCK TABLES implicitly releases any table locks held by the
current session before acquiring new locks. Another use for UNLOCK TABLES is to release the global read lock
acquired with the FLUSH TABLES WITH READ LOCK statement, which enables
you to lock all tables in all databases. See [HELP FLUSH]. (This is a
very convenient way to get backups if you have a file system such as
Veritas that can take snapshots in time.) URL: https://mariadb.com/kb/en/transactions-lock/ MariaDB [yinzhengjie]>
MariaDB [yinzhengjie]> HELP LOCK
2>.添加读锁
MariaDB [yinzhengjie]> LOCK TABLES students READ; #添加读锁后,可读不可写
Query OK, 0 rows affected (0.00 sec) MariaDB [yinzhengjie]>
MariaDB [yinzhengjie]> SELECT * FROM students;
+-------+-----------------------+-----+--------+---------+-----------+
| StuID | Name | Age | Gender | ClassID | TeacherID |
+-------+-----------------------+-----+--------+---------+-----------+
| 1 | Shi Zhongyu | 22 | M | 2 | 3 |
| 2 | Shi Potian | 22 | M | 1 | 7 |
| 3 | Xie Yanke | 53 | M | 2 | 16 |
| 4 | Ding Dian | 32 | M | 4 | 4 |
| 5 | Yu Yutong | 26 | M | 3 | 1 |
| 6 | Shi Qing | 46 | M | 5 | NULL |
| 7 | Xi Ren | 19 | F | 3 | NULL |
| 8 | Lin Daiyu | 17 | F | 7 | NULL |
| 9 | Ren Yingying | 20 | F | 6 | NULL |
| 10 | Yue Lingshan | 19 | F | 3 | NULL |
| 11 | Yuan Chengzhi | 23 | M | 6 | NULL |
| 12 | Wen Qingqing | 19 | F | 1 | NULL |
| 13 | Tian Boguang | 33 | M | 2 | NULL |
| 14 | Lu Wushuang | 17 | F | 3 | NULL |
| 15 | Duan Yu | 19 | M | 4 | NULL |
| 16 | Xu Zhu | 21 | M | 1 | NULL |
| 17 | Lin Chong | 25 | M | 4 | NULL |
| 18 | Hua Rong | 23 | M | 7 | NULL |
| 19 | Xue Baochai | 18 | F | 6 | NULL |
| 20 | Diao Chan | 19 | F | 7 | NULL |
| 21 | Huang Yueying | 22 | F | 6 | NULL |
| 22 | Xiao Qiao | 20 | F | 1 | NULL |
| 23 | Ma Chao | 23 | M | 4 | NULL |
| 24 | Xu Xian | 27 | M | NULL | NULL |
| 25 | 齐天大圣孙悟空 | 100 | M | NULL | NULL |
+-------+-----------------------+-----+--------+---------+-----------+
25 rows in set (0.00 sec) MariaDB [yinzhengjie]>
MariaDB [yinzhengjie]> UPDATE students SET Age = 120 WHERE Name = '齐天大圣孙悟空';
ERROR 1099 (HY000): Table 'students' was locked with a READ lock and can't be updated
MariaDB [yinzhengjie]>
MariaDB [yinzhengjie]>
MariaDB [yinzhengjie]> LOCK TABLES students READ; #添加读锁后,可读不可写
3>.解锁
MariaDB [yinzhengjie]> SELECT * FROM students;
+-------+-----------------------+-----+--------+---------+-----------+
| StuID | Name | Age | Gender | ClassID | TeacherID |
+-------+-----------------------+-----+--------+---------+-----------+
| 1 | Shi Zhongyu | 22 | M | 2 | 3 |
| 2 | Shi Potian | 22 | M | 1 | 7 |
| 3 | Xie Yanke | 53 | M | 2 | 16 |
| 4 | Ding Dian | 32 | M | 4 | 4 |
| 5 | Yu Yutong | 26 | M | 3 | 1 |
| 6 | Shi Qing | 46 | M | 5 | NULL |
| 7 | Xi Ren | 19 | F | 3 | NULL |
| 8 | Lin Daiyu | 17 | F | 7 | NULL |
| 9 | Ren Yingying | 20 | F | 6 | NULL |
| 10 | Yue Lingshan | 19 | F | 3 | NULL |
| 11 | Yuan Chengzhi | 23 | M | 6 | NULL |
| 12 | Wen Qingqing | 19 | F | 1 | NULL |
| 13 | Tian Boguang | 33 | M | 2 | NULL |
| 14 | Lu Wushuang | 17 | F | 3 | NULL |
| 15 | Duan Yu | 19 | M | 4 | NULL |
| 16 | Xu Zhu | 21 | M | 1 | NULL |
| 17 | Lin Chong | 25 | M | 4 | NULL |
| 18 | Hua Rong | 23 | M | 7 | NULL |
| 19 | Xue Baochai | 18 | F | 6 | NULL |
| 20 | Diao Chan | 19 | F | 7 | NULL |
| 21 | Huang Yueying | 22 | F | 6 | NULL |
| 22 | Xiao Qiao | 20 | F | 1 | NULL |
| 23 | Ma Chao | 23 | M | 4 | NULL |
| 24 | Xu Xian | 27 | M | NULL | NULL |
| 25 | 齐天大圣孙悟空 | 100 | M | NULL | NULL |
+-------+-----------------------+-----+--------+---------+-----------+
25 rows in set (0.00 sec) MariaDB [yinzhengjie]>
MariaDB [yinzhengjie]> UPDATE students SET Age = 120 WHERE Name = '齐天大圣孙悟空';
ERROR 1099 (HY000): Table 'students' was locked with a READ lock and can't be updated
MariaDB [yinzhengjie]>
MariaDB [yinzhengjie]> UNLOCK TABLES; #对表进行解锁
Query OK, 0 rows affected (0.00 sec) MariaDB [yinzhengjie]>
MariaDB [yinzhengjie]> UPDATE students SET Age = 120 WHERE Name = '齐天大圣孙悟空';
Query OK, 1 row affected (0.00 sec)
Rows matched: 1 Changed: 1 Warnings: 0 MariaDB [yinzhengjie]>
MariaDB [yinzhengjie]> SELECT * FROM students;
+-------+-----------------------+-----+--------+---------+-----------+
| StuID | Name | Age | Gender | ClassID | TeacherID |
+-------+-----------------------+-----+--------+---------+-----------+
| 1 | Shi Zhongyu | 22 | M | 2 | 3 |
| 2 | Shi Potian | 22 | M | 1 | 7 |
| 3 | Xie Yanke | 53 | M | 2 | 16 |
| 4 | Ding Dian | 32 | M | 4 | 4 |
| 5 | Yu Yutong | 26 | M | 3 | 1 |
| 6 | Shi Qing | 46 | M | 5 | NULL |
| 7 | Xi Ren | 19 | F | 3 | NULL |
| 8 | Lin Daiyu | 17 | F | 7 | NULL |
| 9 | Ren Yingying | 20 | F | 6 | NULL |
| 10 | Yue Lingshan | 19 | F | 3 | NULL |
| 11 | Yuan Chengzhi | 23 | M | 6 | NULL |
| 12 | Wen Qingqing | 19 | F | 1 | NULL |
| 13 | Tian Boguang | 33 | M | 2 | NULL |
| 14 | Lu Wushuang | 17 | F | 3 | NULL |
| 15 | Duan Yu | 19 | M | 4 | NULL |
| 16 | Xu Zhu | 21 | M | 1 | NULL |
| 17 | Lin Chong | 25 | M | 4 | NULL |
| 18 | Hua Rong | 23 | M | 7 | NULL |
| 19 | Xue Baochai | 18 | F | 6 | NULL |
| 20 | Diao Chan | 19 | F | 7 | NULL |
| 21 | Huang Yueying | 22 | F | 6 | NULL |
| 22 | Xiao Qiao | 20 | F | 1 | NULL |
| 23 | Ma Chao | 23 | M | 4 | NULL |
| 24 | Xu Xian | 27 | M | NULL | NULL |
| 25 | 齐天大圣孙悟空 | 120 | M | NULL | NULL |
+-------+-----------------------+-----+--------+---------+-----------+
25 rows in set (0.00 sec) MariaDB [yinzhengjie]>
MariaDB [yinzhengjie]> UNLOCK TABLES; #对表进行解锁
4>.添加写锁
MariaDB [yinzhengjie]> SELECT * FROM students;
+-------+-----------------------+-----+--------+---------+-----------+
| StuID | Name | Age | Gender | ClassID | TeacherID |
+-------+-----------------------+-----+--------+---------+-----------+
| 1 | Shi Zhongyu | 22 | M | 2 | 3 |
| 2 | Shi Potian | 22 | M | 1 | 7 |
| 3 | Xie Yanke | 53 | M | 2 | 16 |
| 4 | Ding Dian | 32 | M | 4 | 4 |
| 5 | Yu Yutong | 26 | M | 3 | 1 |
| 6 | Shi Qing | 46 | M | 5 | NULL |
| 7 | Xi Ren | 19 | F | 3 | NULL |
| 8 | Lin Daiyu | 17 | F | 7 | NULL |
| 9 | Ren Yingying | 20 | F | 6 | NULL |
| 10 | Yue Lingshan | 19 | F | 3 | NULL |
| 11 | Yuan Chengzhi | 23 | M | 6 | NULL |
| 12 | Wen Qingqing | 19 | F | 1 | NULL |
| 13 | Tian Boguang | 33 | M | 2 | NULL |
| 14 | Lu Wushuang | 17 | F | 3 | NULL |
| 15 | Duan Yu | 19 | M | 4 | NULL |
| 16 | Xu Zhu | 21 | M | 1 | NULL |
| 17 | Lin Chong | 25 | M | 4 | NULL |
| 18 | Hua Rong | 23 | M | 7 | NULL |
| 19 | Xue Baochai | 18 | F | 6 | NULL |
| 20 | Diao Chan | 19 | F | 7 | NULL |
| 21 | Huang Yueying | 22 | F | 6 | NULL |
| 22 | Xiao Qiao | 20 | F | 1 | NULL |
| 23 | Ma Chao | 23 | M | 4 | NULL |
| 24 | Xu Xian | 27 | M | NULL | NULL |
| 25 | 齐天大圣孙悟空 | 120 | M | NULL | NULL |
+-------+-----------------------+-----+--------+---------+-----------+
25 rows in set (0.00 sec) MariaDB [yinzhengjie]>
MariaDB [yinzhengjie]> LOCK TABLES students WRITE; #添加写锁后,当前终端可读可写,其它终端既不可读也不可写
Query OK, 0 rows affected (0.00 sec) MariaDB [yinzhengjie]>
MariaDB [yinzhengjie]> UPDATE students SET Age = 125 WHERE Name = '齐天大圣孙悟空';
Query OK, 1 row affected (0.00 sec)
Rows matched: 1 Changed: 1 Warnings: 0 MariaDB [yinzhengjie]>
MariaDB [yinzhengjie]> SELECT * FROM students;
+-------+-----------------------+-----+--------+---------+-----------+
| StuID | Name | Age | Gender | ClassID | TeacherID |
+-------+-----------------------+-----+--------+---------+-----------+
| 1 | Shi Zhongyu | 22 | M | 2 | 3 |
| 2 | Shi Potian | 22 | M | 1 | 7 |
| 3 | Xie Yanke | 53 | M | 2 | 16 |
| 4 | Ding Dian | 32 | M | 4 | 4 |
| 5 | Yu Yutong | 26 | M | 3 | 1 |
| 6 | Shi Qing | 46 | M | 5 | NULL |
| 7 | Xi Ren | 19 | F | 3 | NULL |
| 8 | Lin Daiyu | 17 | F | 7 | NULL |
| 9 | Ren Yingying | 20 | F | 6 | NULL |
| 10 | Yue Lingshan | 19 | F | 3 | NULL |
| 11 | Yuan Chengzhi | 23 | M | 6 | NULL |
| 12 | Wen Qingqing | 19 | F | 1 | NULL |
| 13 | Tian Boguang | 33 | M | 2 | NULL |
| 14 | Lu Wushuang | 17 | F | 3 | NULL |
| 15 | Duan Yu | 19 | M | 4 | NULL |
| 16 | Xu Zhu | 21 | M | 1 | NULL |
| 17 | Lin Chong | 25 | M | 4 | NULL |
| 18 | Hua Rong | 23 | M | 7 | NULL |
| 19 | Xue Baochai | 18 | F | 6 | NULL |
| 20 | Diao Chan | 19 | F | 7 | NULL |
| 21 | Huang Yueying | 22 | F | 6 | NULL |
| 22 | Xiao Qiao | 20 | F | 1 | NULL |
| 23 | Ma Chao | 23 | M | 4 | NULL |
| 24 | Xu Xian | 27 | M | NULL | NULL |
| 25 | 齐天大圣孙悟空 | 125 | M | NULL | NULL |
+-------+-----------------------+-----+--------+---------+-----------+
25 rows in set (0.00 sec) MariaDB [yinzhengjie]>
MariaDB [yinzhengjie]> LOCK TABLES students WRITE; #添加写锁后,当前终端可读可写,其它终端既不可读也不可写
三.针对数据库级别显式使用锁实战案例
1>.添加读锁(注意:对数据库级别并没有写锁)
MariaDB [yinzhengjie]> FLUSH TABLES WITH READ LOCK; #为数据库实例添加读锁,可以对数据库进行读取操作,无法对所有数据库进行写入操作,一般用作数据库温备,并不适合数据库冷备和热备。
Query OK, 0 rows affected (0.00 sec) MariaDB [yinzhengjie]>
MariaDB [yinzhengjie]> CREATE TABLE students_backup SELECT * FROM students; #不可对当前数据库进行写入操作
ERROR 1223 (HY000): Can't execute the query because you have a conflicting read lock
MariaDB [yinzhengjie]>
MariaDB [yinzhengjie]> GRANT ALL ON yinzhengjie.* to jason@'172.30.1.%' IDENTIFIED BY 'yinzhengjie'; #很显然其它数据库也不能写入数据了,包括mysql系统数据库
ERROR 1223 (HY000): Can't execute the query because you have a conflicting read lock
MariaDB [yinzhengjie]>
MariaDB [yinzhengjie]> SELECT * FROM students;
+-------+-----------------------+-----+--------+---------+-----------+
| StuID | Name | Age | Gender | ClassID | TeacherID |
+-------+-----------------------+-----+--------+---------+-----------+
| 1 | Shi Zhongyu | 22 | M | 2 | 3 |
| 2 | Shi Potian | 22 | M | 1 | 7 |
| 3 | Xie Yanke | 53 | M | 2 | 16 |
| 4 | Ding Dian | 32 | M | 4 | 4 |
| 5 | Yu Yutong | 26 | M | 3 | 1 |
| 6 | Shi Qing | 46 | M | 5 | NULL |
| 7 | Xi Ren | 19 | F | 3 | NULL |
| 8 | Lin Daiyu | 17 | F | 7 | NULL |
| 9 | Ren Yingying | 20 | F | 6 | NULL |
| 10 | Yue Lingshan | 19 | F | 3 | NULL |
| 11 | Yuan Chengzhi | 23 | M | 6 | NULL |
| 12 | Wen Qingqing | 19 | F | 1 | NULL |
| 13 | Tian Boguang | 33 | M | 2 | NULL |
| 14 | Lu Wushuang | 17 | F | 3 | NULL |
| 15 | Duan Yu | 19 | M | 4 | NULL |
| 16 | Xu Zhu | 21 | M | 1 | NULL |
| 17 | Lin Chong | 25 | M | 4 | NULL |
| 18 | Hua Rong | 23 | M | 7 | NULL |
| 19 | Xue Baochai | 18 | F | 6 | NULL |
| 20 | Diao Chan | 19 | F | 7 | NULL |
| 21 | Huang Yueying | 22 | F | 6 | NULL |
| 22 | Xiao Qiao | 20 | F | 1 | NULL |
| 23 | Ma Chao | 23 | M | 4 | NULL |
| 24 | Xu Xian | 27 | M | NULL | NULL |
| 25 | 齐天大圣孙悟空 | 120 | M | NULL | NULL |
+-------+-----------------------+-----+--------+---------+-----------+
rows in set (0.00 sec) MariaDB [yinzhengjie]>
MariaDB [yinzhengjie]> FLUSH TABLES WITH READ LOCK; #通常在备份前加全局读锁,可以对数据库进行读取操作,无法对所有数据库进行写入操作。
2>.解锁
MariaDB [yinzhengjie]> FLUSH TABLES WITH READ LOCK;
Query OK, 0 rows affected (0.00 sec) MariaDB [yinzhengjie]>
MariaDB [yinzhengjie]>
MariaDB [yinzhengjie]> CREATE TABLE students_backup SELECT * FROM students;
ERROR 1223 (HY000): Can't execute the query because you have a conflicting read lock
MariaDB [yinzhengjie]>
MariaDB [yinzhengjie]> UNLOCK TABLES;
Query OK, 0 rows affected (0.00 sec) MariaDB [yinzhengjie]>
MariaDB [yinzhengjie]> CREATE TABLE students_backup SELECT * FROM students;
Query OK, 25 rows affected (0.01 sec)
Records: 25 Duplicates: 0 Warnings: 0 MariaDB [yinzhengjie]>
MariaDB [yinzhengjie]> UNLOCK TABLES;
3>.关闭正在打开的表(清除查询缓存)
MariaDB [yinzhengjie]> FLUSH TABLES ;
Query OK, 0 rows affected (0.00 sec) MariaDB [yinzhengjie]>
四.查询时加写或读锁
SELECT clause [FOR UPDATE | LOCK IN SHARE MODE] #这种方式使用相对较少,感兴趣的小伙伴可自行查阅资料 SELECT ... For Update会把行进行写锁定,这是排它锁。
使用主键明确记录行,那么就对存在的主键的记录使用行级锁。例如id=100
使用主键,但不能确定记录,使用表级锁,例如id <> 3。
条件中不使用主键,会使用表级锁。例如,name='tom'
这是悲观锁,我怕别人在我用的时候抢资源,先锁上,独占。悲观锁往往用在数据库的锁机制中,因为独占,所以会影响并发。所以,For Update非要使用,请一定要保证时间短,且一定利用行级锁。
乐观锁,就是心宽,认为极少冲突,只有写入才加锁。但需要检测数据冲突。
MySQL/MariaDB数据库的并发控制的更多相关文章
- MySQL/MariaDB数据库的事务和隔离级别
MySQL/MariaDB数据库的事务和隔离级别 作者:尹正杰 版权声明:原创作品,谢绝转载!否则将追究法律责任. 一.事务概述 1>.事务Transactions 一组原子性的SQL语句 ...
- MySQL/MariaDB数据库的存储引擎
MySQL/MariaDB数据库的存储引擎 作者:尹正杰 版权声明:原创作品,谢绝转载!否则将追究法律责任. 一.MySQL体系结构 连接管理模块: 负责接收远程用户的连接. 线程管理模块: 维护 ...
- MySQL/MariaDB数据库的性能测试
MySQL/MariaDB数据库的性能测试 作者:尹正杰 版权声明:原创作品,谢绝转载!否则将追究法律责任. 一.数据库服务衡量指标 qps: query per second(每秒支持多少查询 ...
- MySQL/MariaDB数据库的Galera高可用性集群实战
MySQL/MariaDB数据库的Galera高可用性集群实战 作者:尹正杰 版权声明:原创作品,谢绝转载!否则将追究法律责任. 一.Galera Cluster概述 1>.什么是Gale ...
- MySQL/MariaDB数据库的MHA实现高可用实战
MySQL/MariaDB数据库的MHA实现高可用实战 作者:尹正杰 版权声明:原创作品,谢绝转载!否则将追究法律责任. 一.MySQL高可用常见的解决方案 1>.Multi-Master ...
- MySQL/MariaDB数据库的PROXY实现读写分离
MySQL/MariaDB数据库的PROXY实现读写分离 作者:尹正杰 版权声明:原创作品,谢绝转载!否则将追究法律责任. 一.ProxySQL概述 1>.各家互联网公司读写分离的解决方案 m ...
- MySQL/MariaDB数据库的复制监控和维护
MySQL/MariaDB数据库的复制监控和维护 作者:尹正杰 版权声明:原创作品,谢绝转载!否则将追究法律责任. 一.清理日志 1>.删除指定日志文件名称之前的日志(也可用基于时间) M ...
- MySQL/MariaDB数据库的复制加密
MySQL/MariaDB数据库的复制加密 作者:尹正杰 版权声明:原创作品,谢绝转载!否则将追究法律责任. 一.MySQL的安全问题 1>.基于SSL复制 在默认的主从复制过程或远程连接 ...
- MySQL/MariaDB数据库的复制过滤器
MySQL/MariaDB数据库的复制过滤器 作者:尹正杰 版权声明:原创作品,谢绝转载!否则将追究法律责任. 一.复制过滤器概述 1>.复制器过滤器功能 让从节点仅复制指定的数据库,或指 ...
随机推荐
- OpenShift 4.2环境离线部署Operatorhub
缺省离线环境安装的ocp4的Operatorhub是没有内容的.详细离线文档参考官网文档 https://docs.openshift.com/container-platform/4.2/opera ...
- EasyDSS高性能RTMP、HLS(m3u8)、HTTP-FLV、RTSP流媒体服务器功能简介---实时数据统计报表、视频文件上传、点播、分享、集成
熟悉EasyDSS流媒体服务器的小伙伴应该都知道,EasyDSS通过将EasyRTMP推流的直播流进行直播转码.智能处理.视频分发,再通过 CDN 分发节点分发到终端播放 SDK为观众播放高清低延时的 ...
- Maya编程——沿Curve绘制圆柱
操作流程: 1. VS运行代码,生成插件 2. 打开Maya绘制曲线,加载插件 3. 选中绘制的曲线,运行插件 Posts1.0 代码: #include <maya/MSimple.h> ...
- 微信小程序tabBar底部导航 不显示问题解析
2019年十月八号 转藏: 版权声明:本文为博主原创文章,遵循 CC 4.0 BY-SA 版权协议,转载请附上原文出处链接和本声明. 本文链接:https://blog.csdn.net/wy_Blo ...
- sql-server-dmv-starter-pack
SELECT wait_type , ) AS [wait_time_s] FROM sys.dm_os_wait_stats DOWS WHERE wait_type NOT IN ( 'SLEEP ...
- 头部文件jq嵌入笔记
var headHtml = '<div class="container">' + '<div class="navbar-header"& ...
- centos7 spark2.3.1集群搭建
1.安装jdk 2.安装scala 参照jdk的安装 3.ssh 免密码登录 4.安装hadoop 以上四步请参照 centos7 安装hadoop2.7.6(分布式) 5.安装spark 1) ...
- 【插件】【idea】的Mybatis Plugin插件方便mapper接口方法和mapper XML文件之间来回切换
效果 安装 这是2019.2版本的,旧版的有点不一样
- Windows下编译Redis5.0.5
先去弄Cygwin环境 http://www.cygwin.com/ 下载完成 打开 下一步 下一步 下一步 下一步 下一步,出现一个界面,让你添加地址,你打开官网,选择mirror sites,点击 ...
- CentOS7-Docker 搭建Maven私服
使用Docker搭建Maven私服 前言本文主要介绍,使用Docker创建一个nexus私服,然后编写一个Library,上传到私服,然后使用demo工程依赖. 本文不对Maven.Nexus.私服等 ...