Open Sirius902 opened 2 weeks ago
Thank you for reporting the issue!
Symlinks are a known place for the corner cases due to the different handling by Linux and Windows. We will look into this, but unfortunately not in a very near future
@Sirius902 I didn't reproduce this issue in my env with your steps, could you tell the virtiofsd version? Host/guest info: 5.14.0-494.el9.x86_64 virtiofsd-1.11.1-1.el9.x86_64 virtio-win-prewhql-0.1-262 Win11 23h3(os build 22631.3447)
Steps:
Create virtiofsd with root privilege:
mkdir /root/avocado/data/avocado-vt/virtio_fs_test/ &
/usr/libexec/virtiofsd --socket-path=/var/tmp/avocado-vt-vm1-fs-virtiofsd.sock -o source=/root/avocado/data/avocado-vt/virtio_fs_test/ -o cache=auto &
Create a symlink for a file
ln -s tmp.sh tmp-link.sh
lrwxrwxrwx 1 root root 6 Sep 18 08:34 tmp-link.sh -> tmp.sh
Start Win11 guest and start virtiofs service.
C:\>"C:\Program Files (x86)\WinFsp\bin\fsreg.bat" virtiofs C:\virtiofs.exe "-t %1 -m %2"
The operation completed successfully.
The operation completed successfully.
The operation completed successfully.
C:>"C:\Program Files (x86)\WinFsp\bin\launchctl-x64.exe" start virtiofs xiagao_fs1 myfs Y: OK
4. Opening the mounted virtiofs share in Windows Explorer, in my case it is Y: volume.
Results: No driver crash.
![image](https://github.com/user-attachments/assets/d5d655de-402c-4263-a73d-cd65b47b4526)
Ignore my last comment. It wasn't for self-symlink. The self-symlink indeed makes the virtiofs volume crash inside guest. I'll create an internal issue to track it.
Describe the bug Opening a mounted virtiofs share in Windows Explorer with a self-symlink inside will cause the guest's virtiofs driver to crash.
To Reproduce Steps to reproduce the behaviour:
cd
into it, and create a self-symlink in it withln -s bruh bruh
.Expected behavior I would expect the virtiofs driver not to crash and possibly show the offending self-symlink as a shortcut.
Screenshots
Event Viewer error text:
Host:
VM:
virtiofs.exe
Virtio-win-guest-tools 0.1.262