Openvz - a quick introduction

2,141 views

Published on

A quick introduction to OpenVZ, a virtualization platform for Linux that works like FreeBSD jails - it segments a system into different partitions, all running LInux. Each virtual system, container, can run different Linux distributions.

Published in: Technology
0 Comments
5 Likes
Statistics
Notes
  • Be the first to comment

No Downloads
Views
Total views
2,141
On SlideShare
0
From Embeds
0
Number of Embeds
10
Actions
Shares
0
Downloads
0
Comments
0
Likes
5
Embeds 0
No embeds

No notes for slide
  • \n
  • \n
  • \n
  • \n
  • \n
  • \n
  • \n
  • \n
  • \n
  • \n
  • \n
  • \n
  • \n
  • \n
  • \n
  • Openvz - a quick introduction

    1. 1. Introduction to OpenVZ oej@edvina.net Olle E.oej@edvina.net Johansson * oej@edvina.net * Twitter oej © Copyright Edvina AB, Sollentuna, Sweden 2012. All rights reserved.
    2. 2. OpenVZ• Virtualization software by Parallells, inc. Base for their commercial Virtuozzo platform• Integrated with the virtualization support in the kernel - lvc• Segmentation, not full virtualization• Regardless, has cool features Introduction to OpenVZ
    3. 3. Cool features• Migration of running system• Backup with just a few secs stop time• Very simple - shared filesystem in the host system Introduction to OpenVZ
    4. 4. Basics Containers share the same kernel. Only Linux is supported - but you can run Kernel a different distribution in Container 1 a container. OpenVZ The host system Containers get allocated a fewruns a full Linux with a Container 2 resources - network, CPU, standard kernel with memory, disk. openvz extensions. Introduction to OpenVZ
    5. 5. The container is a full Linux system• The container is a full Linux system • It has network interfaces (if configured) • It has a separate user account database (/etc/passwd) • It needs patching and updates like any other system Introduction to OpenVZ
    6. 6. The Kernel• The kernel is managed as an package for the distro you are using.• For Centos, you add a new yum repository and install the kernel• Reboot and you have OpenVZ support• Now install the tools - vzsplit, vzctl and vzlist Introduction to OpenVZ
    7. 7. vzctl• Used to manage containers • Create new container • Start container • Stop container • Change attributes (name, IP address, various limits, properties) Introduction to OpenVZ
    8. 8. vzlist• Simply list containers running in a system• Lists all container IDs Introduction to OpenVZ
    9. 9. vzsplit• Used to get settings for vzctl (or the .conf files)• Takes all resources in a server and divides them between a specific number of containers Introduction to OpenVZ
    10. 10. Beancounters• Counters that document use• Also document when a resource limit is exceeded• cat /proc/user_beancounters• Used to design system and manage issues • Watch the failcnt column! Introduction to OpenVZ
    11. 11. Networking• Ethernet interface via nat or bridge• The bridge interface enables DHCP and other broadcast /multicast technologies• IPv4 and IPv6 support• Firewall with IPtables in container or outside in host system (on the bridge)• Network traffic can be managed Introduction to OpenVZ
    12. 12. Script hooks• There are hooks for scripts you can run when starting and stopping containers• These can be used to mount disk drives into container Introduction to OpenVZ
    13. 13. Configuration• Configuration file in /etc/vz/vz.conf• Configuration for containers in /etc/vz/ conf Introduction to OpenVZ
    14. 14. Advanced features• Live migration of containers between systems• Backup of running system• Remote management with libvirt Introduction to OpenVZ
    15. 15. References• www.openvz.org • Documentation • Wiki full with information, howto’s and documentation • Downloadable templates for containers - Centos, Debian, Ubuntu and other distributions Introduction to OpenVZ

    ×