On Saturday, March 13, 2021 at 8:58:57 PM UTC+2 Fotis Xenakis wrote:

> On Saturday, March 13, 2021 at 6:08:29 PM UTC+2 jwkoz...@gmail.com wrote:
>
>> Hi,
>>
>> The other 2 patches work fine but this one fails when I test it. What am 
>> I doing wrong?
>>
>>
>> sudo PATH=build/downloaded_packages/qemu/build/tools/virtiofsd:$PATH 
>> ./scripts/run.py --virtio-fs-tag=myfs --virtio-fs-dir=$(pwd)/build/export 
>> --qemu-path build/downloaded_packages/qemu/build/qemu-system-x86_64 
>> --virtio-fs-dax=1024M
>> qemu-system-x86_64: -device 
>> vhost-user-fs-pci,queue-size=1024,chardev=char0,tag=myfs,cache-size=1024M: 
>> Property 'vhost-user-fs-pci.cache-size' not found
>> qemu failed.
>>
>> sudo PATH=build/downloaded_packages/qemu/build/tools/virtiofsd:$PATH 
>> ./scripts/run.py --virtio-fs-tag=myfs --virtio-fs-dir=$(pwd)/build/export 
>> --qemu-path build/downloaded_packages/qemu/build/qemu-system-x86_64 
>> --virtio-fs-dax=1024M --dry-run
>> /home/wkozaczuk/projects/osv-master/scripts/../scripts/imgedit.py setargs 
>> /home/wkozaczuk/projects/osv-master/build/last/usr.img "--rootfs=virtiofs 
>> /cli"
>> virtiofsd \
>> --socket-path=/tmp/vhostqemu \
>> -o source=/home/wkozaczuk/projects/osv-master/build/export
>> build/downloaded_packages/qemu/build/qemu-system-x86_64 \
>> -m 2G \
>> -smp 4 \
>> -vnc :1 \
>> -gdb tcp::1234,server,nowait \
>> -device virtio-blk-pci,id=blk0,drive=hd0,scsi=off,bootindex=0 \
>> -drive 
>> file=/home/wkozaczuk/projects/osv-master/build/last/usr.img,if=none,id=hd0,cache=none,aio=native
>>  
>> \
>> -chardev socket,id=char0,path=/tmp/vhostqemu \
>> -device 
>> vhost-user-fs-pci,queue-size=1024,chardev=char0,tag=myfs,cache-size=1024M \
>> -object memory-backend-file,id=mem,size=2G,mem-path=/dev/shm,share=on \
>> -numa node,memdev=mem \
>> -netdev user,id=un0,net=192.168.122.0/24,host=192.168.122.1 \
>> -device virtio-net-pci,netdev=un0 \
>> -device virtio-rng-pci \
>> -enable-kvm \
>> -cpu host,+x2apic \
>> -chardev stdio,mux=on,id=stdio,signal=off \
>> -mon chardev=stdio,mode=readline \
>> -device isa-serial,chardev=stdio
>>
>> I am using QEMU 5.2 built from sources.
>>
> Unfortunately DAX support has yet to be merged to upstream QEMU (I was 
> under the impression that it had been staged for QEMU 5.2.0, but alas it is 
> not part of it).
> So, to use it, one still needs to use the virtio-fs downstream version 
> which includes the necessary patches [1].
> The virtio-fs team are actively pursuing its upstreaming, but I 'm afraid 
> I don't have a clear view as to how long that might still take.
>
> Regarding the patch, do you think it would be better to hold it back until 
> there's proper support upstream?
>
Bumping on this: I guess we should wait for QEMU here? 

>
> [1] https://gitlab.com/virtio-fs/qemu/-/tree/virtio-fs-dev
>  
>
>>
>> Waldek
>> On Saturday, March 6, 2021 at 4:34:31 PM UTC-5 Fotis Xenakis wrote:
>>
>>> Signed-off-by: Fotis Xenakis <fo...@windowslive.com> 
>>> --- 
>>> scripts/run.py | 5 ++++- 
>>> 1 file changed, 4 insertions(+), 1 deletion(-) 
>>>
>>> diff --git a/scripts/run.py b/scripts/run.py 
>>> index 71c6cdd7..6a81e98b 100755 
>>> --- a/scripts/run.py 
>>> +++ b/scripts/run.py 
>>> @@ -178,9 +178,10 @@ def start_osv_qemu(options): 
>>> "-drive", "file=%s,if=none,id=hd1" % (options.cloud_init_image)] 
>>>
>>> if options.virtio_fs_tag: 
>>> + dax = (",cache-size=%s" % options.virtio_fs_dax) if 
>>> options.virtio_fs_dax else "" 
>>> args += [ 
>>> "-chardev", "socket,id=char0,path=/tmp/vhostqemu", 
>>> - "-device", "vhost-user-fs-pci,queue-size=1024,chardev=char0,tag=%s" % 
>>> options.virtio_fs_tag, 
>>> + "-device", "vhost-user-fs-pci,queue-size=1024,chardev=char0,tag=%s%s" 
>>> % (options.virtio_fs_tag, dax), 
>>> "-object", 
>>> "memory-backend-file,id=mem,size=%s,mem-path=/dev/shm,share=on" % 
>>> options.memsize, 
>>> "-numa", "node,memdev=mem"] 
>>>
>>> @@ -602,6 +603,8 @@ if __name__ == "__main__": 
>>> help="virtio-fs device tag") 
>>> parser.add_argument("--virtio-fs-dir", action="store", 
>>> help="path to the directory exposed via virtio-fs mount") 
>>> + parser.add_argument("--virtio-fs-dax", action="store", 
>>> + help="DAX window size for virtio-fs device (disabled if not 
>>> specified)") 
>>> parser.add_argument("--mount-fs", default=[], action="append", 
>>> help="extra mounts (forwarded to respective kernel command line 
>>> option)") 
>>> parser.add_argument("--ip", default=[], action="append", 
>>> -- 
>>> 2.30.1 
>>>
>>>

-- 
You received this message because you are subscribed to the Google Groups "OSv 
Development" group.
To unsubscribe from this group and stop receiving emails from it, send an email 
to osv-dev+unsubscr...@googlegroups.com.
To view this discussion on the web visit 
https://groups.google.com/d/msgid/osv-dev/fd7dc8d8-30c1-481c-997c-e7bed43a27fcn%40googlegroups.com.

Reply via email to