freebsd:freebsd_-_bhyve
Unterschiede
Hier werden die Unterschiede zwischen zwei Versionen angezeigt.
| Beide Seiten der vorigen RevisionVorhergehende ÜberarbeitungNächste Überarbeitung | Vorhergehende Überarbeitung | ||
| freebsd:freebsd_-_bhyve [2024-03-28 16:21:57] – [AMD-GPU passthrough] manfred | freebsd:freebsd_-_bhyve [2024-07-06 18:20:05] (aktuell) – [Intel-GPU passthrough] manfred | ||
|---|---|---|---|
| Zeile 52: | Zeile 52: | ||
| die VM von ihrer virtuellen Platte starten: | die VM von ihrer virtuellen Platte starten: | ||
| > sh / | > sh / | ||
| + | |||
| + | |||
| + | ===== Verzeichnis in die VM durchreichen ===== | ||
| + | |||
| + | VM-Start ('' | ||
| + | # bhyve -AHP -s 0: | ||
| + | |||
| + | Mount mit Linux/ | ||
| + | # mount -t 9p -o trans=virtio sharename /mm | ||
| + | |||
| + | Eintrag in der FsTab: | ||
| + | # vim /etc/fstab | ||
| + | sharename | ||
| + | |||
| + | |||
| + | ==== mehrere Verzeichnisse in die VM durchreichen ==== | ||
| + | |||
| + | |||
| + | VM-Start ('' | ||
| + | # bhyve -AHP -s 0: | ||
| + | |||
| + | Mount mit Linux/ | ||
| + | # mount -t 9p -o trans=virtio mmaudio /mm/Audio | ||
| + | # mount -t 9p -o trans=virtio mmvideo /mm/Video | ||
| + | |||
| + | Eintrag in der FsTab: | ||
| + | # vim /etc/fstab | ||
| + | mmaudio | ||
| + | mmvideo | ||
| Zeile 69: | Zeile 98: | ||
| ===== Bridged networking - VM und Host gehen über die selbe Netzwerkkarte aber unterschiedlichen IPs ins Netz ===== | ===== Bridged networking - VM und Host gehen über die selbe Netzwerkkarte aber unterschiedlichen IPs ins Netz ===== | ||
| - | > pkg install sysutils/ | + | > pkg install sysutils/ |
| eine virtuelle Festplatte erstellen: | eine virtuelle Festplatte erstellen: | ||
| Zeile 80: | Zeile 109: | ||
| > vi device.map | > vi device.map | ||
| (hd0) ./linux.img | (hd0) ./linux.img | ||
| - | (cd0) ./buntu-20.04-legacy-server-amd64.iso | + | (cd0) ./debian-12.4.0-amd64-netinst.iso |
| Grub läd den Linux-Kernel vom Installations-ISO-Image: | Grub läd den Linux-Kernel vom Installations-ISO-Image: | ||
| Zeile 86: | Zeile 115: | ||
| VM starten: | VM starten: | ||
| - | > bhyve -A -H -P -s 0: | + | > bhyve -A -H -P -s 0: |
| > bhyvectl --destroy --vm=linuxguest | > bhyvectl --destroy --vm=linuxguest | ||
| Zeile 380: | Zeile 409: | ||
| === Vorbereitungen in FreeBSD 14.0 === | === Vorbereitungen in FreeBSD 14.0 === | ||
| - | Bhyve benötigt ein Firmware-Update aus dem Ports-Tree: **'' | + | Extract ROM (mit Linux): |
| - | + | > lspci -v | grep -Fi vga | |
| - | > cd /usr/ports/sysutils/edk2 | + | 00:02.0 VGA compatible controller: ... |
| - | > git remote -v | + | > echo 1 > / |
| + | > cat /sys/devices/pci0000:00/0000: | ||
| + | > echo 0 > / | ||
| + | FreeBSD-Host-System | ||
| > kldload vmm | > kldload vmm | ||
| | | ||
| - | > pciconf -l | + | > pciconf -l | grep -Ei ' |
| - | ... | + | |
| vgapci0@pci0: | vgapci0@pci0: | ||
| - | ... | ||
| xhci0@pci0: | xhci0@pci0: | ||
| - | ... | ||
| | | ||
| - | > devctl | + | > devctl |
| - | > devctl | + | > devctl |
| | | ||
| > devctl set driver pci0:0:2:0 ppt | > devctl set driver pci0:0:2:0 ppt | ||
| > devctl set driver pci0:0:20:0 ppt | > devctl set driver pci0:0:20:0 ppt | ||
| | | ||
| - | > pciconf -l | + | > pciconf -l | grep -Fi ppt |
| - | ... | + | |
| ppt0@pci0: | ppt0@pci0: | ||
| - | ... | ||
| ppt1@pci0: | ppt1@pci0: | ||
| - | ... | ||
| Zeile 420: | Zeile 446: | ||
| //Interne Intel-Grafikkarten funktionieren, | //Interne Intel-Grafikkarten funktionieren, | ||
| - | Extract ROM (mit Linux): | + | Bhyve benötigt ein Firmware-Update aus dem Ports-Tree: **'' |
| - | > echo 1 > /sys/devices/pci0000: | + | |
| - | > cat / | + | FreeBSD-Host-System |
| - | | + | > cd /usr/ports/sysutils/edk2 |
| + | > git remote -v | ||
| + | ... | ||
| Manchmal kann man das VBIOS nicht dumpen, dann muß man seinen Mainboard-Hersteller nach einem GOP fragen. | Manchmal kann man das VBIOS nicht dumpen, dann muß man seinen Mainboard-Hersteller nach einem GOP fragen. | ||
| Zeile 429: | Zeile 457: | ||
| Call bhyve //(es ist notwendig, von UEFI zu booten)//: | Call bhyve //(es ist notwendig, von UEFI zu booten)//: | ||
| - | > bhyve -AHPw -c 2 -m 4G -s 0, | + | > bhyve -AHPw -c 2 -m 4G -s 0, |
| + | | ||
| + | | ||
| + | | ||
| + | | ||
| + | | ||
| + | | ||
| + | | ||
| + | | ||
| + | | ||
| + | | ||
| + | | ||
| + | | ||
| //Hier wird die Option '' | //Hier wird die Option '' | ||
/home/http/wiki/data/attic/freebsd/freebsd_-_bhyve.1711642917.txt · Zuletzt geändert: von manfred
