Beruflich Dokumente
Kultur Dokumente
Startseite
Zitate
Publikationen
Glossar
Links
Projekte
OccuSearch
OccuCloud
OccuMail
Privacy Captcha
Dokumentenvorlagen
Registervorlagen
Ordnerrücken
Visitenkarten
Musterschreiben
About
Newsletter
Anmelden
Archiv
Kontakt
Suchen
Suche nach: Suche … Suchen
Suche schließen
Menü schließen
Mastodon
Twitter
Diaspora
Facebook
Flickr
Instagram
Kategorien
German Linux Virtualisierung
https://the-digital-native.de/?p=366 1/8
2/8/23, 11:22 AM Eine physikalische Windows 10 Partition unter Linux in VirtualBox booten – The Digital Native
Kürzlich habe ich ein Lenovo P1 erworben, welches bereits ein vorinstalliertes Windows 10 Pro hatte. Natürlich habe ich direkt ein Linux installiert: In meinem
Fall ein Kubuntu 20.04. Dazu habe ich die bereits existente NTFS-Partition mit Windows Installation auf 850GB etwas verkleinert und 100GB freien Platz für
Linux geschaffen. Warum habe ich die NTFS-Partition so groß gelassen? Weil es nach meinen Recherchen wesentlich besser funktioniert von Linux aus auf einer
NTFS-Partition zu schreiben, als in Windows eine ext4 Partition einzurichten. Die gemeinsame Datenpartition wird also die Windows NTFS-Partition. Auf eine
swap-Partition habe ich ganz verzichtet, da 48GB Ram für alles Mögliche ausreichen wird.
So now I have a dual-boot system Ubuntu 20.04 / Windows 10. That's fine. But I also like to have the Windows functionalities to hand (Photoshop, ...) quickly
when using Linux. And since maintaining two Windows 10 instances is double the effort, a way to boot the physical system into VirtualBox comes in handy here.
That's what it's supposed to be about here.
Let's take a look at partitioning. This should look similar on any system with EFI.
/dev/nvme0n1p1a fat32 partition belonging to the EFI. You can also recognize it because it is /boot/efimounted under . This partition is relevant for us
because we need it to boot.
/dev/nvme0n1p2is a so-called Microsoft Reserved Partition , which is actually no longer relevant today.
/dev/nvme0n1p3is now the actually important partition for us. Here lies Windows.
/dev/nvme0n1p5contains our Linux distribution
/dev/nvme0n1p4contains a Windows recovery, in case you have to set up Windows again.
Now we need to find out the UUID of the Windows 10 partition. This is how it works:
sudo udevadm info /dev/nvme0n1p3 | grep UUID
https://the-digital-native.de/?p=366 2/8
2/8/23, 11:22 AM Eine physikalische Windows 10 Partition unter Linux in VirtualBox booten – The Digital Native
E: ID_PART_TABLE_UUID=579b23f9-843f-4fec-a246-0ed74800bef1
If there is another unique ID than ID_PART_TABLE_UUID, this also works. Copy the variable and create the file /etc/udev/rules.d/99-
win10disk.ruleswith something like this:
ENV{ID_PART_TABLE_UUID}=="579b23f9-843f-4fec-a246-0ed74800bef1", GROUP="win10disk"
Save the file and reboot now. Now check if everything worked with:
ls -l /dev/nvme0n1p3
You can VBoxManagecreate the VirtualBox raw disk image with . The target directory can be -filenamespecified with the option. We want to mount the partitions
/dev/nvme0n1p1(EFI) and /dev/nvme0n1p3(Windows). That would be partitions 1 and 3 of /dev/nvme0n1:
When the wizard is complete, open the settings of the new VM. Under System , select " Boot Order" as the only "Hard Disk" and disable all other options.
Activate the option "Enable EFI (special OSses only)" if your laptop uses EFI (we assume that here):
https://the-digital-native.de/?p=366 3/8
2/8/23, 11:22 AM Eine physikalische Windows 10 Partition unter Linux in VirtualBox booten – The Digital Native
Under Storage you can check again whether everything is correctly integrated. The file should be selected under Controller: SATAwin10.vmdk . You will probably
want to enable the "Solid-state Drive" option.
Set up GRUB
Now let's start the virtual machine. It is most likely that GRUB will now start without being able to load Windows directly. With lsyou can display all partitions:
grub> ls
(proc) (hd0) (hd0,gtp5) (hd0,gpt3) (hd0,gpt2) (hd0,gpt1)
https://the-digital-native.de/?p=366 4/8
2/8/23, 11:22 AM Eine physikalische Windows 10 Partition unter Linux in VirtualBox booten – The Digital Native
We already know that our Windows installation is on partition 3. Let's verify this:
grub> ls (hd0,gpt3)
Partition hd0,gpt3: Filesystem type ntfs - Label 'Windows', UUID ABCDEF - Partition start at 283648KiB
/boot/efiWe still have to define the partition mounted in our Linux as /dev/nvme0n1p1a chainloader :
grub> chainloader (hd0,gtp1)/EFI/Microsoft/Boot/bootmgfw.efi
And that was it! We can now start the boot process. The settings made are saved and Windows will start up automatically in the future.
grub> boot
If this is not the case, it is due to a bug in the current VirtualBox version (6.1.8) that seems to appear on some and not on others. The problem can be solved by
setting the graphics controller to VBoxVGA in the settings of the VM under Display and deactivating Enable 3D Acceleration. That's not ideal, but it's always
better than working on a screen that's much too small. Then shut down the VM cleanly via the operating system and start it up again. It should work now.
Conclusion
Es ist erstaunlich, dass Windows 10 in dieser Form so gut funktioniert. Man bedenke, dass wir bei jedem direkten Start andere Hardware haben als über
VirtualBox. Man sollte also Treiberprobleme vermuten. Auch erstaunlich ist, dass keine erneute Aktivierung bei jedem Hardwarewechsel nötig ist. Aber alles ist
super und es funktioniert!
Ich persönlich nutze die VM vor allem für Adobe Produkte (Photoshop, Lightroom, Illustrator, Acrobat Pro), Canon EOS Utility, den Brother P-Touch Editor
(Labeldrucker) und die Steuererklärung (Taxman 2020 für Selbstständige). Insbesondere Photoshop und Lightroom arbeiten unter einem nativ gebooteten System
natürlich besser (Hardwarebeschleunigung!) Eine brauchbare Software für Steuererklärungen von selbstständigen Kleingewerbetreibenden scheint es für Linux
leider nicht zu geben (beweist mir gerne das Gegenteil!)
https://the-digital-native.de/?p=366 5/8
2/8/23, 11:22 AM Eine physikalische Windows 10 Partition unter Linux in VirtualBox booten – The Digital Native
Viele Spaß mit eurem Hybrid-Windows-10
Attribution
Dieser Artikel basiert zum Teil auf dem Artikel „Booting a Physical Windows 10 Disk Using VirtualBox on Linux“ von jamieweb.net. Danke für seine Mühen!
Dieser Artikel ist lizenziert unter der Creative Commons Attribution-ShareAlike 4.0 International License.
Archiv anzeigen →
← Serverseitige Mailfilter mittels Sieve. Einrichtung von Dovecot & Roundcube → HanseMerkur speichert nach Versicherungsantrag rechtswidrig Daten beim
HIS und muss sie wieder löschen
https://the-digital-native.de/?p=366 6/8