What is OpenVZ?
OpenVZ is server virtualization software provided by SWSoft, Inc. licensed under the GPL version 2. OpenVZ is the software that every system administrator requires. It allows you to host multiple Virtual Environments (Aka VE) on a single server. The only limitations are RAM and CPU.
OpenVZ is an operating system-level virtualization technology based on the Linux kernel and operating system. It allows a physical server to run multiple isolated operating system instances, known as Virtual Private Servers (VPS) or Virtual Environments (VE).
Unlike VMWare and Para virtualization technologies such as Xen, OpenVZ is more limited in that it requires both the host and guest OS to be Linux (although Linux distributions can be different in different VEs) under the same kernel. OpenVZ claims a true performance advantage. According to its website, there is only a 1-3% performance penalty for running OpenVZ compared to using a standalone server.
As OpenVZ employs a single kernel model, and is scalable as the 2.6 Linux kernels; in that it will support up to 64 CPUs and up to 64 GB of RAM. A single virtual environment can scale up to the whole physical box (known as a “heavy VPS”) i.e. use all the CPUs and the entire RAM.
OpenVZ is divided into a custom kernel and a number of user-level tools such as vzctl, vzstat etc. OpenVZ lacks some of the features of the commercial product Virtuozzo, such as the advanced vzfs file system, templating features, to save disk space, and additional user land tools and control panels (though third party ones have been written).
OpenVZ improves efficiency, flexibility and quality of service in the enterprise environment. Each Virtual Private Server is hardware independent and can be moved to another OpenVZ-based system in seconds over the network.
Some Important OpenVZ Commands:
1. vzlist -a : Shows list of all the VPS’s hosted on the Node.
2. vzctl start VPS_ID: To start the VPS.
3. vzctl stop VPS_ID : To stop (Shut Down) the VPS
4. vzctl status VPS_ID : To view the status of the particular VPS
5. vzctl stop VPS_ID -fast : to stop the VPS quickly and forcefully
6. vzctl enter VPS_ID : To enter in a particular VPS
1. vzctl set VPS_ID -hostname vps.domain.com -save: To set the Hostname of a VPS.
2. vzctl set VPS_ID -ipadd 184.108.40.206 -save : To add a new IP to the hosting VPS.
3. vzctl set VPS_ID -ipdel 220.127.116.11 -save : To delete the IP from VPS.
4. vzctl set VPS_ID -userpasswd root:new_password -save : to reset root password of a VPS.
5. vzctl set VPS_ID -nameserver 18.104.22.168 -save : To add the nameserver IP’s to the VPS.
6. vzctl exec VPS_ID command : To run any command on a VPS from Node.
7. vzyum VPS_ID install package_name : To install any package/Software on a VPS from Node.
Here VPS_ID refers to the ID of the Particular VPS.