Font Size: a A A

Design And Optimization Of High Concurrent Access Mechanism For Web Server

Posted on:2021-02-26Degree:MasterType:Thesis
Country:ChinaCandidate:S J HeFull Text:PDF
GTID:2428330623467318Subject:Electronic and communication engineering
Abstract/Summary:PDF Full Text Request
Today,with the rapid development of the Internet,people's entertainment,shopping,payment and other activities have been inseparable from Internet applications.The rapid development of mobile devices such as computer mobile phones has made the access to information more diversified and the entertainment services more sophisticated.As the number of network users increases,the pressure on the Web server increases exponentially,causing problems such as server downtime and database crashes.Based on the analysis of the high concurrency scenarios of online mall projects,this paper summarizes the objective reasons that affect the concurrency of servers.Based on these factors,this paper focuses on database caching and high concurrent web server load balancing technology,and designs and optimizes the server's high concurrent access mechanism.This thesis focuses on the following points:(1)According to the needs,choose to use MySQL database as data storage.This thesis analyzes the advantages and disadvantages of MySQL database,and proposes MySQL query tuning method for MySQL database query.In the high concurrency environment,in order to ensure the read and write security of the database,the masterslave replication of MySQL is designed and implemented.(2)Analyze the necessity of joining the Redis cache database.In a high concurrency environment,in order to prevent the problem of excessive access to the database and malicious attacks,it is proposed to add a Redis cache database between the Web server and the MySQL database to ensure data security and greatly improve the data.Query efficiency.In order to ensure the reliability of the Redis database and avoid a series of unrecoverable problems caused by downtime or power failure,the Redis cluster strategy was designed and implemented,and the superiority of Redis cache was proved through testing.(3)Analyze the load distribution problem caused by Web cluster,decide to join the load balancing strategy,and propose a new dynamic load balancing strategy based on weighted polling.This dynamic strategy calculates the load weight according to the CPU,memory,disk IO,and network performance of the cluster server node,and obtains the average weight of the response time according to the response time of the node to the interface for a period of time.Both the load weight and the response time weight are inversely related to the initial weight.According to this feature,the weight of the server node is dynamically set.The performance of the load balancing strategy is tested by the JMeter test tool.The comparison shows that the dynamic strategy of this thesis is better than Nginx's built-in weighted polling strategy in response time and throughput,and is more suitable for high concurrency environment.
Keywords/Search Tags:Web Server, High Concurrency, Redis, Nginx, Load Balancing
PDF Full Text Request
Related items