Skip to content
Toggle navigation
P
Projects
G
Groups
S
Snippets
Help
CIRCLE3
/
gpuvirt
This project
Loading...
Sign in
Toggle navigation
Go to a project
Project
Repository
Issues
0
Merge Requests
0
Pipelines
Wiki
Snippets
Members
Activity
Graph
Charts
Create a new issue
Jobs
Commits
Issue Boards
Files
Commits
Branches
Tags
Contributors
Graph
Compare
Charts
A prog2-höz tartozó friss repo anyagok itt elérhetőek:
https://git.iit.bme.hu/
Commit
dec0f1ec
authored
Aug 16, 2023
by
Karsa Zoltán István
Browse files
Options
Browse Files
Download
Plain Diff
fix conflicts
parents
806935dc
49a28fd7
Hide whitespace changes
Inline
Side-by-side
Showing
3 changed files
with
6 additions
and
60 deletions
+6
-60
demo.txt
+0
-54
templates/demovm.xml
+4
-5
vm.py
+2
-1
No files found.
demo.txt
deleted
100644 → 0
View file @
806935dc
(exec: "/bin/qemu-system-x86_64", args: @["-D",
"/home/cloud/.local/libvf.io/logs/qemu/99a34fe5-451a-4b68-a692-3b5ec2e46849-session.txt",
"-no-hpet", "-mem-prealloc",
"-uuid", "99a34fe5-451a-4b68-a692-3b5ec2e46849",
"-machine", "pc-q35-4.2,accel=kvm,usb=off,vmport=off,dump-guest-core=off",
"-cpu", "host,ss=on,vmx=on,pcid=on,-hypervisor,arat=on,tsc-adjust=on,umip=on,md-clear=on,stibp=on,
arch-capabilities=on,ssbd=on,xsaveopt=on,pdpe1gb=on,ibpb=on,amd-stibp=on,amd-ssbd=on,
skip-l1dfl-vmentry=on,pschange-mc-no=on,hv-vapic,hv_time,hv-spinlocks=0x1fff,hv-vendor-id=null,
kvm=off,topoext=on"
-rtc clock=host,base=localtime",
"-m", "4096", "-smp", "cores=1,threads=2,sockets=1",
"-hda", "/home/cloud/.local/libvf.io/live/99a34fe5-451a-4b68-a692-3b5ec2e46849",
"--enable-kvm",
"-device vfio-pci,id=hostdev0,sysfsdev=/sys/bus/mdev/devices/d3f92818-d658-48ac-a964-c773af3a932d,
display=off
-device rtl8139,netdev=net0
-netdev user,id=net0,hostfwd=tcp::2222-:22",
"-net", "user", "-net", "nic", "-device", "vhost-vsock-pci,guest-cid=11257",
"-qmp", "unix:/tmp/sockets/99a34fe5-451a-4b68-a692-3b5ec2e46849/main.sock,server,nowait",
"-qmp", "unix:/tmp/sockets/99a34fe5-451a-4b68-a692-3b5ec2e46849/master.sock,server,nowait",
"-cdrom", "/data/img/ubuntu-20.04.6-live-server-amd64.iso", "-vnc", "0.0.0.0:6100"])
/usr/bin/qemu-system-x86_64
-name guest=demo,debug-threads=on
-object secret,id=masterKey0,format=raw,file=/var/lib/libvirt/qemu/domain--1-demo/master-key.aes
-machine pc-i440fx-5.2,accel=kvm,usb=off,dump-guest-core=off,memory-backend=pc.ram
-cpu host,migratable=on,vmx=on,ss=on,pcid=on
-m 3815
-object memory-backend-ram,id=pc.ram,size=4000317440
-overcommit mem-lock=off
-smp 2,sockets=2,cores=1,threads=1
-uuid ec472a72-12fa-4315-b20c-4f30e9876870
-no-user-config -nodefaults
-chardev socket,id=charmonitor,path=/var/lib/libvirt/qemu/domain--1-demo/monitor.sock,server,nowait
-mon chardev=charmonitor,id=monitor,mode=control
-rtc base=utc
-no-shutdown
-no-acpi -boot strict=on
-device piix3-usb-uhci,id=usb,bus=pci.0,addr=0x1.0x2
-blockdev '{"driver":"file","filename":"/data/vms/s1/s1-ubuntu.qcow2","node-name":"libvirt-2-storage","auto-read-only":true,"discard":"unmap"}'
-blockdev '{"node-name":"libvirt-2-format","read-only":false,"driver":"qcow2","file":"libvirt-2-storage","backing":null}'
-device ide-hd,bus=ide.0,unit=0,drive=libvirt-2-format,id=ide0-0-0,bootindex=1
-blockdev '{"driver":"file","filename":"/data/img/ubuntu-22.04.2-live-server-amd64.iso","node-name":"libvirt-1-storage","auto-read-only":true,"discard":"unmap"}'
-blockdev '{"node-name":"libvirt-1-format","read-only":true,"driver":"raw","file":"libvirt-1-storage"}'
-device ide-cd,bus=ide.1,unit=0,drive=libvirt-1-format,id=ide0-1-0,bootindex=2
-netdev tap,fd=30,id=hostnet0
-device rtl8139,netdev=hostnet0,id=net0,mac=52:54:00:d0:f2:4d,bus=pci.0,addr=0x3
-vnc 0.0.0.0:0
-device cirrus-vga,id=video0,bus=pci.0,addr=0x2
-device vfio-pci,id=hostdev0,sysfsdev=/sys/bus/mdev/devices/ec472a72-12fa-4315-b20c-4f30e9876870,display=off,bus=pci.0,addr=0x4
-device virtio-balloon-pci,id=balloon0,bus=pci.0,addr=0x5
-sandbox on,obsolete=deny,elevateprivileges=deny,spawn=deny,resourcecontrol=deny
-msg timestamp=on
\ No newline at end of file
templates/demovm.xml
View file @
dec0f1ec
<domain
type=
'kvm'
xmlns:qemu=
'http://libvirt.org/schemas/domain/qemu/1.0'
>
<domain
type=
'kvm'
xmlns:qemu=
'http://libvirt.org/schemas/domain/qemu/1.0'
>
<name>
{{name}}
</name>
<name>
{{name}}
</name>
<uuid>
{{uuid}}
</uuid>
<uuid>
{{uuid}}
</uuid>
<memory
unit=
'G
B
'
>
{{ram}}
</memory>
<memory
unit=
'G'
>
{{ram}}
</memory>
<currentMemory
unit=
'G
B
'
>
{{ram}}
</currentMemory>
<currentMemory
unit=
'G'
>
{{ram}}
</currentMemory>
<vcpu>
{{vcpu}}
</vcpu>
i
<vcpu>
{{vcpu}}
</vcpu>
<features>
<features>
<kvm>
<kvm>
<hidden
state=
'on'
/>
<hidden
state=
'on'
/>
...
@@ -26,11 +26,10 @@
...
@@ -26,11 +26,10 @@
<feature
policy=
'require'
name=
'skip-l1dfl-vmentry'
/>
<feature
policy=
'require'
name=
'skip-l1dfl-vmentry'
/>
<feature
policy=
'require'
name=
'pschange-mc-no'
/>
<feature
policy=
'require'
name=
'pschange-mc-no'
/>
<feature
policy=
'disable'
name=
'hypervisor'
/>
<feature
policy=
'disable'
name=
'hypervisor'
/>
</cpu>
</cpu>
<os>
<os>
<type
arch=
'x86_64'
machine=
'pc-q35-4.2'
>
hvm
</type>
<type
arch=
'x86_64'
machine=
'pc-q35-4.2'
>
hvm
</type>
<bootmenu
enable=
'
no
'
/>
<bootmenu
enable=
'
{{ boot_menu }}
'
/>
</os>
</os>
<devices>
<devices>
<emulator>
/usr/bin/qemu-system-x86_64
</emulator>
<emulator>
/usr/bin/qemu-system-x86_64
</emulator>
...
...
vm.py
View file @
dec0f1ec
...
@@ -29,7 +29,8 @@ params = {
...
@@ -29,7 +29,8 @@ params = {
"iso"
:
"/data/img/ubuntu-20.04.6-live-server-amd64.iso"
,
"iso"
:
"/data/img/ubuntu-20.04.6-live-server-amd64.iso"
,
"vgpu"
:
True
,
"vgpu"
:
True
,
"vgpu_type"
:
"nvidia-1"
,
"vgpu_type"
:
"nvidia-1"
,
"mdev_bus"
:
"0000
\
:01
\
:00.0"
"mdev_bus"
:
"0000
\
:01
\
:00.0"
,
"boot_menu"
:
"yes"
,
}
}
template
=
env
.
get_template
(
"demovm.xml"
)
template
=
env
.
get_template
(
"demovm.xml"
)
...
...
Write
Preview
Markdown
is supported
0%
Try again
or
attach a new file
Attach a file
Cancel
You are about to add
0
people
to the discussion. Proceed with caution.
Finish editing this message first!
Cancel
Please
register
or
sign in
to comment