Alibaba Cloud International Account Purchase: Cloud Server Configuration Guide for the Gaming Industry

cloud 2026-06-09 阅读 7
1

In the game industry, there is a curse that all technical teams have heard: "Research and development for two or three years, blow up for a moment."

Alibaba Cloud International Account Purchase

You may have experienced or seen countless scenes like this on the Internet: a much-anticipated new game was finally tested publicly. As a result, on the first day of service, as soon as the players rushed in, the game was directly stuck in the login interface, or it was to take one step and three steps, with a delay of several thousand milliseconds in releasing skills. In an instant, TapTap and App Store were maxed out by one-star bad reviews.

Many novice R & D teams who play games, or small and medium-sized business owners who have just switched to games, always have a misunderstanding:

"Game Caton? Then I will directly buy the highest matching and most expensive cloud server on Aliyun and Tencent Cloud without thinking?"

I’m sorry, it really won’t work.

The traffic characteristics of the game industry are essentially different from those of ordinary e-commerce and websites. If the selection and architecture are wrong, even if you use hundreds of thousands of top-level servers a month, you will still be fried when you need.

In today's article, let's not engage in long-winded ppt theory, but directly use the real-life writing style of pure vernacular to teach you how to choose cloud server configuration for the game, and thoroughly solve the hard-core proposition of "ten thousand people can't stand together" from the bottom.

The first stage: hard knock hardware-game server selection, in the end see which a few core indicators?

The game is typical.

High concurrency, high real-time, strong computing

Scene. When you go to a big factory (Tengxun Cloud CVM, Aliyun ECS) to check the configuration, you must keep an eye on the following three key items and spend your money on the blade:

1. CPU: to "single-core performance monster", not "multi-core warm swallow water"

This is the first sinkhole that is easiest to step on.

Ordinary webpage/website logic: 1000 individual visits a website, it is 1000 independent lightweight requests. The more CPU cores (such as 64 cores), the better the concurrent processing.

Game clothing logic: in a room or a copy of many games (for example, 100 people play group warfare in the same scene), all positions at the bottom of the game are synchronized and damage calculation is performed in the same thread (main thread). In other words, if your single core performance is not good, even if you have 128 cores in this machine, you can only watch the main thread explode one core while the other 127 cores are idle "fishing".

Iron rule of type selection: CPU is selected for game clothing, and the basic main frequency (Clock Speed) must be above 3.0 GHz. The higher the turbo frequency, the better. Prioritize instances that are tuned for gaming by large manufacturers (such as the latest generation of Intel Xeon or AMD EPYC high-frequency series). It is better to have 4-core 3.6GHz than 16-core 2.2GHz.

2. Network: BGP exclusive bandwidth intranet interconnection

If the Ping value of the game player exceeds 100ms, the action and shooting games will be

Basically can't play.

Public network: must use the domestic first-line factory multi-line BGP whole network navigation network. It ensures that players, whether mobile, connected or telecom, can access the backbone network nearby, keeping physical latency to a minimum.

Bandwidth mode: when the service is just opened or a large-scale promotion activity is held, the bandwidth is recommended to be charged according to the usage traffic (flexible bandwidth), and the upper limit is pulled high enough (for example, 100Mbps or even higher) to prevent players from dropping off the line due to the bandwidth pipeline being squeezed and exploded when the service is opened in an instant.

Intranet: Make sure that your gateway server, game logic server, and database server are all in the same VPC (virtual private cloud) and in the same available area (computer room). The intranet delay between cloud manufacturers and computer rooms is usually within 0.5ms, and the intranet bandwidth can reach 10 trillion yuan. If the server is allowed to communicate across regions, the intranet delay alone can drag the game to death.

The second stage: decoupling architecture-ten thousand people with the same service, not ten thousand people into a server

When you pick the hardware to the top, the carrying capacity of a single server is still physically limited. In order to truly realize the "ten thousand people with the same service", it is not a single machine hard resistance, but a "distributed decoupling architecture".

Purchase an Alibaba Cloud international account

In the deployment of cloud servers, the mature game in the industry is to split the server into different functional roles (that is, to engage in "pipeline division of labor"):

1. Gateway Server (Gateway/Proxy Server)

Responsibilities: It stands at the forefront and directly faces the player. It only does two things: maintain TCP/UDP long connections (Sockets) for thousands of players, and forward the instructions sent by the players to the "logic service" behind ".

Configuration recommendation: high network throughput. The CPU and memory do not need to be too high (for example, 4-core 8G or 8-core 16G), but the instance type with extremely high network packet throughput (PPS, number of packets forwarded per second) must be selected.

2. Game Logic Server (Logic/Scene Server)

Responsibilities: This is the heart of the game, responsible for running all game codes, player moves, monster AI, skill damage calculation.

Configuration recommendation: computing type (high frequency). We recommend 8-core 16G and 16-core 32G high-frequency computing instances with a CPU-to-memory ratio of 1:2.

The secret of the same service for ten thousand people: through "dividing lines" or "dividing rooms". On the surface, players are in a big world (with the same suit), but the underlying structure is: players 1 to 2000 run on logic suit a, and players 2001 to 4000 run on logic suit B. High-speed data synchronization between logical clothing through the intranet.

3. Data cache and database service (Redis / MySQL)

Responsibilities: The player picked up a piece of equipment and was promoted to a higher level. The data must be saved. The game's requirements for reading and writing are milliseconds.

Configuration recommendation: Memory-type top-level storage. The database is definitely the lifeblood of the game.

Anti-Catton move: Never let the game logic suit read and write directly

MySQL hard disk database! You must add a layer of Redis cache servers in the middle. Players play strange games and take medicine in the game. The data is first read and written frantically in the memory (Redis). Every few minutes, the background asynchronously "beats" the data into MySQL hard disk in batches. This can perfectly avoid server Caton caused by slow hard disk I/O reading and writing.

The third stage: the "two moves to save one's life" before going online-pressure measurement and anti-brush

The server has been bought and the structure has been divided. Before the official opening of the service, even if the budget is tight, these two things must be done:

1. Robot pressure test (pressure test)

Find some pressure testing tools on the public network (or write a simple script yourself) to simulate 10000 virtual robots online at the same time, frantically sending packets of login, movement and release skills.

What metrics to look at: Keep an eye on the server's CPU usage. If you find that a certain core has reached 100 percent and the game starts to lose packets, it means that your code has a single-thread bottleneck and must be optimized or the business must be further split before opening the service.

Purchase an Alibaba Cloud international account

2. Access the high-security package to prevent hackers from "ripping off" the opening of the service"

The game industry is the absolute hardest hit by DDoS attacks and CC attacks. Many hackers are focusing on the opening of the new game. On the day of the opening, hundreds of g of traffic will be directly smashed in the past, and then they will privately send your supervisor a "protection fee".

Life-saving operation: In front of the public network IP of the game clothing, the game high-security IP/high-security package of the cloud manufacturer must be mounted. Let the hacker's attack traffic be cleaned up on the high-security node, and then put the clean player traffic into your gateway service. Don't run naked.

Conclusion

To ensure that the game "ten thousand people share the same service but not Caton" is a game made up

Top high frequency hardware + perfect distributed decoupling architecture + silky data cache design

Systems engineering built together.

For the fledgling team, finally give a most economical landing advice:

Don't buy it all at once.

Make full use of the advantages of "elastic scaling" of cloud servers: the initial gateway and logical service can be configured appropriately, and the CPU and network can be monitored through scripts. Once you see a sharp increase in the number of people on the public network, it takes 2 minutes to upgrade the configuration at the console, or open several more logical servers horizontally to split the flow. With the smartest dynamic calculation method, both.

Purchase an Alibaba Cloud international account

Steady holding up the volcanic player flow, but also can help the team to keep every precious venture capital.

2
← 返回新闻中心