PHPPROGLIB Telegram 5672
🎮 Балансировка нагрузки для TCP-сервисов

Проблема: необходимо распределить трафик между несколькими TCP-серверами.

Решение: в книге "Nginx Cookbook: Advanced Recipes for High-performance Load Balancing" автор показывает использование модуля stream для балансировки нагрузки на уровне транспортного слоя.

Пример кода:
stream {
upstream mysql_read {
server read1.example.com:3306 weight=5;
server read2.example.com:3306;
server 10.10.12.34:3306 backup;
}

server {
listen 3306;
proxy_pass mysql_read;
}
}


Преимущества:

— Поддержка балансировки для TCP-сервисов.
— Гибкая настройка весов серверов.
— Резервирование серверов для повышения надёжности.

Еще больше полезных книг — в нашем канале @progbook
Please open Telegram to view this post
VIEW IN TELEGRAM



tgoop.com/phpproglib/5672
Create:
Last Update:

🎮 Балансировка нагрузки для TCP-сервисов

Проблема: необходимо распределить трафик между несколькими TCP-серверами.

Решение: в книге "Nginx Cookbook: Advanced Recipes for High-performance Load Balancing" автор показывает использование модуля stream для балансировки нагрузки на уровне транспортного слоя.

Пример кода:

stream {
upstream mysql_read {
server read1.example.com:3306 weight=5;
server read2.example.com:3306;
server 10.10.12.34:3306 backup;
}

server {
listen 3306;
proxy_pass mysql_read;
}
}


Преимущества:

— Поддержка балансировки для TCP-сервисов.
— Гибкая настройка весов серверов.
— Резервирование серверов для повышения надёжности.

Еще больше полезных книг — в нашем канале @progbook

BY Библиотека пхпшника | PHP, Laravel, Symfony, CodeIgniter


Share with your friend now:
tgoop.com/phpproglib/5672

View MORE
Open in Telegram


Telegram News

Date: |

When choosing the right name for your Telegram channel, use the language of your target audience. The name must sum up the essence of your channel in 1-3 words. If you’re planning to expand your Telegram audience, it makes sense to incorporate keywords into your name. On Tuesday, some local media outlets included Sing Tao Daily cited sources as saying the Hong Kong government was considering restricting access to Telegram. Privacy Commissioner for Personal Data Ada Chung told to the Legislative Council on Monday that government officials, police and lawmakers remain the targets of “doxxing” despite a privacy law amendment last year that criminalised the malicious disclosure of personal information. Find your optimal posting schedule and stick to it. The peak posting times include 8 am, 6 pm, and 8 pm on social media. Try to publish serious stuff in the morning and leave less demanding content later in the day. The group also hosted discussions on committing arson, Judge Hui said, including setting roadblocks on fire, hurling petrol bombs at police stations and teaching people to make such weapons. The conversation linked to arson went on for two to three months, Hui said. Over 33,000 people sent out over 1,000 doxxing messages in the group. Although the administrators tried to delete all of the messages, the posting speed was far too much for them to keep up.
from us


Telegram Библиотека пхпшника | PHP, Laravel, Symfony, CodeIgniter
FROM American