Differences

This shows you the differences between two versions of the page.

Link to this comparison view

Both sides previous revisionPrevious revision
Next revision
Previous revision
fuss:libvirt [2019/06/10 20:27] – [Passing Plan 9 Permissions] officefuss:libvirt [2024/08/03 05:38] (current) – [Enable Shutdown of Windows Guests] office
Line 365: Line 365:
  
   * Using the group policy editor (run ''gpedit.msc'') make sure that ''Computer Configuration->Windows Settings->Security Settings->Local Policies->Security Options->Shutdown: Allow system to be shut down without having to log on'' is set to ''Enabled''.   * Using the group policy editor (run ''gpedit.msc'') make sure that ''Computer Configuration->Windows Settings->Security Settings->Local Policies->Security Options->Shutdown: Allow system to be shut down without having to log on'' is set to ''Enabled''.
-  * Using the registry editor (run ''regedit'') make sure that the DWORD located at ''HKEY_LOCAL_MACHINE->SOFTWARE->Microsoft->Windows NT->CurrentVersion->Windows->ShutdownWarningDialogTimeout'' is set to anything else other than ''0xffffffff'' (for example ''1''). In case the DWORD does not exist, create it and set it to a positive decimal.+ 
 +  * Using the registry editor (run ''regedit'') make sure that the DWORD located at ''HKEY_LOCAL_MACHINE->SOFTWARE->Microsoft->Windows NT->CurrentVersion->Windows->ShutdownWarningDialogTimeout'' is set to anything else other than ''0xffffffff'' (for example ''1''). In case the DWORD does not exist, create it and set it to a positive decimal. Or just import the following registry file: 
 + 
 +<code> 
 +Windows Registry Editor Version 5.00 
 + 
 +[HKEY_LOCAL_MACHINE\SOFTWARE\Microsoft\Windows NT\CurrentVersion\Windows] 
 +"ShutdownWarningDialogTimeout"=dword:00000001 
 +</code>
  
 You can now issue: ''shutdown windows.guest'' to shutdown a Windows domain named ''windows.guest''. You can now issue: ''shutdown windows.guest'' to shutdown a Windows domain named ''windows.guest''.
Line 389: Line 397:
 ====== The VirtIO Pseudo-Random Generator ====== ====== The VirtIO Pseudo-Random Generator ======
  
-Guest machines can be configured to use the host random hardware for pseudo-random number generation. In order to do this you will either need ''egd'' or ''haveged'' to generate more entropy. +Guest machines can be configured to use the host random hardware for pseudo-random number generation. First, edit the virtual machine domain configuration and add the following configuration lines:
- +
-===== Haveged ===== +
- +
-Using ''haveged'' you just need to install the daemon: +
-<code bash> +
-aptitude install haveged +
-</code> +
- +
-and then add to the guest machine the configuration lines:+
 <code xml> <code xml>
     <rng model='virtio'>     <rng model='virtio'>
Line 405: Line 404:
 </code> </code>
  
-and restart the guest.+Next, install the ''rng-tools'' package: 
 +<code bash> 
 +apt-get install rng-tools 
 +</code> 
 + 
 +and start ''rngd'': 
 +<code bash> 
 +systemctl restart rng-tools 
 +</code> 
  
 ===== EGD ===== ===== EGD =====
Line 685: Line 693:
  
 without containing the ''vnet'' substring. without containing the ''vnet'' substring.
 +
 +====== Strange Windows Install Errors ======
 +
 +One easy workaround for a BSoD on a fresh Windows install complaining about ''IRQL_NOT_LESS_OR_EQUAL'' or reaching a fatal error is to increase the RAM available above $3GiB$.
 +
 +====== Passing an USB Device to the Guest ======
 +
 +The USB device has to be identified first by vendor and product number which can be obtained by issuing the command:
 +<code bash>
 +lsusb -v
 +</code>
 +
 +and checking the ''idVendor'' and ''idProduct'' field, for example:
 +<code>
 +  idVendor           0x2040 Hauppauge
 +  idProduct          0x8268
 +</code>
 +
 +Based on the vendor and product numbers, a domain XML file can be generated, such as:
 +<code xml>
 +    <hostdev mode='subsystem' type='usb' managed='yes'>
 +      <source>
 +        <vendor id='0x2040'/>
 +        <product id='0x8268'/>
 +      </source>
 +    </hostdev>
 +
 +</code>
 +
 +that can then be inserted as part of the domain definition.
 +
 +
 +In order to plug and unplug a device from the guest to the host and vice-versa, the following twin converse commands can be used:
 +<code bash>
 +virsh attach-device DOMAIN --file device.xml --config
 +virsh detach-device DOMAIN --file device.xml
 +</code>
 +where:
 +  * ''DOMAIN'' the virtual domain,
 +  * ''device.xml'' contains an USB device definition as per the previous example
 +
 +The additional ''--config'' parameter passed to ''attach-device'' makes it such that the device will be included as part of the domain definition after the command executes.
 +
 +
  

fuss/libvirt.1560198432.txt.gz · Last modified: 2019/06/10 20:27 by office

Wizardry and Steamworks

© 2025 Wizardry and Steamworks

Access website using Tor Access website using i2p Wizardry and Steamworks PGP Key


For the contact, copyright, license, warranty and privacy terms for the usage of this website please see the contact, license, privacy, copyright.