mirror of
				https://github.com/oSoWoSo/DistroHopper.git
				synced 2024-08-14 22:46:53 +00:00 
			
		
		
		
	Add support for boot and driver ISO image
Installing Windows 10 in VirtIO enabled Qemu requires additional drivers. This change makes it possible to exposed those drivers during a Windows 10 install.
This commit is contained in:
		
							parent
							
								
									e8ddb13e9b
								
							
						
					
					
						commit
						c94b6a0a56
					
				
					 1 changed files with 11 additions and 1 deletions
				
			
		
							
								
								
									
										12
									
								
								quickemu
									
										
									
									
									
								
							
							
						
						
									
										12
									
								
								quickemu
									
										
									
									
									
								
							|  | @ -148,6 +148,16 @@ function vm_boot() { | ||||||
|     echo "             Existing disk state will be preserved, no writes will be committed." |     echo "             Existing disk state will be preserved, no writes will be committed." | ||||||
|   fi |   fi | ||||||
| 
 | 
 | ||||||
|  |   if [ -n "${iso}" ] && [ -e "${iso}" ]; then | ||||||
|  |     local ISO_BOOT="-drive media=cdrom,file="${iso}",index=2" | ||||||
|  |     echo " - Boot:     ${iso}" | ||||||
|  |   fi | ||||||
|  | 
 | ||||||
|  |   if [ -n "${driver_iso}" ] && [ -e "${driver_iso}" ]; then | ||||||
|  |     local ISO_DRIVER="-drive media=cdrom,file="${driver_iso}",index=3" | ||||||
|  |     echo " - Drivers:  ${driver_iso}" | ||||||
|  |   fi | ||||||
|  | 
 | ||||||
|   local cores="1" |   local cores="1" | ||||||
|   local allcores=$(nproc --all) |   local allcores=$(nproc --all) | ||||||
|   if [ ${allcores} -ge 8 ]; then |   if [ ${allcores} -ge 8 ]; then | ||||||
|  | @ -222,8 +232,8 @@ function vm_boot() { | ||||||
|   # Boot the iso image |   # Boot the iso image | ||||||
|   ${QEMU} -name ${VMNAME},process=${VMNAME} \ |   ${QEMU} -name ${VMNAME},process=${VMNAME} \ | ||||||
|     ${BIOS} \ |     ${BIOS} \ | ||||||
|     -cdrom "${iso}" \ |  | ||||||
|     -drive id=disk,file=${disk_img},format=qcow2,if=virtio,aio=native,cache.direct=on \ |     -drive id=disk,file=${disk_img},format=qcow2,if=virtio,aio=native,cache.direct=on \ | ||||||
|  |     ${ISO_BOOT} ${ISO_DRIVER} \ | ||||||
|     -enable-kvm \ |     -enable-kvm \ | ||||||
|     -machine q35,accel=kvm \ |     -machine q35,accel=kvm \ | ||||||
|     -cpu host,kvm=on \ |     -cpu host,kvm=on \ | ||||||
|  |  | ||||||
		Loading…
	
	Add table
		Add a link
		
	
		Reference in a new issue