当前位置:网站首页>Vernacular high concurrency (2)
Vernacular high concurrency (2)
2022-07-07 03:32:00 【Your brother Dachen】
background
This is the second part of the three high topics , I thought for a long time about how to connect this topic , Later, I thought I would talk in the direction of traffic , From user request to server to user .
Suddenly 200 Million requests
Our server can bear 200 Ten thousand requests ? answer , Sure , But the condition can only be an empty link after three handshakes , We know linux All documents in , So one request for one linux It is also a file fd, Then just mine linux The number of files is large enough to receive 200 Million requests , A request defaults to 4k,200w * 4k however 8M There is no problem with the memory around , But the premise is that these are empty links , If the client sends a large amount of data to the server , The server needs to do cpu Do a lot of calculations , After processing, a large amount of data is returned to the client , Don't say that 2000 ten thousand ,1000 It's all hard .
For our secsha scene , A single machine cannot bear 200 Million requests , Therefore, it is necessary to introduce load balancing . Route requests to multiple places .
NGINX
First of all, I thought of nginx,nginx yes 7 Layer load balancing , The amount of concurrency is about 5w about , If you want to support 200 Million concurrent , Need to have 40 individual nginx Talent .
LVS perhaps F5 The server
a nginx 5 Million concurrent , So you need to nginx One more layer above 4 Layer load balancing , All say lvs Concurrent in hundreds of thousands , Assuming that 20 ten thousand , need 10 platform lvs.
DNS Load balancing
a lvs It still seems unbearable 200 Million concurrent , It seems that a layer is needed above him , This floor is DNS, adopt ip To do load balancing , One lvs One ip.
summary
Hundreds of millions of concurrency is also this routine , If one layer is not enough, add another layer ,ip If it's not enough, add a few more ip, If the machine room is not enough, add several more machine rooms .
Reference resources
边栏推荐
猜你喜欢
Depth analysis of compilation constants, classloader classes, and system class loaders
Flink Task退出流程与Failover机制
我的勇敢对线之路--详细阐述,浏览器输入URL发生了什么
存储过程与函数(MySQL)
Code quality management
[cpk-ra6m4 development board environment construction based on RT thread studio]
体会设计细节
input_ delay
Make (convert) ICO Icon
Flutter3.0, the applet is not only run across mobile applications
随机推荐
源代码保密的意义和措施
Appx代码签名指南
迷失在MySQL的锁世界
【DPDK】dpdk样例源码解析之三:dpdk-l3fwd_001
函数重入、函数重载、函数重写自己理解
Restcloud ETL Community Edition June featured Q & A
Huawei and Xiaomi "copy each other"
19.(arcgis api for js篇)arcgis api for js线采集(SketchViewModel)
Matlab Error (Matrix dimensions must agree)
[colmap] 3D reconstruction with known camera pose
Ubuntu20 installation redisjson record
Set WiFi automatic connection for raspberry pie
leetcode
变量、流程控制与游标(MySQL)
小程序能运行在自有App中,且实现直播和连麦?
Jericho is in non Bluetooth mode. Do not jump back to Bluetooth mode when connecting the mobile phone [chapter]
【colmap】已知相机位姿情况下进行三维重建
Decoration design enterprise website management system source code (including mobile source code)
Cocos2d-x Box2D物理引擎编译设置
Lavel PHP artisan automatically generates a complete set of model+migrate+controller commands