I think my delay has been longer than yours, sorry...
In order to make Windows support virtio drivers, you have to add the drivers during OS
installation. By default, one should do it manually (adding the drivers from an external
device). But, during an unattend installation, you have mainly two options:
1) One way is to use DISM.exe (and other tools from Windows Automated Installation Kit) to
'inject' the drivers in the installation image (a .wim file stored in installation
2) You can place the driver somewhere else and point from the unattend file to that
location in order to load the driver during the installation.
I like the second one because you don't have to depend on additional Microsoft tools
and you can work with the original ISO, so it's friendlier on other environments like
Oz on Linux. One alternative to do that is as simple as add a folder named $OEM$
) in the
installation media, this folder allows you to place drivers, additional files, files for
customization (images, etc)...
So, I would like to add support for virtio as we commented in previous e-mails, and, as a
side effect, add support for adding an OEM folder to the installation media:
1) Regarding the virtio driver, I agree with you, it's better to have it as a
parameter, maybe something like "--use-virtio" ? "--force-virtio"? or
2) About the OEM folder, it should be copied during "modify_iso" method, do you
think is too Windows specific? or could be useful for Linux guests? I have doubts whether
in this case it could be better to have it as a parameter "--oem-folder
<path>" or as a field in TDL file "<OEMFolder/>"
What do you think?
I hope you find it useful. Let me know if you need further information...
From: Chris Lalancette [clalancette(a)gmail.com]
Sent: 10 November 2012 20:06
To: Luis Fernandez Alvarez
Subject: Re: [PATCH] Added basic support for Virtio in Windows guests in Oz.
Sorry for the long delay; I was away for most of the week.
So what you are trying to do here is to allow the user to optionally specify the
nicmodel and the diskbus in order to speed things up. For Linux guests we have typically
just changed the default as the distros gained support for virtio. Presumably that
won't happen with Windows, though, so I see the need for what you want to do here. I
have a question, and an idea to change this up.
The question is: what do you need to do in Windows in order to get this to work?
Presumably Windows doesn't have built-in virtio drivers, so how do you convince the
Windows installer to see your install disk? I see below that you mentioned you
"inject" them into the disk, can you describe that process in more detail?
As far as the patch is concerned, I have two issues (both solvable). The first is
that I would like to see this option available to all guests, not just Windows. That
would basically mean moving your code into oz/Guest.py, plus probably putting a little
glue around it. The second thing is that I'm not sure this should be in the
configuration file. While I haven't documented this, there are really 3 sources of
configuration in Oz:
1) The configuration file - these are global environmental options that tend to affect
2) The TDL - this is the configuration about what gets put *on* the diskimage
3) Command-line - these are per-install configuration options
Therefore, I think this would be a little more appropriate as a command-line option.
Could you look into that and see if you could do that?
I definitely appreciate the contribution, and I am certainly willing to listen to other
opinions, so if you disagree with the above let me know.
On Mon, Nov 5, 2012 at 3:08 AM, Luis Fernandez Alvarez
The Windows VirtIO Drivers allows Microsoft Windows guests to be
installed using virtio devices. In order to make Oz support this
case, it's proposed to modify the class Windows.py to get the
diskbus and nicmodel from the configuration file. The performance
boost installing Microsoft Windows guests is remarkable.
oz/Windows.py | 12 ++++++++++--
1 files changed, 10 insertions(+), 2 deletions(-)
diff --git a/oz/Windows.py b/oz/Windows.py
index ddc3e7f..ee4a266 100644
@@ -33,8 +33,16 @@ class Windows(oz.Guest.CDGuest):
Shared Windows base class.
def __init__(self, tdl, config, output_disk):
- oz.Guest.CDGuest.__init__(self, tdl, config, output_disk, "rtl8139",
- "localtime", "usb", None, True,
+ diskbus = oz.ozutil.config_get_key(config,
+ nicmodel = oz.ozutil.config_get_key(config,
+ oz.Guest.CDGuest.__init__(self, tdl, config, output_disk, nicmodel,
+ "localtime", "usb", diskbus, True,
if self.tdl.key is None:
raise oz.OzException.OzException("A key is required when installing