Using the VMware paravirtual SCSI controller to boot a Debian VM
Jun 28, 2009 Blogs
I’ve been optimizing my hosted environment for the last couple of days now. Besides upgrading the hard- and software of the physical server (Virtual Lifestyle running on ESX 4!), I’ve been optimizing the Guest OS of the VM running this website. After doing the usual stuff (like running “aptitude update” and “aptitude full-upgrade”), I set my sights on optimizing the virtual hardware of this VM.
Two major improvements were to be made:
- Upgrade the virtual ethernet adapter to VMXnet3
- Upgrade the virtual SCSI adapter to pvSCSI
Using VMXnet3
Upgrading the virtual ethernet adapter was easy enough:
- Shutdown VM
- Remove the VM from the (ESX/vCenter) inventory
- add the following line to the vm.vmx file
ethernet0.virtualDev=vmxnet3
- Add the VM to the inventory
- Start the VM
Using the Paravirtualized SCSI controller for the bootdisk
This one was a lot tougher to beat, mainly because I want pvSCSI on the bootdisk! First, I need to read up on the subject:
- What’s the deal with the new PVSCSI drivers?
- vSphere Virtual Machine Upgrade Process
- Update on the I/O vSphere performance test
- How to Add VMware Paravirtual SCSI (PVSCSI) adapters.
- Installing and using pvscsi in Red Hat and CentOS 5.3 under vSphere 4
- Using pvscsi in Linux – Update
With the newly gained knowledge, I knew I had to (roughly) do the following
- Upgrade VMware Tools to the latest and greatest
- Check if the kernel module is running (lsmod | grep pvscsi)
- Shutdown VM
- Add a second harddisk to scsi 1:0 (thus adding a new adapter)
- Change the adapter type to “paravirtual”
- Boot up the VM
- Move the current initrd file to a backuplocation
mv /boot/initrd.img-2.6.26-2-686 initrd.img-2.6.26-2-686.bck
- Add the pvscsi module to /etc/initramfs-tools/modules
- Run update-initramfs in verbose mode to create a new initrd and check if the pvscsi module is actually included:
update-initramfs -k `uname -r` -c -v | grep pvscsi
This should create a new initrd in /boot with the same name as the current initrd.img file. Please do doublecheck that, as the system will not boot if the name of initrd has changed.
- Shutdown VM
- Remove second hard disk
- Change adapter type for the bootdisk to “paravirtual”
- Boot up VM!




July 18th, 2009 at 6:27
[...] I just saw this URL for all you Debian users out there….you both know who you are !! http://www.virtuallifestyle.nl/2009/06/using-the-vmware-paravirtual-scsi-controller-to-boot-a-debian... [...]
December 5th, 2009 at 21:53
[...] Paravirtual SCSI devices – recently updated to allow booting, can allow higher-performance (greater throughput and lower CPU utilization) than the standard virtual SCSI adapter – especially in SAN environments where I/O-intensive applications are used. Currently supported in Windows Server 2003/2008 and Red Hat Linux 5 – although any version of Linux could be modified to support PVSCSI. [...]
October 14th, 2010 at 12:43
It works on my configuration (esx 4.1, ubuntu 10.10, latest tools)
a lil note, module name is now “vmw_pvscsi”
bye
December 30th, 2010 at 20:55
Thanks so much for sharing this info! I was struggling trying to get Ubuntu 8.04 VM converted to using PVSCSI and this did the trick. Much obliged!!!
Wes