首页 | 官方网站   微博 | 高级检索  
     

MongoDB负载均衡算法优化研究
引用本文:陈敬静,马明栋,王得玉.MongoDB负载均衡算法优化研究[J].计算机技术与发展,2020(3):88-92.
作者姓名:陈敬静  马明栋  王得玉
作者单位:南京邮电大学通信与信息工程学院;南京邮电大学地理与生物信息学院
基金项目:江苏省自然科学基金-青年基金项目(BK20140868)。
摘    要:随着Web2.0网络应用的兴起和大数据技术的发展,传统的关系型数据库(ORDBMS)已经难以满足海量数据的存储需求。非关系型数据库(NoSQL)因其高扩展性、高伸缩性、高可用性和容错性等特点,得到了越来越多的应用。作为一种新兴的NoSQL数据库,MongoDB数据库因具有模式自由、易于扩展、故障自动恢复、支持自动分片等特点,被广泛应用于大数据处理与分析中。文中首先介绍了MongoDB自动分片架构原理和实现机制,然后分析了MongoDB自带的负载均衡算法,其虽能使各个节点数据量达到平衡,但没有考虑各个节点的负载均衡。为了解决节点的负载平均问题,在原算法基础上提出了一种基于节点实时负载的负载均衡改进算法,改进算法的主要思想是引入节点负载指数作为chunk块迁移的一个判断条件。通过搭建测试环境并进行实验,验证了改进的负载均衡算法可以有效地均衡分片中的数据,提高集群的并发读写性能,从而证明了算法的有效性。

关 键 词:非关系型数据库  MONGODB  自动分片  负载均衡  节点负载

Research on Optimization of MongoDB Load Balancing Algorithm
CHEN Jing-jing,MA Ming-dong,WANG De-yu.Research on Optimization of MongoDB Load Balancing Algorithm[J].Computer Technology and Development,2020(3):88-92.
Authors:CHEN Jing-jing  MA Ming-dong  WANG De-yu
Affiliation:(School of Telecommunications&Information Engineering,Nanjing University of Posts and Telecommunications,Nanjing 210003,China;School of Geographical and Biological Information,Nanjing University of Posts and Telecommunications,Nanjing 210003,China)
Abstract:With the rise of Web2.0 network applications and the development of big data technology,the traditional relational database(ORDBMS)has been difficult to meet the storage requirements of massive data.Non-relational database(NoSQL)has been applied more and more because of its high expansibility,high scalability,high availability and fault tolerance.As a new NoSQL database,MongoDB is widely used in big data processing and analysis because of its free mode,easy expansion,automatic fault recovery and automatic fragmentation.We firstly introduce the principle and implementation mechanism of MongoDB automatic fragmentation architecture,and then analyze the load balancing algorithm of MongoDB.Although it can balance the data volume of each node,the load balancing of each node is not considered.In order to solve the load averaging problem of nodes,an improved load balancing algorithm based on real-time load of nodes is proposed.Its main idea is to introduce the load index of node as a judgment condition for chunk block migration.By setting up the test environment and conducting experiments,it is verified that the improved load balancing algorithm can effectively balance the data in the fragment and improve the concurrent read-write performance of the cluster,which proves its effectiveness.
Keywords:NoSQL  MongoDB  auto-sharding  load balancing  node balancing
本文献已被 维普 等数据库收录!
设为首页 | 免责声明 | 关于勤云 | 加入收藏

Copyright©北京勤云科技发展有限公司    京ICP备09084417号-23

京公网安备 11010802026262号