-
Notifications
You must be signed in to change notification settings - Fork 104
New issue
Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.
By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.
Already on GitHub? Sign in to your account
add/remove virtio-fs file share after vm started #861
Comments
Currently, no. virtiofs uses a device per tag. So to add/remove a share after the VM has started, you will need to dynamically add/remove a device. This is fairly straightforward to implement if you're using the VPCI transport (supported only with Windows hosts due to KVM limitaitons). It's not possible if you're using the MMIO transport. An alternative approach is to create a single share and dynamically link files into the share as necessary. On Linux, you would probably do this with bind mounts, since virtiofs won't follow symbolic links on the host. On Windows, you could experiment with the bindlink API to do the same: https://learn.microsoft.com/en-us/windows/win32/bindlink/. A middle ground would be to teach virtiofs to support some kind of virtual file system that would allow you to add/remove sub-file systems (each backed by a real file system directory) as part of a single device. This would be a fair amount of work but would be useful to have. |
I don't think it would be unreasonable to have an optional virtiofs mode that follows directory junctions (but not symlinks) on Windows. I would probably accept a PR that does this. |
I can add a windows file share with the following parameter when starting openvmm.exe:
Is here a way (via interactive mode or RPC call) to add/remove virtio-fs file share after vm started?
The text was updated successfully, but these errors were encountered: