Hello,
I have Virtualbox 6.1.4 on a Windows 10 guest both fully updated. Through that I have a Red Hat Enterprise Linux 8.1 virtual machine (with guest additions 6.1.4) with two shared folders with "Access" set to full and auto-mount enabled. I added my virtual machine user to the vboxsf group and I can see and open files in those two shares from the virtual machine.
However, there are two problems:
1. I often can't save my changes to files I edit in those shares. For example, if I use Gnome's text editor to open, edit, and try to save a pure text file in the share, I get a "file busy" error. In Visual Studio Code, the error is simply permission denied. By using the `ls -lh` command in a terminal, I see that the files and folders in the share are owned by root:vboxsf with read and write privileges to the root user and the vboxsf group. Strangely, if I use the `nano` editor from the terminal, I can edit and write to the same file just fine.
2. Sometimes, a seemingly random assortment of files and folders inside the share would show up as belonging to nobody:nobody, and I can access them even with the `sudo` command.
How can I troubleshoot these problems? Thank you.
Shared folder in Linux guest permissions problems
-
- Site Moderator
- Posts: 20945
- Joined: 30. Dec 2009, 20:14
- Primary OS: MS Windows 10
- VBox Version: PUEL
- Guest OSses: Windows, Linux
Re: Shared folder in Linux guest permissions problems
If you set these shared folders via the Virtualbox settings, then they are Guest Additions Shared Folders. GASFs are not real shared folders. They are only for file transfer, not for running, saving, databases, etc.
Make a real shared folder on the host PC OS and use a Virtualbox Bridged or Host-Only network between the guest & host to access the real shared folder, then you will be able to do anything a normal networked shared folder can support.
Make a real shared folder on the host PC OS and use a Virtualbox Bridged or Host-Only network between the guest & host to access the real shared folder, then you will be able to do anything a normal networked shared folder can support.
Re: Shared folder in Linux guest permissions problems
Thanks for getting back to me so quickly.
So are the problems I described expected and normal for a Guest Additions shared folder?scottgus1 wrote:They are only for file transfer, not for running, saving, databases, etc.
Let me try this and report back.scottgus1 wrote:Make a real shared folder on the host PC OS and use a Virtualbox Bridged or Host-Only network between the guest & host to access the real shared folder, then you will be able to do anything a normal networked shared folder can support.
-
- Site Moderator
- Posts: 20945
- Joined: 30. Dec 2009, 20:14
- Primary OS: MS Windows 10
- VBox Version: PUEL
- Guest OSses: Windows, Linux
Re: Shared folder in Linux guest permissions problems
GASFs were only designed for passing files between the host & guest, so one didn't have to set up a network. There are a lot of protocols that were not programmed into GASFs.avamk wrote:So are the problems I described expected and normal for a Guest Additions shared folder?
While it would be rather hard to predict a particular problem, if the operation is not ultimately a simple file copy, then a GASF might have problems with the operation.