VirtioFS Support Page


Recommended Posts

  • 2 weeks later...

There is a memory leak (happening with the latest VirtioFS driver too, in combination with WinFSP 2022). Give it enough memory and reboot the VM once in a while before the memory is full, that should help until someone figures out a fix. The memory fills up as files are accessed it seems...

 

I'm having worse issues though... VirtioFS just appears to be crashing. Used to work, but now after a short while the mounted drive just appears as empty. Any idea what could be wrong? Any fix? I tried installing WinFSP 2023, but that didn't help.

 

https://github.com/virtio-win/kvm-guest-drivers-windows/issues/776 Someone seems to have the same problem. Can't get the solution to work though.

Edited by kadajawi
Link to comment
3 hours ago, kadajawi said:

There is a memory leak (happening with the latest VirtioFS driver too, in combination with WinFSP 2022). Give it enough memory and reboot the VM once in a while before the memory is full, that should help until someone figures out a fix. The memory fills up as files are accessed it seems...

 

I'm having worse issues though... VirtioFS just appears to be crashing. Used to work, but now after a short while the mounted drive just appears as empty. Any idea what could be wrong? Any fix? I tried installing WinFSP 2023, but that didn't help.

 

https://github.com/virtio-win/kvm-guest-drivers-windows/issues/776 Someone seems to have the same problem. Can't get the solution to work though.

You could try updating to the lastest virtiofsd from https://gitlab.com/virtio-fs/virtiofsd/uploads/a3f40cdf8fd0754f13ab327b57bfe285/virtiofsd-v1.5.1.zip 

 

location in unraid is /usr/libexec. suggest renaming this to .old and replacing with version from zip. Not test my self to see if it works correctly.

 

New rust vers
root@computenode:/mnt/user/test2# ./virtiofsd --version
virtiofsd backend 1.5.1


root@computenode:/mnt/user/test2#  /usr/libexec/virtiofsd --version
virtiofsd version 7.1.0
Copyright (c) 2003-2022 Fabrice Bellard and the QEMU Project developers
using FUSE kernel interface version 7.36

 

Link to comment
7 hours ago, SimonF said:

You could try updating to the lastest virtiofsd from https://gitlab.com/virtio-fs/virtiofsd/uploads/a3f40cdf8fd0754f13ab327b57bfe285/virtiofsd-v1.5.1.zip 

 

location in unraid is /usr/libexec. suggest renaming this to .old and replacing with version from zip. Not test my self to see if it works correctly.

 

Thanks. I got it to work as you recommended, though I had to remove flock and posix_lock from the arguments. Will see if it crashes again or not. I hope those arguments aren't there for a good reason...?

 

Link to comment
2 hours ago, kadajawi said:

Thanks. I got it to work as you recommended, though I had to remove flock and posix_lock from the arguments. Will see if it crashes again or not. I hope those arguments aren't there for a good reason...?

 

Thanks for the report. They are not in the new vers. I will look to remove them from gui as with qemu 8 only the rust version is available.

  • Like 1
Link to comment

Hi there,

 

I've been fighting permission issues on Virtio-FS. They seem to react very weird when the system user does stuff. Example here would be: 

I like to move my downloads to another drive. So I use the "set location" feature in the properties of the downloads "favorites" (so file explorer, that favorites area -> downloads -> properties). Now it moves the folder but if I look at it's permissions on the unraid side it's set to up 550, which doesn't seem right. Esp when there's subfolders it just gives me the message "permission denied" while creating the subfolders (on windows side). 

 

Similar happens if I already make the folder myself. When I do that it creates the folder with 770. When I "set location" it removes permissions and set it to 550. 

 

This however doesn't seem to be the case for when I manually make folders/subfolders. This just get's the permissions 770... so what's going wrong here? The client is a Windows 11 machine with nothing special during install. 

Link to comment
  • 2 weeks later...
20 minutes ago, SimonF said:

Did you try the rust version of virtiofsd?

I had trouble getting this to work. I swapped the file out but after that my VM's wouldn't start. Also the changed file didn't persist across reboots so I'm sure I did something wrong. I'm assuming I have to set some permissions on the file but I honestly am not proficient enough with Linux to know what exactly I have to do.

Link to comment
40 minutes ago, mackid1993 said:

Does anyone know how to get the rust version of Virtiofsd to work. I'm sure I'm just missing something stupid. I connected to my server over SFTP to replace the file. I'm wondering if I should be replacing it a different way?

I would put rust version on flash and put the following in go file to make persistent at boot. but you can run the comand manually to test.

 

mv /usr/libexec/virtiofsd /usr/libexec/virtiofsd.old

cp /boot/xxx/virtiofsd /usr/libexec/virtiofsd 

chmod +x /usr/libexec/virtiofsd 

Link to comment
35 minutes ago, SimonF said:

I would put rust version on flash and put the following in go file to make persistent at boot. but you can run the comand manually to test.

 

mv /usr/libexec/virtiofsd /usr/libexec/virtiofsd.old

cp /boot/xxx/virtiofsd /usr/libexec/virtiofsd 

chmod +x /usr/libexec/virtiofsd 

@SimonF so I did this and replaced the file. When I add a few mounts and try to start my VM I get this error.

image.png.18f2932f3c3c2f872a7de8f6b1f3984c.png

Link to comment
On 4/4/2023 at 10:19 AM, kadajawi said:

Thanks. I got it to work as you recommended, though I had to remove flock and posix_lock from the arguments. Will see if it crashes again or not. I hope those arguments aren't there for a good reason...?

 

 

38 minutes ago, mackid1993 said:

@SimonF so I did this and replaced the file. When I add a few mounts and try to start my VM I get this error.

image.png.18f2932f3c3c2f872a7de8f6b1f3984c.png

I got this working, it took me a little while to figure out what flock and posix_lock meant. I edited the xml and switched those from on to off for each mount. Now Windows is booted. I'm going to test and report back tomorrow if it locked up. I'm doing a trial of Backblaze personal backup now to really stress test it. Thanks Simon!

Edited by mackid1993
grammar
Link to comment
3 hours ago, johnsanc said:

I mentioned this before, but for me it locks up just with the memory backing config and nothing else related to virtioFS. I don’t think the lockups are related to virtioFS at all. Focus should be directed elsewhere.

Perhaps the issue is related to QEMU and not Virtiofsd. 

Link to comment
3 minutes ago, SimonF said:

Thanks for testing we are looking to update qemu soon.

No problem. Let me know if there is anything else I can help test. I noticed with Virtiofsd 1.6.0 the lockup was more severe. RDP actually wouldn't connect. When I connected over VNC the lockscreen clock was frozen. Previously it would just get slower and slower and slower until it would gradually lock up. This time it completely froze. 

Link to comment

I'm using VirtioFS to create a secondary drive in my Windows Server 2012R2 VM that is linked to an unraid share.  My WS2012R2 VM was created from a physical copy of my old Windows Server that I had running prior to migrating over to Unraid.  I'm trying to get the VM working so that I can keep the AD/domain functions working for the time being for a number of Windows 10 PCs I have in the household.  In my old Windows Server setup, I had a D drive that was on a HDD where the Windows share folders are created.  The D drive/folders were not included in the virtualization of the server--I only included C drive.  I was hoping I can just link an unraid share to the VM using VirtioFS and have the VM access the file history, client backup, and other data I've copied over from the old server install.  

 

I was able to get the unraid share added to the VM.  It shows up as Z: drive.  I was hoping I can just modify the share folder within the Windows Server VM to point it to Z:.  But Windows Server isn't letting me choose the VirtioFS share.  Z: drive doesn't show up when I'm trying to remap the share folders.  I thought that by using VirtioFS it would make the unraid share look like a physical HDD within the VM.  Is that the case and I'm just configuring it incorrectly?  Or is that a limitation of VirtioFS for now?

Link to comment

Join the conversation

You can post now and register later. If you have an account, sign in now to post with your account.
Note: Your post will require moderator approval before it will be visible.

Guest
Reply to this topic...

×   Pasted as rich text.   Restore formatting

  Only 75 emoji are allowed.

×   Your link has been automatically embedded.   Display as a link instead

×   Your previous content has been restored.   Clear editor

×   You cannot paste images directly. Upload or insert images from URL.