swap
与要装的Virtual Machine数量有关,544M可支持32个Partition,如果要修改分区大小,只能reinstall,一般在生产环境推荐1.6G.
RAM allocated to service console
最大是 800 MB,1.6 G 就是 800 X 2
因为:The swap partition allows ESX Server and third
�\
party add
�\
ons to use disk space when more memory is needed than the physical RAM allows. (ESX Server
内存一般需要 272MB, 最大 800MB,应当根据 ESX Server 究竟要用多大的物理内存和ESX Server 上运行的应用类型 �C 即虚拟机所使用内存的机制决定)
Note: The ESX Server swap partition is not to be confused with virtual machine swap space. See the Resource Management Guide for a discussion of configuring a partition for virtual machine swap space.
The memory space overhead has two components:
! A fixed system
�\
wide overhead for the service console and the VMkernel.
! Additional overhead for each virtual machine.
For ESX Server 3.0, the service console typically uses 272MB and the VMkernel uses a smaller amount of memory. The amount depends on the number and size of the device drivers that are being used. See Viewing Host Resource Information on page 13 for information on how to determine the available memory for a host.
Memory Performance Best Practices
There are two kinds of memory related overhead that are incurred by ESX Server virtual machines: the additional time to access memory within a virtual machine and the extra memory needed by ESX Server for its own code and data structures.
In ESX, the VMkernel manages all machine memory except for the memory allocated to the service console. The guest operating system running inside a virtual machine translates guest virtual memory addresses to guest physical memory addresses. The virtualization layer then translates guest physical memory addresses to physical memory addresses on the underlying machine. The virtualization layer does this by intercepting guest operating system instructions to manipulate guest address mappings. It is important to note that the mappings from guest physical memory addresses to machine memory addresses are used directly by the processor's paging hardware so that there is no overhead for each memory access.
The memory overhead is comprised of two components: a fixed system-wide overhead for the service console and the VMkernel, and an additional overhead for each virtual machine. For ESX Server 3.0, the service console typically uses 272MB and the VMkernel uses a smaller amount of memory. Overhead memory includes space reserved for the virtual machine frame buffer and various virtualization data structures. Overhead memory depends on the number of virtual CPUs, the configured memory for the guest operating system, and on whether you are using a 32-bit or 64-bit guest operating system.
The following table gives examples of per virtual machine memory overhead
estimations:
Virtual CPUs
|
Memory (MB)
|
Overhead for a 32-bit virtual machine (MB)
|
Overhead for a 64-bit virtual machine (MB)
|
1
|
1024
|
84
|
180
|
1
|
8192
|
139
|
236
|
1
|
16384
|
203
|
300
|
2
|
1024
|
101
|
300
|
2
|
8192
|
221
|
413
|
2
|
16384
|
349
|
541
|
4
|
1024
|
141
|
523
|
4
|
8192
|
222
|
605
|
4
|
16384
|
350
|
734
|
The VMkernel reclaims memory by ballooning and swapping.
VMware recommends the following memory configurations and practices for optimal performance:
n
Avoid high memory overcomittment. Make sure the host has more memory than
the total amount of memory that will be used by ESX plus the sum of the working set sizes that will be used by all the virtual machines.
n
Carefully select the amount of virtual memory you allocate to your virtual machines to allow enough memory to hold the working set of applications you willrun in the virtual machine.
n
If possible, use less than 896MB of guest physical memory on Linux virtual machines. Linux uses different techniques to map memory in the kernel if the amount of physical memory is greater than 896MB. These techniques impose additional overhead on the virtual machine monitor and can result in slightly lowered performance.
n
Due to page sharing and other techniques, ESX Server can be overcommitted on memory and still not swap. However, if the over-commitment is large and ESX is swapping, performance in the virtual machines is significantly reduced.
n
If you choose to overcommit memory with ESX Server, you need to be sure you have sufficient swap space on your ESX Server. ESX server creates a swap file per virtual machine that is equal in size to the difference between the virtual machine's configured memory size and its reservation. This swap file is created at power on, so there are no performance implications in its creation. This swap space must be greater than or equal to the difference between the virtual machine's configured memory size and its reservation.
NOTE The reservation is a guaranteed lower bound on the amount of memory that the host reserves for the virtual machine. This can be configured through Virtual Infrastructure client in the Memory resource settings for a virtual machine.
n
If swapping cannot be avoided, for better performance ensure that the virtual machine’s swap file is placed on a high speed/bandwidth storage system. By default, a virtual machine’s swap file is created in the same location where the virtual machine is located. This can be changed by setting the sched.swap.dir option (in the VI client, Edit Settings > Options > Advanced > Configuration Parameters) to the appropriate location path.