Skip to main content

Server

1. Server​

A server is a computer whose primary responsibility is to respond to requests.

Key Points​

  • Servers receive requests and send responses.
  • Modern applications rarely run on a single server.
  • Production environments use multiple servers for:
    • High availability​

      In case one server fails, another can take over.

    • Failover​

      If a server goes down, traffic is rerouted to another server

    • Load balancing​

      Distributing traffic across multiple servers to prevent overload

    • Zero-downtime deployments (e.g., blue/green deployments)​

      Deploying new versions of an application without taking the system offline.

Example​

User -> Server -> Response

A server's job is simple: listen for requests and respond to them.

2. Cloud computing​

Cloud computing is the idea of renting computing resources from large data centers instead of maintaining your own physical servers.

Traditional Approach​

  • Buy physical servers
  • Maintain hardware
  • Hire system administrators
  • Handle power, cooling, and networking

Cloud Approach​

  • Rent resources on demand
  • Pay monthly or based on usage
  • Scale up or down easily
  • AWS (Example: EC2, S3, Lambda)
  • DigitalOcean (Example: Droplets)
  • Microsoft Azure (Example: Virtual Machines, App Service)
  • Google Cloud Platform (GCP) (Example: Compute Engine, Cloud Storage)

Key Idea​

Cloud Computing = Renting someone else's servers.

Cloud providers use massive server farms around the world and allow developers to deploy applications without managing physical infrastructure.

3. VPS (Virtual Private Server)​

A VPS is a virtual server created through virtualization technology.

How It Works​

Physical Machine (32 Cores)
↓
Virtualization
↓
32 Virtual Servers

Instead of renting an entire physical machine, you can rent:

  • 1 CPU Core
  • 2 CPU Cores
  • 4 CPU Cores
  • Custom amounts of RAM and storage

Advantages of a VPS​

  • Full control over the operating system
  • Install any software you want
  • Configure your environment freely
  • Cost-effective
  • Great for learning deployment and DevOps

Why Developers Love VPS​

A VPS is a blank canvas.

You can turn it into:

  • A Node.js server
  • A React application host
  • A PostgreSQL database server
  • A personal website
  • An AI API server
  • A Docker host

Common VPS Providers​

  • DigitalOcean
  • Linode
  • Vultr
  • Hetzner
  • AWS EC2

4. Summary & Big Picture​

Laptop
↓
Build Application
↓
Server
↓
Cloud Computing
↓
VPS
↓
Ubuntu + SSH
↓
Deploy Application
↓
Users can access it from anywhere in the world

We build applications on our laptops, deploy them to servers in the cloud, and users access them from anywhere in the world.

The difference between Cloud Computing and VPS is that Cloud Computing is a broad concept of renting computing resources, while a VPS is a specific type of virtual server that you can rent and control.