mirror of
https://github.com/GNS3/gns3-server.git
synced 2026-11-03 14:01:15 +02:00
Merge branch '2.2' into 3.0
# Conflicts: # gns3server/compute/qemu/qemu_vm.py # gns3server/crash_report.py # gns3server/schemas/qemu.py # gns3server/schemas/qemu_template.py # gns3server/static/web-ui/index.html # gns3server/static/web-ui/main.1379a5647e8bc6d3e401.js # gns3server/version.py # tests/compute/qemu/test_qemu_vm.py
This commit is contained in:
commit
3f691b60c9
16 files changed
+212
-83
No files matched your search
@@ -0,0 +1,43 @@
|
||||
{
|
||||
"appliance_id": "8fecbf89-5cd1-4aea-b735-5f36cf0efbb7",
|
||||
"name": "BIRD2",
|
||||
"category": "router",
|
||||
"description": "The BIRD project aims to develop a fully functional dynamic IP routing daemon primarily targeted on (but not limited to) Linux, FreeBSD and other UNIX-like systems and distributed under the GNU General Public License.",
|
||||
"vendor_name": "CZ.NIC Labs",
|
||||
"vendor_url": "https://bird.network.cz",
|
||||
"documentation_url": "https://bird.network.cz/?get_doc&f=bird.html&v=20",
|
||||
"product_name": "BIRD internet routing daemon",
|
||||
"registry_version": 4,
|
||||
"status": "stable",
|
||||
"maintainer": "Bernhard Ehlers",
|
||||
"maintainer_email": "dev-ehlers@mailbox.org",
|
||||
"usage": "Username:\tgns3\nPassword:\tgns3\nTo become root, use \"sudo -s\".\n\nNetwork configuration:\nsudo nano /etc/network/interfaces\nsudo systemctl restart networking\n\nBIRD:\nRestart: sudo systemctl restart bird\nReconfigure: birdc configure",
|
||||
"port_name_format": "eth{0}",
|
||||
"qemu": {
|
||||
"adapter_type": "virtio-net-pci",
|
||||
"adapters": 4,
|
||||
"ram": 512,
|
||||
"hda_disk_interface": "scsi",
|
||||
"arch": "x86_64",
|
||||
"console_type": "telnet",
|
||||
"kvm": "allow"
|
||||
},
|
||||
"images": [
|
||||
{
|
||||
"filename": "bird2-debian-2.0.12.qcow2",
|
||||
"version": "2.0.12",
|
||||
"md5sum": "435218a2e90cba921cc7fde1d64a9419",
|
||||
"filesize": 287965184,
|
||||
"download_url": "https://sourceforge.net/projects/gns-3/files/Qemu%20Appliances/",
|
||||
"direct_download_url": "http://downloads.sourceforge.net/project/gns-3/Qemu%20Appliances/bird2-debian-2.0.12.qcow2"
|
||||
}
|
||||
],
|
||||
"versions": [
|
||||
{
|
||||
"name": "2.0.12",
|
||||
"images": {
|
||||
"hda_disk_image": "bird2-debian-2.0.12.qcow2"
|
||||
}
|
||||
}
|
||||
]
|
||||
}
|
||||
@@ -24,10 +24,17 @@
|
||||
"kvm": "require"
|
||||
},
|
||||
"images": [
|
||||
{
|
||||
"filename": "c8000v-universalk9_8G_serial.17.06.05.qcow2",
|
||||
"version": "17.06.05 8G",
|
||||
"md5sum": "aeb15ab8e1cbd0cd76f7260a81442f98",
|
||||
"filesize": 1777795072,
|
||||
"download_url": "https://software.cisco.com/download/home/286327102/type/282046477/release/Bengaluru-17.6.5"
|
||||
},
|
||||
{
|
||||
"filename": "c8000v-universalk9_8G_serial.17.06.01a.qcow2",
|
||||
"version": "17.06.01a 8G",
|
||||
"md5sum": "d8b8ae633d953ec1b6d8f18a09a4f4e7",
|
||||
"md5sum": "e278fa644295c703976a86f7f1c1cd65",
|
||||
"filesize": 1595277312,
|
||||
"download_url": "https://software.cisco.com/download/home/286327102/type/282046477/release/Bengaluru-17.6.1a"
|
||||
},
|
||||
@@ -47,6 +54,12 @@
|
||||
}
|
||||
],
|
||||
"versions": [
|
||||
{
|
||||
"name": "17.06.05 8G",
|
||||
"images": {
|
||||
"hda_disk_image": "c8000v-universalk9_8G_serial.17.06.05.qcow2"
|
||||
}
|
||||
},
|
||||
{
|
||||
"name": "17.06.01a 8G",
|
||||
"images": {
|
||||
|
||||
@@ -188,12 +188,12 @@
|
||||
"download_url": "https://software.cisco.com/download/"
|
||||
},
|
||||
{
|
||||
"filename": "OVMF-20160813.fd",
|
||||
"version": "16.08.13",
|
||||
"md5sum": "8ff0ef1ec56345db5b6bda1a8630e3c6",
|
||||
"filesize": 2097152,
|
||||
"download_url": "",
|
||||
"direct_download_url": "https://sourceforge.net/projects/gns-3/files/Qemu%20Appliances/OVMF-20160813.fd.zip/download",
|
||||
"filename": "OVMF-edk2-stable202305.fd",
|
||||
"version": "stable202305",
|
||||
"md5sum": "6c4cf1519fec4a4b95525d9ae562963a",
|
||||
"filesize": 4194304,
|
||||
"download_url": "https://sourceforge.net/projects/gns-3/files/Qemu%20Appliances/",
|
||||
"direct_download_url": "https://sourceforge.net/projects/gns-3/files/Qemu%20Appliances/OVMF-edk2-stable202305.fd.zip/download",
|
||||
"compression": "zip"
|
||||
}
|
||||
],
|
||||
@@ -201,161 +201,161 @@
|
||||
{
|
||||
"name": "9500v 10.1.1",
|
||||
"images": {
|
||||
"bios_image": "OVMF-20160813.fd",
|
||||
"bios_image": "OVMF-edk2-stable202305.fd",
|
||||
"hda_disk_image": "nexus9500v64.10.1.1.qcow2"
|
||||
}
|
||||
},
|
||||
{
|
||||
"name": "9300v 10.1.1",
|
||||
"images": {
|
||||
"bios_image": "OVMF-20160813.fd",
|
||||
"bios_image": "OVMF-edk2-stable202305.fd",
|
||||
"hda_disk_image": "nexus9300v.10.1.1.qcow2"
|
||||
}
|
||||
},
|
||||
{
|
||||
"name": "9500v 9.3.9",
|
||||
"images": {
|
||||
"bios_image": "OVMF-20160813.fd",
|
||||
"bios_image": "OVMF-edk2-stable202305.fd",
|
||||
"hda_disk_image": "nexus9500v.9.3.9.qcow2"
|
||||
}
|
||||
},
|
||||
{
|
||||
"name": "9300v 9.3.9",
|
||||
"images": {
|
||||
"bios_image": "OVMF-20160813.fd",
|
||||
"bios_image": "OVMF-edk2-stable202305.fd",
|
||||
"hda_disk_image": "nexus9300v.9.3.9.qcow2"
|
||||
}
|
||||
},
|
||||
{
|
||||
"name": "9300v 9.3.8",
|
||||
"images": {
|
||||
"bios_image": "OVMF-20160813.fd",
|
||||
"bios_image": "OVMF-edk2-stable202305.fd",
|
||||
"hda_disk_image": "nexus9300v.9.3.8.qcow2"
|
||||
}
|
||||
},
|
||||
{
|
||||
"name": "9500v 9.3.7",
|
||||
"images": {
|
||||
"bios_image": "OVMF-20160813.fd",
|
||||
"bios_image": "OVMF-edk2-stable202305.fd",
|
||||
"hda_disk_image": "nexus9500v.9.3.7.qcow2"
|
||||
}
|
||||
},
|
||||
{
|
||||
"name": "9500v 9.3.3",
|
||||
"images": {
|
||||
"bios_image": "OVMF-20160813.fd",
|
||||
"bios_image": "OVMF-edk2-stable202305.fd",
|
||||
"hda_disk_image": "nexus9500v.9.3.3.qcow2"
|
||||
}
|
||||
},
|
||||
{
|
||||
"name": "9300v 9.3.3",
|
||||
"images": {
|
||||
"bios_image": "OVMF-20160813.fd",
|
||||
"bios_image": "OVMF-edk2-stable202305.fd",
|
||||
"hda_disk_image": "nexus9300v.9.3.3.qcow2"
|
||||
}
|
||||
},
|
||||
{
|
||||
"name": "9.3.1",
|
||||
"images": {
|
||||
"bios_image": "OVMF-20160813.fd",
|
||||
"bios_image": "OVMF-edk2-stable202305.fd",
|
||||
"hda_disk_image": "nxosv.9.3.1.qcow2"
|
||||
}
|
||||
},
|
||||
{
|
||||
"name": "9.2.3",
|
||||
"images": {
|
||||
"bios_image": "OVMF-20160813.fd",
|
||||
"bios_image": "OVMF-edk2-stable202305.fd",
|
||||
"hda_disk_image": "nxosv-final.9.2.3.qcow2"
|
||||
}
|
||||
},
|
||||
{
|
||||
"name": "9.2.2",
|
||||
"images": {
|
||||
"bios_image": "OVMF-20160813.fd",
|
||||
"bios_image": "OVMF-edk2-stable202305.fd",
|
||||
"hda_disk_image": "nxosv-final.9.2.2.qcow2"
|
||||
}
|
||||
},
|
||||
{
|
||||
"name": "9.2.1",
|
||||
"images": {
|
||||
"bios_image": "OVMF-20160813.fd",
|
||||
"bios_image": "OVMF-edk2-stable202305.fd",
|
||||
"hda_disk_image": "nxosv-final.9.2.1.qcow2"
|
||||
}
|
||||
},
|
||||
{
|
||||
"name": "7.0.3.I7.9",
|
||||
"images": {
|
||||
"bios_image": "OVMF-20160813.fd",
|
||||
"bios_image": "OVMF-edk2-stable202305.fd",
|
||||
"hda_disk_image": "nxosv-final.7.0.3.I7.9.qcow2"
|
||||
}
|
||||
},
|
||||
{
|
||||
"name": "7.0.3.I7.7",
|
||||
"images": {
|
||||
"bios_image": "OVMF-20160813.fd",
|
||||
"bios_image": "OVMF-edk2-stable202305.fd",
|
||||
"hda_disk_image": "nxosv-final.7.0.3.I7.7.qcow2"
|
||||
}
|
||||
},
|
||||
{
|
||||
"name": "7.0.3.I7.6",
|
||||
"images": {
|
||||
"bios_image": "OVMF-20160813.fd",
|
||||
"bios_image": "OVMF-edk2-stable202305.fd",
|
||||
"hda_disk_image": "nxosv-final.7.0.3.I7.6.qcow2"
|
||||
}
|
||||
},
|
||||
{
|
||||
"name": "7.0.3.I7.5",
|
||||
"images": {
|
||||
"bios_image": "OVMF-20160813.fd",
|
||||
"bios_image": "OVMF-edk2-stable202305.fd",
|
||||
"hda_disk_image": "nxosv-final.7.0.3.I7.5.qcow2"
|
||||
}
|
||||
},
|
||||
{
|
||||
"name": "7.0.3.I7.4",
|
||||
"images": {
|
||||
"bios_image": "OVMF-20160813.fd",
|
||||
"bios_image": "OVMF-edk2-stable202305.fd",
|
||||
"hda_disk_image": "nxosv-final.7.0.3.I7.4.qcow2"
|
||||
}
|
||||
},
|
||||
{
|
||||
"name": "7.0.3.I7.3",
|
||||
"images": {
|
||||
"bios_image": "OVMF-20160813.fd",
|
||||
"bios_image": "OVMF-edk2-stable202305.fd",
|
||||
"hda_disk_image": "nxosv-final.7.0.3.I7.3.qcow2"
|
||||
}
|
||||
},
|
||||
{
|
||||
"name": "7.0.3.I7.2",
|
||||
"images": {
|
||||
"bios_image": "OVMF-20160813.fd",
|
||||
"bios_image": "OVMF-edk2-stable202305.fd",
|
||||
"hda_disk_image": "nxosv-final.7.0.3.I7.2.qcow2"
|
||||
}
|
||||
},
|
||||
{
|
||||
"name": "7.0.3.I7.1",
|
||||
"images": {
|
||||
"bios_image": "OVMF-20160813.fd",
|
||||
"bios_image": "OVMF-edk2-stable202305.fd",
|
||||
"hda_disk_image": "nxosv-final.7.0.3.I7.1.qcow2"
|
||||
}
|
||||
},
|
||||
{
|
||||
"name": "7.0.3.I6.1",
|
||||
"images": {
|
||||
"bios_image": "OVMF-20160813.fd",
|
||||
"bios_image": "OVMF-edk2-stable202305.fd",
|
||||
"hda_disk_image": "nxosv-final.7.0.3.I6.1.qcow2"
|
||||
}
|
||||
},
|
||||
{
|
||||
"name": "7.0.3.I5.2",
|
||||
"images": {
|
||||
"bios_image": "OVMF-20160813.fd",
|
||||
"bios_image": "OVMF-edk2-stable202305.fd",
|
||||
"hda_disk_image": "nxosv-final.7.0.3.I5.2.qcow2"
|
||||
}
|
||||
},
|
||||
{
|
||||
"name": "7.0.3.I5.1",
|
||||
"images": {
|
||||
"bios_image": "OVMF-20160813.fd",
|
||||
"bios_image": "OVMF-edk2-stable202305.fd",
|
||||
"hda_disk_image": "nxosv-final.7.0.3.I5.1.qcow2"
|
||||
}
|
||||
}
|
||||
|
||||
@@ -8,8 +8,8 @@
|
||||
"product_name": "Debian",
|
||||
"registry_version": 4,
|
||||
"status": "experimental",
|
||||
"maintainer": "GNS3 Team",
|
||||
"maintainer_email": "developers@gns3.net",
|
||||
"maintainer": "Bernhard Ehlers",
|
||||
"maintainer_email": "dev-ehlers@mailbox.org",
|
||||
"usage": "Username:\tdebian\nPassword:\tdebian\nTo become root, use \"sudo -s\".\n\nNetwork configuration:\n- In \"/etc/network/interfaces\" comment out \"source-directory /run/network/interfaces.d\"\n- Remove \"/etc/network/interfaces.d/50-cloud-init\"\n- Create \"/etc/network/interfaces.d/10-ens4\", for example:\n\nauto ens4\n#iface ens4 inet dhcp\niface ens4 inet static\n address 10.1.1.100/24\n gateway 10.1.1.1\n dns-nameservers 10.1.1.1\n",
|
||||
"symbol": "linux_guest.svg",
|
||||
"port_name_format": "ens{port4}",
|
||||
@@ -24,20 +24,28 @@
|
||||
},
|
||||
"images": [
|
||||
{
|
||||
"filename": "debian-11-genericcloud-amd64-20221219-1234.qcow2",
|
||||
"version": "11.6",
|
||||
"md5sum": "bd6ddbccc89e40deb7716b812958238d",
|
||||
"filesize": 258801664,
|
||||
"download_url": "https://cloud.debian.org/images/cloud/bullseye/",
|
||||
"direct_download_url": "https://cloud.debian.org/images/cloud/bullseye/20221219-1234/debian-11-genericcloud-amd64-20221219-1234.qcow2"
|
||||
"filename": "debian-12-genericcloud-amd64-20230612-1409.qcow2",
|
||||
"version": "12.0",
|
||||
"md5sum": "524cf33a1284d6e3363bd4d843756386",
|
||||
"filesize": 280166400,
|
||||
"download_url": "https://cloud.debian.org/images/cloud/bookworm/",
|
||||
"direct_download_url": "https://cloud.debian.org/images/cloud/bookworm/20230612-1409/debian-12-genericcloud-amd64-20230612-1409.qcow2"
|
||||
},
|
||||
{
|
||||
"filename": "debian-10-genericcloud-amd64-20220911-1135.qcow2",
|
||||
"filename": "debian-11-genericcloud-amd64-20230601-1398.qcow2",
|
||||
"version": "11.7",
|
||||
"md5sum": "1b24a841dc5ca9bcf40b94ad4b4775d4",
|
||||
"filesize": 259063808,
|
||||
"download_url": "https://cloud.debian.org/images/cloud/bullseye/",
|
||||
"direct_download_url": "https://cloud.debian.org/images/cloud/bullseye/20230601-1398/debian-11-genericcloud-amd64-20230601-1398.qcow2"
|
||||
},
|
||||
{
|
||||
"filename": "debian-10-genericcloud-amd64-20230601-1398.qcow2",
|
||||
"version": "10.13",
|
||||
"md5sum": "9d4d1175bef974caba79dd6ca33d500c",
|
||||
"filesize": 234749952,
|
||||
"md5sum": "ca799fb4011712f4686c422c1a9731cf",
|
||||
"filesize": 228130816,
|
||||
"download_url": "https://cloud.debian.org/images/cloud/buster/",
|
||||
"direct_download_url": "https://cloud.debian.org/images/cloud/buster/20220911-1135/debian-10-genericcloud-amd64-20220911-1135.qcow2"
|
||||
"direct_download_url": "https://cloud.debian.org/images/cloud/buster/20230601-1398/debian-10-genericcloud-amd64-20230601-1398.qcow2"
|
||||
},
|
||||
{
|
||||
"filename": "debian-cloud-init-data.iso",
|
||||
@@ -50,16 +58,23 @@
|
||||
],
|
||||
"versions": [
|
||||
{
|
||||
"name": "11.6",
|
||||
"name": "12.0",
|
||||
"images": {
|
||||
"hda_disk_image": "debian-11-genericcloud-amd64-20221219-1234.qcow2",
|
||||
"hda_disk_image": "debian-12-genericcloud-amd64-20230612-1409.qcow2",
|
||||
"cdrom_image": "debian-cloud-init-data.iso"
|
||||
}
|
||||
},
|
||||
{
|
||||
"name": "11.7",
|
||||
"images": {
|
||||
"hda_disk_image": "debian-11-genericcloud-amd64-20230601-1398.qcow2",
|
||||
"cdrom_image": "debian-cloud-init-data.iso"
|
||||
}
|
||||
},
|
||||
{
|
||||
"name": "10.13",
|
||||
"images": {
|
||||
"hda_disk_image": "debian-10-genericcloud-amd64-20220911-1135.qcow2",
|
||||
"hda_disk_image": "debian-10-genericcloud-amd64-20230601-1398.qcow2",
|
||||
"cdrom_image": "debian-cloud-init-data.iso"
|
||||
}
|
||||
}
|
||||
|
||||
@@ -8,8 +8,8 @@
|
||||
"product_name": "ipterm",
|
||||
"registry_version": 4,
|
||||
"status": "stable",
|
||||
"maintainer": "GNS3 Team",
|
||||
"maintainer_email": "developers@gns3.net",
|
||||
"maintainer": "Bernhard Ehlers",
|
||||
"maintainer_email": "dev-ehlers@mailbox.org",
|
||||
"usage": "The /root directory is persistent.",
|
||||
"symbol": "linux_guest.svg",
|
||||
"docker": {
|
||||
|
||||
@@ -27,6 +27,15 @@
|
||||
"options": "-nographic"
|
||||
},
|
||||
"images": [
|
||||
{
|
||||
"filename": "chr-7.10.1.img",
|
||||
"version": "7.10.1",
|
||||
"md5sum": "917729e79b9992562f4160d461b21cac",
|
||||
"filesize": 134217728,
|
||||
"download_url": "http://www.mikrotik.com/download",
|
||||
"direct_download_url": "https://download.mikrotik.com/routeros/7.10.1/chr-7.10.1.img.zip",
|
||||
"compression": "zip"
|
||||
},
|
||||
{
|
||||
"filename": "chr-7.7.img",
|
||||
"version": "7.7",
|
||||
@@ -83,6 +92,12 @@
|
||||
}
|
||||
],
|
||||
"versions": [
|
||||
{
|
||||
"name": "7.10.1",
|
||||
"images": {
|
||||
"hda_disk_image": "chr-7.10.1.img"
|
||||
}
|
||||
},
|
||||
{
|
||||
"name": "7.7",
|
||||
"images": {
|
||||
|
||||
@@ -25,6 +25,13 @@
|
||||
"kvm": "require"
|
||||
},
|
||||
"images": [
|
||||
{
|
||||
"filename": "OPNsense-23.1-OpenSSL-nano-amd64.img",
|
||||
"version": "23.1",
|
||||
"md5sum": "db7d3b9fd3b94894623368db1041ff11",
|
||||
"filesize": 3221225472,
|
||||
"download_url": "https://opnsense.c0urier.net/releases/23.1/"
|
||||
},
|
||||
{
|
||||
"filename": "OPNsense-22.1.2-OpenSSL-nano-amd64.img",
|
||||
"version": "22.1.2",
|
||||
@@ -55,6 +62,12 @@
|
||||
}
|
||||
],
|
||||
"versions": [
|
||||
{
|
||||
"name": "23.1",
|
||||
"images": {
|
||||
"hda_disk_image": "OPNsense-23.1-OpenSSL-nano-amd64.img"
|
||||
}
|
||||
},
|
||||
{
|
||||
"name": "22.1.2",
|
||||
"images": {
|
||||
|
||||
@@ -24,6 +24,13 @@
|
||||
"process_priority": "normal"
|
||||
},
|
||||
"images": [
|
||||
{
|
||||
"filename": "pfSense-CE-2.7.0-RELEASE-amd64.iso",
|
||||
"version": "2.7.0",
|
||||
"md5sum": "cb0b72ca864d06682265de5e5a72a1fb",
|
||||
"filesize": 765218816,
|
||||
"download_url": "https://www.pfsense.org/download/mirror.php?section=downloads"
|
||||
},
|
||||
{
|
||||
"filename": "pfSense-CE-2.6.0-RELEASE-amd64.iso",
|
||||
"version": "2.6.0",
|
||||
@@ -69,6 +76,13 @@
|
||||
}
|
||||
],
|
||||
"versions": [
|
||||
{
|
||||
"name": "2.7.0",
|
||||
"images": {
|
||||
"hda_disk_image": "empty100G.qcow2",
|
||||
"cdrom_image": "pfSense-CE-2.7.0-RELEASE-amd64.iso"
|
||||
}
|
||||
},
|
||||
{
|
||||
"name": "2.6.0",
|
||||
"images": {
|
||||
|
||||
@@ -8,8 +8,8 @@
|
||||
"product_name": "webterm",
|
||||
"registry_version": 4,
|
||||
"status": "stable",
|
||||
"maintainer": "GNS3 Team",
|
||||
"maintainer_email": "developers@gns3.net",
|
||||
"maintainer": "Bernhard Ehlers",
|
||||
"maintainer_email": "dev-ehlers@mailbox.org",
|
||||
"usage": "The /root directory is persistent.",
|
||||
"symbol": "firefox.svg",
|
||||
"docker": {
|
||||
|
||||
@@ -38,12 +38,12 @@
|
||||
"compression": "zip"
|
||||
},
|
||||
{
|
||||
"filename": "OVMF-20160813.fd",
|
||||
"version": "16.08.13",
|
||||
"md5sum": "8ff0ef1ec56345db5b6bda1a8630e3c6",
|
||||
"filesize": 2097152,
|
||||
"download_url": "",
|
||||
"direct_download_url": "https://sourceforge.net/projects/gns-3/files/Qemu%20Appliances/OVMF-20160813.fd.zip/download",
|
||||
"filename": "OVMF-edk2-stable202305.fd",
|
||||
"version": "stable202305",
|
||||
"md5sum": "6c4cf1519fec4a4b95525d9ae562963a",
|
||||
"filesize": 4194304,
|
||||
"download_url": "https://sourceforge.net/projects/gns-3/files/Qemu%20Appliances/",
|
||||
"direct_download_url": "https://sourceforge.net/projects/gns-3/files/Qemu%20Appliances/OVMF-edk2-stable202305.fd.zip/download",
|
||||
"compression": "zip"
|
||||
}
|
||||
],
|
||||
@@ -51,7 +51,7 @@
|
||||
{
|
||||
"name": "2212",
|
||||
"images": {
|
||||
"bios_image": "OVMF-20160813.fd",
|
||||
"bios_image": "OVMF-edk2-stable202305.fd",
|
||||
"hda_disk_image": "WinDev2212Eval-disk1.vmdk"
|
||||
}
|
||||
}
|
||||
|
||||
@@ -115,6 +115,7 @@ class QemuVM(BaseNode):
|
||||
self._local_udp_tunnels = {}
|
||||
self._guest_cid = None
|
||||
self._command_line_changed = False
|
||||
self._qemu_version = None
|
||||
|
||||
# QEMU VM settings
|
||||
if qemu_path:
|
||||
@@ -2089,8 +2090,7 @@ class QemuVM(BaseNode):
|
||||
f"file={disk},if=none,id=drive{disk_index},index={disk_index},media=disk{extra_drive_options}",
|
||||
]
|
||||
)
|
||||
qemu_version = await self.manager.get_qemu_version(self.qemu_path)
|
||||
if qemu_version and parse_version(qemu_version) >= parse_version("4.2.0"):
|
||||
if self._qemu_version and parse_version(self._qemu_version) >= parse_version("4.2.0"):
|
||||
# The ‘ide-drive’ device is deprecated since version 4.2.0
|
||||
# https://qemu.readthedocs.io/en/latest/system/deprecated.html#ide-drive-since-4-2
|
||||
options.extend(
|
||||
@@ -2281,7 +2281,19 @@ class QemuVM(BaseNode):
|
||||
raise QemuError(f"bios image '{self._bios_image}' is not accessible")
|
||||
options.extend(["-bios", self._bios_image.replace(",", ",,")])
|
||||
elif self._uefi:
|
||||
options.extend(["-bios", "OVMF.fd"]) # the OVMF bios image should be in the image directory
|
||||
# get the OVMF firmware from the images directory
|
||||
ovmf_firmware_path = self.manager.get_abs_image_path("OVMF_CODE.fd")
|
||||
log.info("Configuring UEFI boot mode using OVMF file: '{}'".format(ovmf_firmware_path))
|
||||
options.extend(["-drive", "if=pflash,format=raw,readonly,file={}".format(ovmf_firmware_path)])
|
||||
|
||||
# the node should have its own copy of OVMF_VARS.fd (the UEFI variables store)
|
||||
ovmf_vars_node_path = os.path.join(self.working_dir, "OVMF_VARS.fd")
|
||||
if not os.path.exists(ovmf_vars_node_path):
|
||||
try:
|
||||
shutil.copyfile(self.manager.get_abs_image_path("OVMF_VARS.fd"), ovmf_vars_node_path)
|
||||
except OSError as e:
|
||||
raise QemuError("Cannot copy OVMF_VARS.fd file to the node working directory: {}".format(e))
|
||||
options.extend(["-drive", "if=pflash,format=raw,file={}".format(ovmf_vars_node_path)])
|
||||
return options
|
||||
|
||||
def _linux_boot_options(self):
|
||||
@@ -2381,8 +2393,7 @@ class QemuVM(BaseNode):
|
||||
pci_bridges = math.floor(pci_devices / 32)
|
||||
pci_bridges_created = 0
|
||||
if pci_bridges >= 1:
|
||||
qemu_version = await self.manager.get_qemu_version(self.qemu_path)
|
||||
if qemu_version and parse_version(qemu_version) < parse_version("2.4.0"):
|
||||
if self._qemu_version and parse_version(self._qemu_version) < parse_version("2.4.0"):
|
||||
raise QemuError(
|
||||
"Qemu version 2.4 or later is required to run this VM with a large number of network adapters"
|
||||
)
|
||||
@@ -2448,8 +2459,7 @@ class QemuVM(BaseNode):
|
||||
|
||||
if any(opt in self._options for opt in ["-display", "-nographic", "-curses", "-sdl" "-spice", "-vnc"]):
|
||||
return []
|
||||
version = await self.manager.get_qemu_version(self.qemu_path)
|
||||
if version and parse_version(version) >= parse_version("3.0"):
|
||||
if self._qemu_version and parse_version(self._qemu_version) >= parse_version("3.0"):
|
||||
return ["-display", "none"]
|
||||
else:
|
||||
return ["-nographic"]
|
||||
@@ -2578,6 +2588,7 @@ class QemuVM(BaseNode):
|
||||
(to be passed to subprocess.Popen())
|
||||
"""
|
||||
|
||||
self._qemu_version = await self.manager.get_qemu_version(self.qemu_path)
|
||||
vm_name = self._name.replace(",", ",,")
|
||||
project_path = self.project.path.replace(",", ",,")
|
||||
additional_options = self._options.strip()
|
||||
@@ -2599,10 +2610,9 @@ class QemuVM(BaseNode):
|
||||
if await self._run_with_hardware_acceleration(self.qemu_path, self._options):
|
||||
if sys.platform.startswith("linux"):
|
||||
command.extend(["-enable-kvm"])
|
||||
version = await self.manager.get_qemu_version(self.qemu_path)
|
||||
# Issue on some combo Intel CPU + KVM + Qemu 2.4.0
|
||||
# https://github.com/GNS3/gns3-server/issues/685
|
||||
if version and parse_version(version) >= parse_version("2.4.0") and self.platform == "x86_64":
|
||||
if self._qemu_version and parse_version(self._qemu_version) >= parse_version("2.4.0") and self.platform == "x86_64":
|
||||
command.extend(["-machine", "smm=off"])
|
||||
elif sys.platform.startswith("darwin"):
|
||||
command.extend(["-enable-hax"])
|
||||
|
||||
Binary file not shown.
Binary file not shown.
Executable → Regular
File mode changed.
Reference in new issue
Block a user