Vmware scsi controller type какой выбрать
Довольно часто на семинарах или при аудите существующей у заказчика виртуальной среды мне приходилось слышать упреки: «Виртуализация тормозит», «Мы попробовали перевести сервер в виртуальную среду, и он встал», «Виртуальные серверы работают медленнее физических». При этом девять из десяти таких проблем с «торможением» виртуальных серверов решались простой оптимизацией устройств в составе виртуальной машины.
Большое количество вопросов, как повысить быстродействие виртуальной среды, побудило меня к написанию небольшого FAQ по оптимизации виртуальных машин на основе VMware vSphere – платформы используемой большинством наших корпоративных клиентов. При этом хочется отметить, что для решений на основе Hyper-V и Xen Server корректный выбор устройств также способен ускорить работу виртуальных серверов.
FAQ по работе с виртуальными устройствами в среде VMware vSphere
Q: На что влияют типы устройств виртуальной машины?
A: Типы встроенных устройств влияют на алгоритм работы виртуальной машины с «железом», таким образом оказывая непосредственное влияние на быстродействие.
Q: Зачем VMware понадобилось закладывать в архитектуру уникальные виртуальные устройства вместо эмуляции обычных контроллеров?
A: Виртуальные устройства, не имеющие реальных аналогов, разработаны только с одной целью – снизить накладные расходы на виртуализацию. Только с ними можно добиться того, что быстродействие виртуальной машины практически не отличается от физического оригинала.
Q: Чем отличаются дисковые контроллеры?
A: Дисковые контроллеры влияют на алгоритм обработки SCSI команд. VMware Paravirtual оптимизирован под пакетную обработку команд, таким образом, при большом количестве операций ввода-вывода он заметно эффективнее LSI Logic контроллеров.
Q: Если VMware Paravirtual так хорош, почему он не используется по умолчанию?
A: Поскольку VMware Paravirtual не имеет реальных аналогов, он не поддерживается операционными системами напрямую. Следовательно, остальные контроллеры нужны исключительно для совместимости со старыми версиями гостевых операционных систем. Кроме того при небольшом количестве операций ввода-вывода он может быть менее эффективен чем LSI Logic SAS, что позволяет его рекомендовать для применения в качестве контроллера системного диска.
Q: Какие операционные системы поддерживают VMware Paravirtual?
A: Список ОС поддерживающих VMware Paravirtual приведен в таблице ниже.
Гостевая операционная система | VMware Paravirtual поддерживается в качестве диска с данными | VMware Paravirtual поддерживается в качестве загрузочного диска |
Windows Server 2008 R2 (64-bit only) | ESX/ESXi 4.0 Update 1, ESX/ESXi 4.1, ESXi 5.0 | ESX/ESXi 4.0 Update 1, ESX/ESXi 4.1, ESXi 5.0 |
Windows Server 2008 (32 and 64 bit) | ESX/ESXi 4.X, ESXi 5.0 | ESX/ESXi 4.0 Update 1, ESX/ESXi 4.1, ESXi 5.0 |
Windows Server 2003 (32 and 64 bit) | ESX/ESXi 4.x, ESXi 5.0 | ESX/ESXi 4.x, ESXi 5.0 |
Windows 7 (32 and 64 bit) | ESX/ESXi 4.1, ESXi 5.0 | ESX/ESXi 4.1, ESXi 5.0 |
Windows Vista (32 and 64 bit) | ESX/ESXi 4.1, ESXi 5.0 | ESX/ESXi 4.1, ESXi 5.0 |
Windows XP (32 and 64 bit) | ESX/ESXi 4.1, ESXi 5.0 | ESX/ESXi 4.1, ESXi 5.0 |
Red Hat Enterprise Linux (RHEL) 5 (32 and 64 bit) и выше | ESX/ESXi 4.X, ESXi 5.0 | Не поддерживается. |
RHEL 6 (32 and 64 bit) | ESX/ESXi 4.0 Update 2, ESX/ESXi 4.1, ESXi 5.0 | ESX/ESXi 4.0 Update 2, ESX/ESXi 4.1, ESXi 5.0 |
SUSE Linux Enterprise 11 SP1(32 and 64 bit) и выше | ESX/ESXi 4.0 Update 2, ESX/ESXi 4.1, ESXi 5.0 | ESX/ESXi 4.0 Update 2, ESX/ESXi 4.1, ESXi 5.0 |
Ubuntu 10.04 (32 and 64 bit) и выше | ESX/ESXi 4.0 Update 2, ESX/ESXi 4.1, ESXi 5.0 | ESX/ESXi 4.0 Update 2, ESX/ESXi 4.1, ESXi 5.0 |
Distros Linux 2.6.33 и выше | ESX/ESXi 4.1, ESXi 5.0 | ESX/ESXi 4.1, ESXi 5.0 |
Q: Какие дисковые контроллеры лучше использовать, если VMware Paravirtual не поддерживается?
A: Предпочитаемым контроллером является LSI Logic SAS. К сожалению, в виду огромного разнообразия поддерживаемых ОС привести их всех в рамках данного обзора не представляется возможным. Если даже LSI Logic SAS не поддерживается, то вынужденно придется использовать LSI Logic Parallel.
Q: Где взять драйверы для VMware Paravirtual?
A: При установке ОС драйверы можно поставить с виртуального флоппи-дисковода. Для выбора нужного образа следует указать в свойствах дисковода «Use existing floppy image in datastore». После следует указать нужный образ из расположенных в каталоге /vmimages/floppies. Также драйверы для несистемных дисков могут быть добавлены после установки ОС – для этого надо просто установить VMware Tools.
Q: Почему нельзя использовать в промышленной среде «тонкие» диски?
A: При каждой операции расширения тонкого диска значительно снижается быстродействие тома VMFS, на котором он расположен, а точно предсказать операции расширения нельзя.
Q: Какой сетевой контроллер наиболее эффективен?
A: Наиболее эффективным типом сетевого контроллера является VMXNET 3. По аналогии с VMware Paravirtual он позволяет снизить накладные расходы и повысить быстродействие подсистемы сетевого ввода-вывода.
Q: Зачем нужны сетевые контроллеры кроме VMXNET3?
A: Остальные сетевые контроллеры нужны исключительно для совместимости с ОС, не поддерживающими VMXNET3.
- 32- и 64-разрядные версии Microsoft Windows XP,7, 2003, 2003 R2, 2008, and 2008 R2 и выше;
- 32- и 64-разрядные версии Red Hat Enterprise Linux 5.0 и выше;
- 32- и 64-разрядные версии SUSE Linux Enterprise Server 10 и выше;
- 32- и 64-разрядные версии Asianux 3 и выше;
- 32- и 64-разрядные версии Debian 4 и выше;
- 32- и 64-разрядные версии Ubuntu 7.04 и выше;
- 32- и 64-разрядные версии Sun Solaris 10 U4 и выше.
Q: Где взять драйверы для VMXNET3?
A: Драйверы для VMXNET3 устанавливаются вместе с VMware Tools.
Q: Какие сетевые контроллеры лучше использовать, если VMXNET3 не поддерживается?
A: Рекомендуемым после VMXNET3 является E1000. VMXNET2 нужен для совместимости со старыми версиями ESX/ESXi, а не со старыми версиями гостевых ОС. Если даже E1000 не подошел, то следует использовать другие сетевые контроллеры, совместимые с конкретной ОС.
Q: Что делать, если курсор мыши в виртуальной среде двигается рывками?
A: В Windows 7 и Windows 2008 (и выше) следует вручную установить драйвер видеоадаптера. После установки VMware Tools драйвер видеоадаптера доступен в каталоге C:\Program Files\Common Files\VMware\drivers\wddm_video.
В VMware vSphere доступны четыре вида SCSI контроллеров:
Все они предоставляют разный уровень производительности и разную поддержку в гостевых ОС.
Самым производительным будет VMware Paravirtual (PVSCSI), но драйверов пока очень мало. LSI Logic Parallel и LSI Logic SAS предоставляют одинаковую производительность. BusLogic Parallel наиболее поддерживаемое устройство в гостевых операционных системах.
Итого, выбор очень прост:
- VMware Paravirtual (PVSCSI) если поддерживается гостевой ОС
- LSI Logic SAS если поддерживается гостевой ОС
- LSI Logic Parallel
- BusLogic Parallel если ничего более не работает.
Драйвера для VMware Paravirtual (PVSCSI) доступны для следующих операционных систем:
Guest operating system | Data Disk | Boot Disk |
Windows Server 2008 and higher | ESX 4.0 | ESX 4.0 U1 |
Windows Server 2003 | ESX 4.0 | ESX 4.0 U1 |
Red Hat Enterprise Linux (RHEL) 5 | ESX 4.0 | not supported |
RHEL 6 and higher | ESX 4.0 U2 | ESX 4.0 U2 |
SUSE Linux Enterprise 11 SP1 and higher | ESX 4.1 | ESX 4.1 |
Ubuntu 10.04 and higher | ESX 4.1 | ESX 4.1 |
Distros using Linux version 2.6.33 or later and that include the vmw_pvscsi driver | ESX 4.1 | ESX 4.1 |
Как видно, VMware увеличивает поддержку VMware Paravirtual (PVSCSI) в гостевых ОС.
В случае, если использование VMware Paravirtual (PVSCSI) невозможно, выбирайте LSI Logic SAS ради совместимости с будущими версиями.
В случае, если виртуальная машина уже установлена с другим типом SCSI контроллера, и хочется сменить его на более производительный, то рекомендую прочесть инструкцию по смене SCSI контроллера для Windows систем.
To access virtual disks, CD/DVD-ROM, and SCSI devices, a virtual machine uses storage controllers, which are added by default when you create the virtual machine. You can add additional controllers or change the controller type after virtual machine creation. You can make these changes while you are in the creation wizard. If you know about node behavior, controller limitations, and compatibility of different types of controllers before you change or add a controller, you can avoid potential boot problems.
How Storage Controller Technology Works
Storage controllers appear to a virtual machine as different types of SCSI controllers, including BusLogic Parallel, LSI Logic Parallel, LSI Logic SAS, and VMware Paravirtual SCSI. AHCI, SATA, and NVM Express (NVMe) controllers are also available.
NVMe is a standartized protocol designed specifically for high-performance multi-queue communication with NVM devices. ESXi supports the NVMe protocol to connect to local and networked storage devices. For more information, see the vSphere Storage documentation.
When you create a virtual machine, the default controller is optimized for best performance. The controller type depends on the guest operating system, the device type, and sometimes, the virtual machine's compatibility. For example, when you create virtual machines with Apple Mac OS X guests and ESXi 5.5 and later compatibility, the default controller type for both the hard disk and the CD/DVD drive is SATA. When you create virtual machines with Windows Vista and later guests, a SCSI controller is the default for the hard disk and a SATA controller is the default for the CD/DVD drive.
Each virtual machine can have a maximum of four SCSI controllers and four SATA controllers. The default SCSI or SATA controller is 0. When you create a virtual machine, the default hard disk is assigned to the default controller 0 at bus node (0:0).
When you add storage controllers, they are numbered sequentially 1, 2, and 3. If you add a hard disk, SCSI, or CD/DVD-ROM device to a virtual machine after virtual machine creation, the device is assigned to the first available virtual device node on the default controller, for example (0:1).
If you add a SCSI controller, you can reassign an existing or new hard disk or device to that controller. For example, you can assign the device to (1: z ), where 1 is SCSI controller 1 and z is a virtual device node from 0 to 15. For SCSI controllers, z cannot be 7. By default, the virtual SCSI controller is assigned to virtual device node ( z :7), so that device node is unavailable for hard disks or other devices.
If you add a SATA controller, you can reassign an existing or new hard disk or device to that controller. For example, you can assign the device to (1: z ), where 1 is SATA controller 1 and z is a virtual device node from 0 to 29. For SATA controllers, you can use device nodes 0 through 29, including 0:7.
Alternatively, each virtual machine can have a maximum of four NVMe controllers. You can reassign an existing or new hard disk or device to that controller. For example, you can assign the hard disk to ( x : z ), where x is NVMe controller and z is a virtual device node. x has values from 0 to 3, and z has values from 0 to 14.
Storage Controller Limitations
Storage controllers have the following requirements and limitations:
- LSI Logic SAS and VMware Paravirtual SCSI are available for virtual machines with ESXi 4.x and later compatibility.
- AHCI SATA is available only for virtual machines with ESXi 5.5 and later compatibility.
- NVMe is available only for virtual machines with ESXi 6.5 and later compatibility.
- BusLogic Parallel controllers do not support virtual machines with disks larger than 2TB.
- Disks on VMware Paravirtual SCSI controllers might not experience optimal performance if they have snapshots or if the hosts memory is overcommitted.
Caution: Changing the controller type after the guest operating system is installed will make the disk and any other devices connected to the adapter inaccessible. Before you change the controller type or add a new controller, make sure that the guest operating system installation media contains the necessary drivers. On Windows guest operating systems, the driver must be installed and configured as the boot driver.
How Storage Controller Technology Works
Storage controllers appear to a virtual machine as different types of SCSI controllers, including BusLogic Parallel, LSI Logic Parallel, LSI Logic SAS, and VMware Paravirtual SCSI. AHCI SATA controllers are also available.
When you create a virtual machine, the default controller is optimized for best performance. The controller type depends on the guest operating system, the device type, and in some cases, the virtual machine's compatibility. For example, when you create virtual machines with Apple Mac OS X guests and ESXi 5.5 and later compatibility, the default controller type for both the hard disk and the CD/DVD drive is SATA. When you create virtual machines with Windows Vista and later guests, a SCSI controller is the default for the hard disk and a SATA controller is the default for the CD/DVD drive.
Each virtual machine can have a maximum of four SCSI controllers and four SATA controllers. The default SCSI or SATA controller is 0. When you create a virtual machine, the default hard disk is assigned to the default controller 0 at bus node (0:0).
When you add storage controllers, they are numbered sequentially 1, 2, and 3. If you add a hard disk, SCSI, or CD/DVD-ROM device to a virtual machine after virtual machine creation, the device is assigned to the first available virtual device node on the default controller, for example (0:1).
If you add a SCSI controller, you can reassign an existing or new hard disk or device to that controller. For example, you can assign the device to (1: z ), where 1 is SCSI controller 1 and z is a virtual device node from 0 to 15. For SCSI controllers, z cannot be 7. By default, the virtual SCSI controller is assigned to virtual device node ( z :7), so that device node is unavailable for hard disks or other devices.
If you add a SATA controller, you can reassign an existing or new hard disk or device to that controller. For example, you can assign the device to (1: z ), where 1 is SATA controller 1 and z is a virtual device node from 0 to 29. For SATA controllers, you can use device nodes 0 through 29, including 0:7.
Storage Controller Compatibility
- If the virtual machine boots from LSI Logic SAS or VMware Paravirtual SCSI, and you add a disk that uses BusLogic, LSI Logic, or AHCI SATA controllers.
- If the virtual machine boots from AHCI SATA, and you add BusLogic Parallel or LSI Logic controllers.
Adding additional disks to virtual machines that use EFI firmware does not cause boot problems.
I wrote a blog article in Oct 2010 on this same topic that is still frequently referenced today so I figure it was due for an update.
So what should I choose as my vSCSI controller and what are the differences between them?
First, it’s important to remind everyone that when you select the Guest OS for a new virtual machine
this automatically makes a selection for which vSCSI controller to use based on what drivers are available in the OS distribution. So be sure to select the correct Guest OS to start in the right place.
Let’s look at the options available today:
- BusLogic – this was one of the first emulated vSCSI controllers available in the VMware platform. The earliest versions of Windows has this driver available by default which made it easy when installing that particular OS. It wasn’t however as performant as the LSI Logic driver since Windows’ driver was limited to a queue depth of 1, so often one would manually load the LSI Logic driver instead. While still available and used occasionally (Is anyone still running Win2K?), it should be considered legacy.
- LSI Logic Parallel (formerly knows as just LSI Logic) – this was the other emulated vSCSI controller available originally in the VMware platform. Most operating systems had a driver that supported a queue depth of 32 and it became a very common choice, if not the default.
- LSI Logic SAS – This is an evolution of the parallel driver to support a new future facing standard. It began to grown popularity when Microsoft required its use for MCSC within Windows 2008 or newer.
- VMware Paravirtual (aka PVSCSI) – this vSCSI controller is virtualization aware and was been designed to support very high throughput with minimal processing cost and is therefore the most efficient driver. In the past, there were issues if it was used with virtual machines that didn’t do a lot of IOPS, but that was resolved in vSphere 4.1.
Are there performance differences between them?
- PVSCSI and LSI Logic Parallel/SAS are essentially the same when it comes to overall performance capability. PVSCSI, however, is more efficient in the number of host compute cycles that are required to process the same number of IOPS. This means that if you have a very storage IO intensive virtual machine, this is the controller to choose to ensure you save as many cpu cycles as possible that can then be used by the application or host. Most modern operating systems that can drive high IO support one of these two controllers.
- Here’s a detailed whitepaper that takes a closer look at PVSCSI vs LSI Logic SAS for IOPS, Latency and Cost. While it does support that PVSCSI is more capable, keep in mind most customers are not producing 1 million IOPS so for real life the difference is negligible.
How many vSCSI adapters are supported per virtual machine?
- It’s also worth noting that you can configure a total of 4 vSCSI adapters per virtual machine. To provide the best performance, one should also distribute virtual disk across as many vSCSI adapters as possible. This configuration provides the capability to process more IO simultaneously and benefit from additional queues if necessary.
What about AHCI SATA?
- This is a new storage controller available with vSphere 5.5 and virtual hardware 10. It allows you to connect a large amount of storage to a virtual machine but it wasn’t designed to be as efficient as the PVSCSI or LSI Logic controllers and therefore should not be used with performance sensitive applications.
Let’ summarize this in a chart:
Mark Achtemichuk
Mark Achtemichuk currently works as a Staff 2 Engineer within VMware’s Engineering Services (VES) Performance team, focusing on education, benchmarking, collaterals and performance architectures. @vmMarkA is recognized as an industry expert…
To access virtual disks, CD/DVD-ROM, and SCSI devices, a virtual machine uses storage controllers, which are added by default when you create the virtual machine. You can add additional controllers or change the controller type after virtual machine creation. You can make these changes while you are in the creation wizard. If you know about node behavior, controller limitations, and compatibility of different types of controllers before you change or add a controller, you can avoid potential boot problems.
Storage Controller Limitations
Storage controllers have the following requirements and limitations:
- LSI Logic SAS and VMware Paravirtual SCSI are available for virtual machines with ESXi 4.x and later compatibility.
- AHCI SATA is available only for virtual machines with ESXi 5.5 and later compatibility.
- BusLogic Parallel controllers do not support virtual machines with disks larger than 2TB.
Caution: Changing the controller type after the guest operating system is installed will make the disk and any other devices connected to the adapter inaccessible. Before you change the controller type or add a new controller, make sure that the guest operating system installation media contains the necessary drivers. On Windows guest operating systems, the driver must be installed and configured as the boot driver.
Storage Controller Compatibility
- If the virtual machine boots from LSI Logic SAS or VMware Paravirtual SCSI, and you add a disk that uses BusLogic, LSI Logic, or AHCI SATA controllers.
- If the virtual machine boots from AHCI SATA, and you add BusLogic Parallel or LSI Logic controllers.
Adding additional disks to virtual machines that use EFI firmware does not cause boot problems.
Читайте также: