shared folder Access denied.

Discussions about using Linux guests in VirtualBox.
Post Reply
MattC13
Posts: 33
Joined: 7. Feb 2020, 22:53

shared folder Access denied.

Post by MattC13 »

Additional issue:

Unable to open a shared folder. The shared folder 'Public' is set up as it is in Windows VMs. The folder appears in the 'Places' on the left hand column in the file manager of the VM as 'sf_Public' (with the eject button). However, clicking on the device, produces a 'Failed to open directory "sf_Public". Access denied.

Matt
Last edited by scottgus1 on 13. Mar 2023, 18:32, edited 1 time in total.
Reason: changed title to reflect problem
warpino
Posts: 5
Joined: 6. Nov 2021, 14:24

Re: GA Not Installing On Linux Mint 21

Post by warpino »

I guess the user should be added to group vboxsf
scottgus1
Site Moderator
Posts: 20965
Joined: 30. Dec 2009, 20:14
Primary OS: MS Windows 10
VBox Version: PUEL
Guest OSses: Windows, Linux

Re: GA Not Installing On Linux Mint 21

Post by scottgus1 »

MattC13 wrote:Additional issue:
One issue per thread
MattC13
Posts: 33
Joined: 7. Feb 2020, 22:53

Re: shared folder Access denied.

Post by MattC13 »

scottgus1 wrote:One issue per thread
Appologies.
warpino wrote:I guess the user should be added to group vboxsf
Not sure what this means.

Matt
MattC13
Posts: 33
Joined: 7. Feb 2020, 22:53

Re: shared folder Access denied.

Post by MattC13 »

I'm guessing that this problem is an unknown one, and no one seems to know how to solve it. I'm trying to transfer large files between the host and guest, and this has always been the way I do it. If there is no way to solve this, is there another way?

Matt
mpack
Site Moderator
Posts: 39156
Joined: 4. Sep 2008, 17:09
Primary OS: MS Windows 10
VBox Version: PUEL
Guest OSses: Mostly XP

Re: shared folder Access denied.

Post by mpack »

You were already given a suggestion: add your Linux user to the "vboxsf" group in your Linux. I'm afraid that you are expected to know how to use the OS's you install, as there is limited scope for tuition on these forums while remaining on topic (i.e. VirtualBox).
ufguy
Posts: 40
Joined: 4. Jun 2023, 16:43

Re: shared folder Access denied.

Post by ufguy »

I did this last night and it worked. Root owns the folder but it is also in the vboxsf group.

ls -l in the media folder shows something like this:
drwxrwx--- 1 root vboxsf sf_share

where root owns it and vboxsf is the group it belongs to.

I had to add the user to the vboxsf group. Then to get to work I had to reboot. Some say you just have to log out and back in but that didn't work.

After the reboot the user could enter the sf_share folder and access the files there.
ufguy
Posts: 40
Joined: 4. Jun 2023, 16:43

Re: shared folder Access denied.

Post by ufguy »

I think this is how it works if you check the "guest additions" box before you install the system. That's on the second "page" of the Create Virtual Machine dialog, "Unattended Guest OS Install Setup:". Towards the bottom left. This may not always be an option.

If it's checked then your user is a member of vboxsf
If it isn't checked then your user is not a member of vboxsf

I had an Ubuntu VM running where the user was a member of vboxsf and I hadn't added that user to that group.
Did some checking and the above outcomes is what I discovered.
VB_user23
Posts: 1
Joined: 14. Jun 2023, 11:04

Re: shared folder Access denied.

Post by VB_user23 »

Hello!

I have a weird issue with VB Version 7.0.8 r156879 (Qt5.15.2) on Win 10 Ent, Guest OS - Ubuntu 22.04. User is a member of vboxsf group.
Problem description:
I can't copy to or edit files in the shared folders. When I copy files, they appear in the folder but "File already exist" error reported.
When I'm trying to edit and save a Python or text file with a Nano editor, it alters successfully but if any editor which uses a temporary file used, it can't save the file reporting "File is busy". Also it is not possible to rename files/folders deeper than share root.
Chown/chgrp have no effect on the shared folders.

Any suggestions are appreciated.
ufguy
Posts: 40
Joined: 4. Jun 2023, 16:43

Re: shared folder Access denied.

Post by ufguy »

I had something weird like this happen after you mentioned it. It looks isolated to the shared folders directory.

I did a test with the problem program in a directory with the same owner and group as the shared folder. Worked fine.

In the shared folder I can't "save" but I can "save as" and things work ok.

Even as root the program acts the same way. Something to do with a temporary file.
ufguy
Posts: 40
Joined: 4. Jun 2023, 16:43

Re: shared folder Access denied.

Post by ufguy »

This might be an old issue that people have been running across:
viewtopic.php?t=81264
https://www.virtualbox.org/ticket/2553

That has to do with Gedit but on the surface it sounds like its the same thing were running into.

I'm running into it with Mousepad, which is made for Xfce.
The problem does not manifest with XEmacs so it isn't a universal problem.

I'm not sure if this issue needs it's own thread or not.
Post Reply