1. Traditional Deployment
- Overview: Applications ran on physical servers without resource boundaries, leading to allocation issues.
- Challenges:
- Resource competition: One application could dominate resources, causing others to underperform.
- Scaling issues: Running each app on a separate server was resource-intensive and costly.
- Solution: Virtualization and containerization emerged to address these limitations.
2. Virtualization
- Definition: Creation of virtual versions of OS, servers, storage, or network resources using software to simulate hardware.
- Benefits:
- Run multiple OS and apps on a single server.
- Improves resource utilization and scalability.
- Types:
- Network Virtualization: Divides network bandwidth into secure, assignable channels for improved speed, availability, and security.
- Storage Virtualization: Pools multiple storage devices into a single, centrally managed virtual device (e.g., in SANs).
- Benefits: Remote storage appears local, high availability, improved performance.
- Data Virtualization: Aggregates data from multiple sources into a single logical view without needing to know storage locations.
- Benefits: Abstracts technical details, enables data federation, single access point.
- Desktop Virtualization: Isolates desktop OS, allowing remote access (e.g., shared hosted desktops via Microsoft Remote Desktop Services).
- Application Virtualization: Runs apps separately from the accessing device, simplifying updates and patching.
- Hardware Virtualization: Creates virtual machines (VMs) that act like real computers with their own OS.
- Type 1 (Bare Metal) Hypervisor: Runs directly on hardware (e.g., VMware ESXi).
3. Microservices Architecture
- Definition: Architectural method using independently deployable services with their own logic and database.
- Characteristics:
- Each service focuses on a specific goal.
- Decouples business concerns into independent code bases.
- Aligns with DevOps for continuous delivery.
- Pros:
- Agility: Small teams deploy frequently.
- Flexible scaling: Add instances to handle load.
- Continuous deployment: Frequent, faster releases (e.g., 2-3 times/day).
- Maintainable/testable: Easy to update, isolate, and fix issues.
- Independent deployment: Deploy features without affecting others.
- Technology flexibility: Teams choose their tools.
- High reliability: Service failures don’t crash the entire app.
- Cons:
- Development sprawl: Increased complexity from multiple services.
- Infrastructure costs: Each service requires its own testing, hosting, and monitoring.
- Organizational overhead: More coordination needed.
- Debugging challenges: Distributed logs and processes complicate troubleshooting.
- Lack of standardization: Diverse languages and logging standards.
- Unclear ownership: Hard to track services and support contacts.
4. Containerization
- Definition: Packaging software code with OS libraries and dependencies into a lightweight, portable executable (container).
- Comparison with VMs:
- VMs: Hardware-level virtualization, heavyweight, slow provisioning, fully isolated, separate OS per VM, boots in minutes.
- Containers: OS-level virtualization, lightweight, fast provisioning, process-level isolation, share OS, boots in seconds.
- Benefits:
- Portability: Runs consistently across platforms/clouds.
- Agility: Supports DevOps with tools like Docker Engine.
- Speed: Lightweight, no OS boot time, faster start-up.
- Fault Isolation: One container’s failure doesn’t affect others.
- Efficiency: Shares OS kernel, smaller size, runs more containers per server.
- Ease of Management: Orchestration platforms (e.g., Kubernetes) automate scaling, updates, and monitoring.
- Security: Isolates apps, uses OS security (e.g., SELinux) to prevent malicious code spread.
5. Docker
- Definition: Open-source platform for building, deploying, and managing containers.
- Why Docker?:
- Simplifies creating deployable app packages.
- Ensures consistent environments (on-prem or cloud).
- Lightweight compared to VMs.