Re: "relaxed" `-hda file.qcow2` equivalent ?

2024-11-15 Thread lacsaP Patatetom
Le ven. 15 nov. 2024 à 15:21, Frantisek Rysanek a écrit : > > And, I have an idea: rather than refer to driver=qcow2 and > > file.filename, how about referring to the loopback device (NBD) that > > you already have, courtesy of qemu-nbd ? Would that perhaps circumvent > > the file lock? ;-) > > >

Re: "relaxed" `-hda file.qcow2` equivalent ?

2024-11-15 Thread lacsaP Patatetom
Le ven. 15 nov. 2024 à 16:11, lacsaP Patatetom a écrit : > Le ven. 15 nov. 2024 à 15:21, Frantisek Rysanek > a écrit : > >> > And, I have an idea: rather than refer to driver=qcow2 and >> > file.filename, how about referring to the loopback device (NBD) that >> > you already have, courtesy of qe

Re: "relaxed" `-hda file.qcow2` equivalent ?

2024-11-15 Thread Frantisek Rysanek
> adding `,bus=ide.0,unit=0` to `-device ide-hd,drive=qcow-driver` do > the job :-) > > "relaxed" `-hda file.qcow2` is (seems to be) `-blockdev > driver=file,node-name=file-driver,filename=file.qcow2,locking=off > -blockdev driver=qcow2,node-name=qcow-driver,file=file-driver -device > ide-hd,driv

Re: PASST networking with onboard NIC

2024-11-15 Thread Thomas Huth
On 14/11/2024 20.09, Lytle, Ben wrote: >> I have a question about the proper way to use passt networking with a machine's onboard >> NIC (ie. without specifying a |-device|). >> Is there a way to connect |-netdev stream,id=net0,server=off,addr.type=unix,addr.path=/ >> tmp/passt_1.socket| t

Re: "relaxed" `-hda file.qcow2` equivalent ?

2024-11-15 Thread lacsaP Patatetom
Le ven. 15 nov. 2024 à 13:35, Frantisek Rysanek a écrit : > > # qemu-nbd -c /dev/nbd0 file.qcow2 > > # mount /dev/nbd0p1 /mnt -o uid=me > > $ # do some changes in /mnt/... > > > Are you sure the changes have made it to the underlying file? > If you do an umount here, a sync() is guaranteed. > If

Re: "relaxed" `-hda file.qcow2` equivalent ?

2024-11-15 Thread lacsaP Patatetom
Le jeu. 14 nov. 2024 à 17:00, Frantisek Rysanek a écrit : > > my image `fie.qcow2` is mounted elsewhere (nbd) and running > > `qemu-system-x86_64 -snapshot -hda file.qcow2` fails with the error > > "qemu-system-x86_64: -hda usb1.disk: Failed to get shared “write” > > lock / Is another process usi

Re: "relaxed" `-hda file.qcow2` equivalent ?

2024-11-15 Thread lacsaP Patatetom
Le ven. 15 nov. 2024 à 14:00, lacsaP Patatetom a écrit : > Le ven. 15 nov. 2024 à 13:35, Frantisek Rysanek > a écrit : > >> > # qemu-nbd -c /dev/nbd0 file.qcow2 >> > # mount /dev/nbd0p1 /mnt -o uid=me >> > $ # do some changes in /mnt/... >> > >> Are you sure the changes have made it to the under

Re: "relaxed" `-hda file.qcow2` equivalent ?

2024-11-15 Thread Frantisek Rysanek
Hmm. By now I'm thinking aloud. According to the manpage (see below), "-blockdev" is the most "down to earth", true and modern way to specify the emulated disk - possibly needs to be combined with a "-device" to specify the guest-side emulated interface? Curiously, I cannot find a complete exa

Re: "relaxed" `-hda file.qcow2` equivalent ?

2024-11-15 Thread Frantisek Rysanek
> And, I have an idea: rather than refer to driver=qcow2 and > file.filename, how about referring to the loopback device (NBD) that > you already have, courtesy of qemu-nbd ? Would that perhaps circumvent > the file lock? ;-) > > -blockdev node-name=xy,driver=raw,file.driver=host_device,\ > file.

Re: "relaxed" `-hda file.qcow2` equivalent ?

2024-11-15 Thread Frantisek Rysanek
> # qemu-nbd -c /dev/nbd0 file.qcow2 > # mount /dev/nbd0p1 /mnt -o uid=me > $ # do some changes in /mnt/... > Are you sure the changes have made it to the underlying file? If you do an umount here, a sync() is guaranteed. If you do not umount, at this point you may have some dirty writeback. So t