Virtuozzo SWsoft OpenVZ Betriebsanweisung

Stöbern Sie online oder laden Sie Betriebsanweisung nach Software Virtuozzo SWsoft OpenVZ herunter. Virtuozzo SWsoft OpenVZ User`s guide Benutzerhandbuch

  • Herunterladen
  • Zu meinen Handbüchern hinzufügen
  • Drucken
  • Seite
    / 119
  • Inhaltsverzeichnis
  • FEHLERBEHEBUNG
  • LESEZEICHEN
  • Bewertet. / 5. Basierend auf Kundenbewertungen

Inhaltsverzeichnis

Seite 1 - User's Guide

SWsoft, Inc. OpenVZ User's Guide Version 2.7.0-8 © 2005

Seite 2

Preface 10 General Conventions Be aware of the following conventions used in this book.  Chapters in this guide are divided into sections, which

Seite 3 - Contents

Reference 100 vzctl exec, vzctl exec2, and vzctl enter These commands are used to run arbitrary commands inside a Virtual Private Server being auth

Seite 4

Reference 101 -o parameter[.specifier] This option is used to display only particular information about the VPSs. The parameters and their specifie

Seite 5

Reference 102 kmemsize .m, .b, .l, .f KMEMSIZE Size of unswappable kernel memory (in bytes), allocated for internal kernel structures of the proces

Seite 6 - Table of Figures

Reference 103 numpty .m, .b, .l, .f NPTY Number of pseudo-terminals. For example, ssh session, screen, xterm application consumes pseudo-terminal

Seite 7 - Preface

Reference 104 Allowed CPU power. This is a positive integer number, which determines the minimal guaranteed share of the CPU the Virtual Private Se

Seite 8 - Documentation Conventions

Reference 105 OpenVZ quota works on a file system sub-tree or area. If this area has additional file systems mounted to its subdirectories quota wi

Seite 9 - Typographical Conventions

Reference 106 -e, --block-exptime time Required. Expiration time for excess of the block soft limit. Time can be specified in two formats:  dd:h

Seite 10 - Feedback

Reference 107 vzquota on and vzquota off These commands are used to turn quota on and off. Their syntax is as follows: vzquota [options] on vpsid [

Seite 11 - OpenVZ Philosophy

Reference 108 -b, --block-softlimit num -B, --block-hardlimit num -e, --block-exptime time -i, --inode-softlimit num -I, --inode-hardlimit num -n,

Seite 12 - OpenVZ Applications

Reference 109 vzquota stat and vzquota show These commands are used for querying quota statistics. The syntax is as below: vzquota [options] show v

Seite 13 - Templates

11 C HAPTER 2 OpenVZ Philosophy In This Chapter About OpenVZ Software ...

Seite 14 - Resource Management

Reference 110 Template Management Utilities A template is basically a set of packages from some Linux distribution used to populate a VPS. An OS te

Seite 15 - Operation

Reference 111 vzpkgcache This utility creates/updates template caches for OS templates. You should run this utility before you can use a newly inst

Seite 16 - OpenVZ Philosophy 16

Reference 112 Supplementary Tools vzdqcheck This utility counts inodes and disk space used using the same algorithm as OpenVZ quota. It has the fol

Seite 17 - Understanding Templates

Reference 113 Quotas must be turned off when the vzdqload utility is working. Mind that only 2nd-level disk quotas are handled by the utilities. v

Seite 18 - OpenVZ Configuration

Reference 114 vzsplit This utility is used to generate a sample VPS configuration file with a set of system resource control parameters. The syntax

Seite 19 - Considerations

Glossary 115 Glossary Hardware Node (or Node) is a computer where OpenVZ is installed for hosting Virtual Private Servers. HN is an abbreviation of

Seite 20 - Installation Requirements

Glossary 116 VPS is an abbreviation of Virtual Private Server. VENET device is a virtual networking device, a gateway from a VPS to the external ne

Seite 21 - Software Compatibility

117 Index Failure to Start VPS • 78 A Feedback • 10 Finding Kernel Function That Caused D Process State • 77 About OpenVZ Software • 11 About This

Seite 22 - Network Requirements

Index 118 Supplementary Tools • 112 Matrix of OpenVZ Command Line Utilities • 91 System Requirements • 20 Matrix of OpenVZ Configuration Files • 81

Seite 23 - Operating System on Hardware

Index 119 W What are Disk Quotas? • 48 What are Resource Control Parameters? • 46 What is OpenVZ • 11 Who Should Read This Guide • 7

Seite 24 - Disk Partitioning

OpenVZ Philosophy 12 OpenVZ Applications OpenVZ provides a comprehensive solution for Hosting Service Providers allowing them to:  Have hundreds

Seite 25

OpenVZ Philosophy 13 OS Virtualization From the point of view of applications and Virtual Private Server users, each VPS is an independent system.

Seite 26 - Finishing OS Installation

OpenVZ Philosophy 14 Resource Management OpenVZ Resource Management controls the amount of resources available to Virtual Private Servers. The con

Seite 27 - Installing OpenVZ Software

OpenVZ Philosophy 15 Main Principles of OpenVZ Operation Basics of OpenVZ Technology In this section we will try to let you form a more or less pr

Seite 28

OpenVZ Philosophy 16 OpenVZ is installed in such a way that you will be able to boot your computer either with OpenVZ support or without it. This

Seite 29 - Installing OS Templates

OpenVZ Philosophy 17 Understanding Templates A template is a VPS building block. An OS template is a set of packages needed to operate a VPS. Temp

Seite 30

OpenVZ Philosophy 18 Understanding Licenses The OpenVZ software consists of the OpenVZ kernel and user-level tools, which are licensed by means of

Seite 31 - Virtual Private Server

OpenVZ Philosophy 19 Hardware Node Availability Considerations Hardware Node availability is more critical than the availability of a typical PC s

Seite 32 - VPS not found

ISBN: N/A SWsoft Inc 13755 Sunrise Valley Drive Suite 325 Herndon, VA 20171 USA Tel: +1 (703) 815 5670 Fax: +1 (703) 815 5675 Copyright © 2005 by SWs

Seite 33 - Choosing OS Template

20 C HAPTER 3 Installation and Preliminary Operations The current chapter provides exhaustive information on the process of installing and deployin

Seite 34 - Setting Startup Parameters

Installation and Preliminary Operations 21 Hardware Compatibility The Hardware Node requirements for the standard 32-bit edition of OpenVZ are the

Seite 35 - Setting Network Parameters

Installation and Preliminary Operations 22 Network Requirements The network pre-requisites enlisted in this subsection will help you avoid delays

Seite 36 - # vzctl start 101

Installation and Preliminary Operations 23 Installing and Configuring Host Operating System on Hardware Node This section explains how to install

Seite 37

Installation and Preliminary Operations 24 Disk Partitioning On the Disk Partitioning Setup screen, select Manual partition with Disk Druid. Do no

Seite 38

Installation and Preliminary Operations 25 It is suggested to use the ext3 file system for the /vz partition. This partition is used for holding a

Seite 39

Installation and Preliminary Operations 26 Finishing OS Installation After the proper partitioning of your hard drive(s), proceed in accordance wi

Seite 40

Installation and Preliminary Operations 27 Installing OpenVZ Software Downloading and Installing OpenVZ Kernel First of all, you should download t

Seite 41 - Private Server

Installation and Preliminary Operations 28 # On Hardware Node we generally need # packet forwarding enabled and proxy arp disabled net.ipv4.ip_for

Seite 42 - Managing Templates

Installation and Preliminary Operations 29 Downloading and Installing OpenVZ Packages After you have successfully installed and booted the OpenVZ

Seite 43 - # vzpkgcache fedora-core-4

3 Contents Preface 7 About This Guide ...

Seite 44 - Listing Templates

Installation and Preliminary Operations 30 You can also use one of the already pre-cached OS templates available at http://openvz.org/download/tem

Seite 45 - Working with VPS

31 C HAPTER 4 Operations on Virtual Private Servers This chapter describes how to perform day-to-day operations on separate Virtual Private Servers

Seite 46 - Managing Resources

Operations on Virtual Private Servers 32 Choosing Virtual Private Server ID Every Virtual Private Server has a numeric ID, also known as VPS ID, a

Seite 47 - Managing Disk Quotas

Operations on Virtual Private Servers 33 Choosing OS Template Next, you shall decide on which OS template you want to base the new VPS. There migh

Seite 48 - Disk Quota Parameters

Operations on Virtual Private Servers 34 In principle, now you are ready to start your newly created Virtual Private Server. However, typically yo

Seite 49

Operations on Virtual Private Servers 35 Setting Network Parameters In order to be accessible from the network, a Virtual Private Server shall be

Seite 50

Operations on Virtual Private Servers 36 Setting root Password for VPS By default, the root account is locked in a newly created VPS, and you cann

Seite 51

Operations on Virtual Private Servers 37 Starting, Stopping, Restarting, and Querying Status of Virtual Private Server When a Virtual Private Serv

Seite 52

Operations on Virtual Private Servers 38 vzctl has a two-minute timeout for the VPS shutdown scripts to be executed. If the VPS is not stopped in

Seite 53 - Managing CPU Share

Operations on Virtual Private Servers 39 Listing Virtual Private Servers Very often you may want to get an overview of the Virtual Private Servers

Seite 54

Contents 4 Configuring Virtual Private Server...34 S

Seite 55 - Managing System Parameters

Operations on Virtual Private Servers 40 Deleting Virtual Private Server You can delete a Virtual Private Server that is not needed anymore with t

Seite 56

Operations on Virtual Private Servers 41 Running Commands in Virtual Private Server Usually, a Virtual Private Server administrator logs in to the

Seite 57

42 C HAPTER 5 Managing Templates A template is basically a set of packages from some Linux distribution used to populate a VPS. An OS template cons

Seite 58

Managing Templates 43  List of packages this template comprises  Locations of (network) package repositories  Scripts needed to be executed

Seite 59

Managing Templates 44 Listing Templates The vzpkgls utility allows you to list the templates installed on the Hardware Node. They may be already u

Seite 60 - Configuration

Managing Templates 45 Working with VPS If you need to update an already existing VPS with the newer packages available from distribution repositor

Seite 61

46 C HAPTER 6 Managing Resources The main goal of resource control in OpenVZ is to provide Service Level Management or Quality of Service (QoS) for

Seite 62

Managing Resources 47 System This group of parameters defines various aspects of using system memory, TCP sockets, IP packets and like parameters

Seite 63 - Advanced Tasks

Managing Resources 48 What are Disk Quotas? Disk quotas enable system administrators to control the size of Linux file systems by limiting the amo

Seite 64

Managing Resources 49 Turning On and Off Per-VPS Disk Quotas The parameter that defines whether to use first-level disk quotas is DISK_QUOTA in th

Seite 65

Contents 5 Reference 80 Configuring OpenVZ...

Seite 66

Managing Resources 50 Setting Up Per-VPS Disk Quota Parameters Three parameters determine how much disk space and inodes a Virtual Private Server

Seite 67

Managing Resources 51 Turning On and Off Second-Level Quotas for Virtual Private Server The parameter that controls the second-level disk quotas i

Seite 68

Managing Resources 52 Setting Up Second-Level Disk Quota Parameters In order to work with disk quotas inside a VPS, you should have standard quota

Seite 69 - Loading iptables Modules

Managing Resources 53 Checking Quota Status As the Hardware Node system administrator, you can check the quota status for any Virtual Private Serv

Seite 70

Managing Resources 54 cpuunitsThis is a positive integer number that determines the minimal guaranteed share of the CPU time the corresponding Vir

Seite 71 - Advanced Tasks 71

Managing Resources 55 Managing System Parameters The resources a Virtual Private Server may allocate are defined by the system resource control pa

Seite 72 - Troubleshooting

Managing Resources 56 tcprcvbufThe total size of receive buffers for TCP sockets, i.e. the amount of kernel memory allocated for the data received

Seite 73 - General Considerations

Managing Resources 57 Monitoring System Resources Consumption It is possible to check the system resource control parameters statistics from withi

Seite 74

Managing Resources 58 # for res in tcpsendbuf tcprcvbuf unixsockbuf sockrcvbuf kmemsize; \ do echo;echo "$res usage for all VEs, in MB:"

Seite 75 - Kernel Troubleshooting

Managing Resources 59 Monitoring Memory Consumption You can monitor a number of memory parameters for the whole Hardware Node and for particular V

Seite 76 - Saving Kernel Fault (OOPS)

6 Table of Figures Figure 1: OpenVZ Technology ...15

Seite 77 - Problems with VPS Management

Managing Resources 60 The union of RAM and swap space is the main computer resource determining the amount of memory available to applications. If

Seite 78 - Failure to Start VPS

Managing Resources 61 2 Using OpenVZ specialized utilities for preparing configuration files in their entirety. The tasks these utilities perform

Seite 79 - Problems with VPS Operation

Managing Resources 62 Validating Virtual Private Server Configuration The system resource control parameters have complex interdependencies. Viola

Seite 80 - Reference

63 C HAPTER 7 Advanced Tasks In This Chapter Determining VPS ID by Process ID...

Seite 81 - Configuring OpenVZ

Advanced Tasks 64 Determining VPS ID by Process ID Each process is identified by a unique PID (process identifier), which is the entry of that pro

Seite 82

Advanced Tasks 65 root@vps101's password: Last login: Mon Oct 28 23:25:58 2002 from 10.100.40.18 [root@vps101 root]# date Mon Oct 28 23:31:57

Seite 83

Advanced Tasks 66 Accessing Devices from Inside Virtual Private Server It is possible to grant a Virtual Private Server read, write, or read/write

Seite 84 - VPS Configuration File

Advanced Tasks 67 p primary partition (1-4) p Partition number (1-4): 2 First cylinder (256-2231, default 256): Using default value 256 Last

Seite 85

Advanced Tasks 68 Moving Network Adapter to Virtual Private Server By default, all the VPSs on a Node are connected among themselves and with the

Seite 86

Advanced Tasks 69 Enabling VPN for VPS Virtual Private Network (VPN) is a technology which allows you to establish a secure network connection eve

Seite 87 - Managing OpenVZ Scripts

7 C HAPTER 1 Preface In This Chapter About This Guide...

Seite 88 - OpenVZ Action Scripts

Advanced Tasks 70 Loading iptables Modules to Hardware Node To have certain iptables modules loaded on the Hardware Node startup, you should provi

Seite 89 - Reference 89

Advanced Tasks 71 Rebooting Virtual Private Server When you issue the reboot command at your Linux box console, the command makes the reboot syste

Seite 90

72 C HAPTER 8 Troubleshooting This chapter provides the information about those problems that may occur during your work with OpenVZ and suggests t

Seite 91

Troubleshooting 73 General Considerations The general issues to take into consideration when troubleshooting your OpenVZ system are listed below. Y

Seite 92

Troubleshooting 74 Nmap run completed -- 1 IP address (1 host up) scanned in 169 seconds to check if any ports are open that should normally b

Seite 93

Troubleshooting 75 Kernel Troubleshooting Using ALT+SYSRQ Keyboard Sequences Press ALT+SYSRQ+H (3 keys simultaneously) and check what's printe

Seite 94

Troubleshooting 76 Saving Kernel Fault (OOPS) You can use the following command to check for the kernel messages that should be decoded and reporte

Seite 95

Troubleshooting 77 Finding Kernel Function That Caused D Process State If there are too many processes in the D state and you can't find out w

Seite 96

Troubleshooting 78 Failure to Start VPS An attempt to start a Virtual Private Server fails. Solution 1 If there is a message on the system console:

Seite 97

Troubleshooting 79 Solution 2 Make sure the routing to the Virtual Private Server is properly configured. Virtual Private Servers can use the defau

Seite 98

Preface 8 Organization of This Guide Chapter 2, OpenVZ Philosophy, is a must-read chapter that helps you grasp the general principles of OpenVZ ope

Seite 99

80 C HAPTER 9 Reference In order to make OpenVZ successfully accomplish its tasks you need to understand how to configure OpenVZ correctly. This se

Seite 100

81 Configuring OpenVZ In order to make OpenVZ successfully accomplish its tasks you need to understand how to configure OpenVZ correctly. This chap

Seite 101

Reference 82 Global OpenVZ Configuration File OpenVZ keeps its system wide configuration parameters in the /etc/sysconfig/vz configuration file. Th

Seite 102

Reference 83 Disk quota parameters allow you to control the disk usage by the Virtual Private Servers: Parameter Description Default value DISK_Q

Seite 103

Reference 84 Supplementary parameters define other OpenVZ settings: Parameter Description Default value VZWDOGDefines whether the vzwdog module i

Seite 104

Reference 85 Resource management parameters control the amount of resources a VPS can consume. They are described in the Managing Resources chapter

Seite 105

Reference 86 AVNUMPROCNumber of processes expected to run in the Virtual Private Server on average. This is informational parameter used by utiliti

Seite 106

Reference 87 NUMFILENumber of files opened by all VPS processes. 512…8192NUMFLOCKNumber of file locks created by all VPS processes. 50…200 – 60…220

Seite 107

Reference 88 Overview Along with OpenVZ configuration files responsible for the OpenVZ system configuration, there are a number of OpenVZ scripts a

Seite 108

Reference 89 The normal order of executing action scripts is shown in the figure below. The mount and umount scripts run in the context of the Host

Seite 109

Preface 9 Typographical Conventions The following kinds of formatting in the text identify special information. Formatting convention Type of Infor

Seite 110

Reference 90 Action scripts are located in the same directory as VPS configuration files and have names like vpsid.action. The global scripts are n

Seite 111

91 OpenVZ Command Line Interface OpenVZ is shipped with a number of command line tools. This chapter documents the utilities, which are supported i

Seite 112 - Supplementary Tools

Reference 92 vzctl vzctl is the primary tool for Virtual Private Server management. To use it, you have to log in to the Hardware Node as the root

Seite 113

Reference 93 vzctl create This command is used to create a new Virtual Private Server. It has the following syntax: vzctl create vpsid [--ostemplat

Seite 114

Reference 94 vzctl destroy The syntax of this command is: vzctl destroy vpsid This command is used to delete a Virtual Private Server, which is no

Seite 115 - Glossary

Reference 95 You should use action scripts (mount/umount and start/stop) if you would like to carry out some actions upon VPS startup/shutdown. The

Seite 116 - Glossary 116

Reference 96 --noatime yes|no Sets the noatime flag (do not update inode access times) on the VPS file system. The default is yes for a Class 1 VPS

Seite 117

Reference 97 Resource management settings control the amount of resources a VPS can consume. If the setting has bar:lim after it than this setting

Seite 118 - Index 118

Reference 98 --othersockbuf bar:lim Total size in bytes of UNIX-domain socket buffers, UDP and other datagram protocol send buffers. --dgramrcvbuf

Seite 119 - Index 119

Reference 99 --diskspace bar:lim Total size of disk space consumed by VPS, in 1 Kb blocks. When the space used by a Virtual Private Server hits the

Kommentare zu diesen Handbüchern

Keine Kommentare