Openvz Command Line Reference
Total Page:16
File Type:pdf, Size:1020Kb
OpenVZ Command Line Reference December 20, 2016 Parallels IP Holdings GmbH Vordergasse 59 8200 Schaffhausen Switzerland Tel: + 41 52 632 0411 Fax: + 41 52 672 2010 http://www.virtuozzo.com Copyright © 1999-2016 Parallels IP Holdings GmbH and its affiliates. All rights reserved. This product is protected by United States and international copyright laws. The product’s underlying technology, patents, and trademarks are listed at http://www.virtuozzo.com/legal/. Microsoft, Windows, Windows Server, Windows NT, Windows Vista, and MS-DOS are registered trademarks of Microsoft Corporation. Apple, Mac, the Mac logo, Mac OS, iPad, iPhone, iPod touch, FaceTime HD camera and iSight are trademarks of Apple Inc., registered in the US and other countries. Linux is a registered trademark of Linus Torvalds. All other marks and names mentioned herein may be trademarks of their respective owners. Table of Contents 1. Introduction ........................................................................................................................................... 6 1.1. About OpenVZ ........................................................................................................................... 6 1.2. About This Guide ...................................................................................................................... 7 2. Managing OpenVZ ............................................................................................................................... 8 2.1. OpenVZ Configuration Files ...................................................................................................... 8 2.1.1. Global OpenVZ Configuration File ................................................................................. 8 2.1.2. Container Configuration File ......................................................................................... 11 2.1.2.1. Miscellaneous Parameters ................................................................................. 12 2.1.2.2. Resource Management Parameters .................................................................. 13 2.1.2.3. Networking Parameters ...................................................................................... 16 2.1.3. Linux Distribution Configuration Files ........................................................................... 17 2.1.4. Memory and IOPS Deduplication Configuration File .................................................... 19 2.1.5. Network Classes Definition File .................................................................................... 20 2.1.6. Kernel Parameters ........................................................................................................ 20 2.1.7. Offline Management Configuration Files ...................................................................... 21 2.1.8. vztt Configuration File ................................................................................................... 22 2.1.9. pcompact.conf ............................................................................................................... 22 2.2. OpenVZ Utilities ....................................................................................................................... 23 2.2.1. prlsrvctl .......................................................................................................................... 23 2.2.1.1. prlsrvctl info ........................................................................................................ 23 2.2.1.2. prlsrvctl net ......................................................................................................... 24 2.2.1.3. prlsrvctl problem-report ...................................................................................... 27 2.2.1.4. prlsrvctl set ......................................................................................................... 27 2.2.1.5. prlsrvctl shutdown .............................................................................................. 29 2.2.1.6. prlsrvctl usb ........................................................................................................ 30 2.2.1.7. prlsrvctl user list ................................................................................................. 31 2.2.1.8. prlsrvctl user set ................................................................................................ 31 2.2.1.9. prlsrvctl privnet ................................................................................................... 32 2.3. OpenVZ Updates ..................................................................................................................... 33 3. Managing Containers ......................................................................................................................... 34 3.1. Matrix of OpenVZ Command-Line Utilities .............................................................................. 34 3.2. prlctl ......................................................................................................................................... 34 3.2.1. prlctl console ................................................................................................................. 35 3.2.2. prlctl create ................................................................................................................... 36 3.2.3. prlctl delete ................................................................................................................... 36 3.2.4. prlctl exec, enter ........................................................................................................... 37 3.2.5. prlctl migrate ................................................................................................................. 37 3.2.6. prlctl mount, umount ..................................................................................................... 38 3.2.7. prlctl move .................................................................................................................... 38 3.2.8. prlctl problem-report ...................................................................................................... 39 3.2.9. prlctl register, unregister ............................................................................................... 39 3.2.10. prlctl reinstall ............................................................................................................... 40 3.2.11. prlctl set ...................................................................................................................... 41 3.2.11.1. General Options ............................................................................................... 41 3.2.11.2. Resource Management Options ...................................................................... 42 3.2.11.3. Network Options .............................................................................................. 44 3.2.11.4. Hard Disk Drive Management Options ............................................................ 46 3.2.12. prlctl snapshot, snapshot-list, snapshot-switch, snapshot-delete ............................... 48 3.2.13. prlctl start, stop, restart, status ................................................................................... 48 3.2.14. prlctl suspend, resume ............................................................................................... 50 3.2.15. prlctl list ....................................................................................................................... 50 3.2.15.1. prlctl list Output Parameters ............................................................................ 51 3.3. Migration Utilities ..................................................................................................................... 52 3.3.1. prlctl clone ..................................................................................................................... 52 3.4. EZ Template Management Utilities ......................................................................................... 52 3.4.1. vzpkg ............................................................................................................................. 52 3.4.2. vzpkg install template ................................................................................................... 53 3.4.3. vzpkg update template ................................................................................................. 54 3.4.4. vzpkg remove template ................................................................................................ 54 3.4.5. vzpkg list ....................................................................................................................... 55 3.4.6. vzpkg info ...................................................................................................................... 56 3.4.7. vzpkg status .................................................................................................................. 59 3.4.8. vzpkg install .................................................................................................................. 59 3.4.9. vzpkg update ................................................................................................................ 60 3.4.10. vzpkg remove ............................................................................................................. 61 3.4.11. vzpkg create cache ....................................................................................................