Skip to main content

7th Chapter

 Static Load Balancing means that the workload (like user requests, data access, etc.) is divided manually or in a fixed way between multiple servers. Once set, this division doesn’t change automatically, even if one server gets overloaded or another stays underused.


In load balancing, a deterministic method means that the system always sends a request to the same server based on a fixed rule. For example, if your computer’s IP address is used to decide where your request goes, you will always be sent to the same server every time. This makes the process predictable and stable. But the problem is — if that server gets too many heavy tasks or busy users, it can get overloaded, while other servers may not be doing much.

On the other hand, a probabilistic method works more like rolling a dice. It doesn’t always send the request to the same server. Instead, it chooses one based on chances. For example, Server A might be picked 50% of the time, Server B 30%, and Server C 20%. This helps spread the load more evenly between servers. It’s more flexible and can handle changes better, but it might send the same user to different servers at different times, which can sometimes cause issues with tracking or saving user data.






In dynamic load balancing, the system checks how busy each server is in real-time and sends new requests to the one that’s least busy or most available. Unlike static load balancing (which uses fixed rules), dynamic methods can adjust automatically based on current conditions. This helps avoid overloading any single server and keeps the system running smoothly, even when traffic changes a lot.

There are two main types of dynamic load balancing: centralized and distributed.

In centralized load balancing, there is one main controller (or server) that watches over all the others. It collects information about how busy each server is and then makes the decision about where to send each new request. This method is easier to manage and can make smarter decisions since it sees everything in one place. But if the central controller goes down, the whole system can be affected.

In distributed load balancing, there is no single controller. Instead, all servers work together and share information with each other. Each server can help decide where to send requests based on what it knows about the others. This makes the system more reliable — even if one server fails, the others can keep working. However, it can be more complex since each server needs to communicate and stay updated.



In distributed load balancing, there are two types: cooperative and non-cooperative.

  • Cooperative: Servers work together and share information. They help each other handle the load, leading to better decisions, but it needs more communication.

  • Non-Cooperative: Each server works on its own without sharing data. It’s simpler and faster but can cause uneven load because servers don’t know what others are doing.




Problems in Load Balancing (Simple Points):

  1. Not Fairly Shared Work – Some servers get too much work while others do very little.

  2. One Point Failure – If the main controller stops working, the whole system can go down.

  3. Slow Response – If a user is sent to a far or busy server, it can take longer to get a reply.

  4. Too Much Talking Between Servers – In some systems, servers talk a lot to each other, which can slow things down.

  5. Hard to Grow – When adding more servers or users, it gets harder to manage the system.

  6. User Gets Logged Out – If a user is sent to a different server each time, they might lose their session or data.

  7. Security Problems – Load balancers can be attacked by hackers if not protected properly.

Comments

Popular posts from this blog

Chap#10

Network topologies Definition: Network topologies define how nodes (processors/computers) are interconnected in parallel and distributed systems. The choice of topology affects performance, scalability, and cost. Key Metrics: Degree: Number of links per node. (Formula: deg = connections per node) Example: In a linear array, each node (except ends) has 2 links. Diameter: Longest shortest path between any two nodes. (Formula: diam = max distance) Example: Linear array with 8 nodes has diameter 7 (P₀ to P₇). Bisection Width: Minimum links to cut to split the network into two halves. (Formula: bw = min cuts) Example: Binary tree has bw=1 (cutting the root disconnects it).4 1. Linear Array Define : Nodes are connected one after another in a straight line. Each node (except the ends) connects to two neighbors one on the left and one on the right. Explanation : Simple to build and easy to understand, but not efficient for large networks. Long distance between farthest nodes makes comm...
Asymmetric-key algorithms are algorithms used in cryptography that use two different keys  a public key for encryption and a private key for decryption. These keys are mathematically related, but the private key cannot be easily derived from the public key. Types: RSA (Rivest–Shamir–Adleman): It uses large prime numbers to generate the key pair and supports both encryption and digital signatures DSA (Digital Signature Algorithm): DSA is primarily used for creating digital signatures, ensuring the authenticity. Symmetric-key algorithms are algorithms for cryptography that use the same cryptographic keys for both encryption of plaintext and decryption of ciphertext  Types: Stream Cipher:  Stream Cipher Converts the plain text into cipher text by taking 1 byte of plain text at a time. Block cipher: Converts the plain text into cipher text by taking plain text's block at a time DES? DES stands for Data Encryption Standard . It is a symmetric-key algorithm used to enc...

Ai Mental Health & Cyber Safety Presentation

Module A - The Normalization Engine Linguistic Challenge: Roman Urdu lacks standardized orthography (e.g., "kesa" vs "kaisa"), creating orthographic "noise" that significantly degrades the accuracy of downstream AI models. Technical Role: Acts as a Sequence-to-Sequence (Seq2Seq) transliteration and lexical normalization layer to standardize inputs before analysis. Model: A specialized transformer architecture, specifically m2m100 fine-tuned on parallel corpora or UrduParaphraseBERT. Primary Dataset: Roman-Urdu-Parl (RUP). A large-scale parallel corpus of 6.37 million sentence pairs designed to support machine transliteration and word embedding training. Link: https://arxiv.org/abs/2503.21530 Outcome: Reduces orthographic noise by achieving up to 97.44% Char-BLEU accuracy for Roman-Urdu to Urdu conversion, ensuring Module B receives high-quality "clean" data for risk analysis. Module B - Risk Stratification (BERT) Heading: The "Safety ...