Setup Share Folder for Fedora27/28 Guested in Virtual Box 5.2
FedoraForum.org - Fedora Support Forums and Community
Results 1 to 8 of 8
  1. #1
    Join Date
    May 2018
    Location
    philadelphia
    Posts
    1

    Setup Share Folder for Fedora27/28 Guested in Virtual Box 5.2

    Just took a little bit time to get Share Folder to work on Fedora 27 and Fedora 28 in Virtual Box 5.2. The below steps are for Fedora-MATE_Compiz-Live-x86_64-27-1.6 but could also be applied on Fedora 28. I verified with https://download.fedoraproject.org/p..._64-28-1.1.iso

    1.First install Virtual Box 5.2 as https://www.if-not-true-then-false.c...-red-hat-rhel/

    2. Install
    Fedora-MATE_Compiz-Live-x86_64-27-1.6.iso
    https://download-ib01.fedoraproject....ns/x86_64/iso/

    3. Download VBoxGuestAdditions_5.2.10.iso from https://download.virtualbox.org/virt...ons_5.2.10.iso

    4. To build kernel modules of Guest Additions, need to install:
    Install gcc and / or g++ and it’s related Development Tools:

    dnf group install 'Development Tools’
    yum -y install kernel-devel kernel-headers
    export kernel_headers=`ls -hd /usr/src/kernels/4*`
    sudo ln -s ${kernel_headers}/include/generated/uapi/linux/version.h ${kernel_headers}/include/linux/version.h

    After installation, Kernel source should be under “ls /usr/src/kernels/$(uname -r)”
    Now check “uname -r” --> 4.13.9-300.fc27.x86_64
    Make sure the version of installed kernel-devel and kernel-headers packages having the same version.

    In case there is mismatch, just:
    Remove the packages:
    sudo yum install "kernel-devel-uname-r == $(uname -r)"
    Or,
    sudo yum update
    to make sure you are running the latest F27 kernel as well as the latest packages installed.
    Then after a bunch of upgrade, building main Guest Additions module hit error:

    "Makefile:978: *** "Cannot generate ORC metadata for CONFIG_UNWINDER_ORC=y, please install libelf-dev, libelf-devel or elfutils-libelf-devel". Stop."

    Install elfutils-libelf
    dnf install elfutils elfutils-libelf
    dnf install elfutils-libelf-devel

    Better check the results from the two commands:
    yum list |grep elfutils-libelf
    rpm -qa |grep elfutils-libelf

    If there is mismatch, the problem is where you have a package from updates-testing but that repo's been disabled by the fedora-release update. Enable updates-testing again by:

    yum --enablerepo=u*g install elfutils-libelf-devel

    5. After finishing all the above steps, you can build the kernel modules. An error may come up when it finished compiling the modules and tried to `modprobe vboxsf`, and rebooting the guest OS VM would fix that.

    6. To verify 'Guest Additions' properly installed, use
    cat /proc/filesystems
    You should see shared folder is accessible under `/media/sf_SHAREDNAME/`

    7. Finally, add your username to the vboxsf group by:
    sudo usermod -G vboxsf -a <username>

  2. #2
    Join Date
    Apr 2018
    Location
    California
    Posts
    32

    Re: Setup Share Folder for Fedora27/28 Guested in Virtual Box 5.2

    Great tutorial! A couple of quick notes/comments:

    3) The VirtualBox Guest Additions ISO file is part of the VirtualBox installation, so there's no need to download it
    (found here: /usr/share/virtualbox/VBoxGuestAdditions.iso)
    I would also strongly suggest installing the VirtualBox Extension Pack.

    6) When adding shared folders in Linux VMs, make sure that the shared folder is a real folder, not a symlink. This doesn't seem to be a problem in Windows (at least not my Windows7-64bit VM), but on Fedora 27/28, Mint 18.3, & OpenSUSE Tumbleweed/LEAP it was an issue.

    Thanks again for posting this.

  3. #3
    Join Date
    Feb 2018
    Location
    Home
    Posts
    58

    Re: Setup Share Folder for Fedora27/28 Guested in Virtual Box 5.2

    I have just installed Fedora28 on Virtualbox. On my Windows 10 host, I have a shared folder I created on my desktop named Windows_share. I shared the folder to everyone and gave everyone access. On Fedora28, I do see /media/sf_Windows_share. On my Windows 10 host, I created a test file in the shared folder, but I'm not seeing the file from the Fedora guest. I did make my Fedora user a member of the vboxsf. Why can't I see the test file? Please advise. Thanks.

  4. #4
    Join Date
    Apr 2018
    Location
    California
    Posts
    32

    Re: Setup Share Folder for Fedora27/28 Guested in Virtual Box 5.2

    I've only done this the other direction - Linux host, Windows VM. A couple of questions:
    1) Is the version of VirtualBox (main program & Guest Additions) the same of both systems?
    2) Is the share on Windows a real folder or a shortcut?
    3) Can you create a file on the Fedora side that shows up on the Windows side?
    4) What are the permissions on the Windows share?

  5. #5
    Join Date
    Feb 2018
    Location
    Home
    Posts
    58

    Re: Setup Share Folder for Fedora27/28 Guested in Virtual Box 5.2

    I have replies next to each question. Thanks.
    Quote Originally Posted by ajgringo619
    I've only done this the other direction - Linux host, Windows VM. A couple of questions:
    1) Is the version of VirtualBox (main program & Guest Additions) the same of both systems? VirtualBox is version 5.2.12 as is the guest additions.
    2) Is the share on Windows a real folder or a shortcut? It is a real folder.
    3) Can you create a file on the Fedora side that shows up on the Windows side? I have created a file on the Fedora side. No, it does not show up in the folder on the Windows side.
    4) What are the permissions on the Windows share? The permissions on the Windows share is that everyone can read and write.
    Last edited by chiguy1256; 29th May 2018 at 01:43 AM.

  6. #6
    Join Date
    Apr 2018
    Location
    California
    Posts
    32

    Re: Setup Share Folder for Fedora27/28 Guested in Virtual Box 5.2

    1) On Fedora: rpm -qa | grep VirtualBox
    On Windows: start VirtualBox, click "Help", then select "About..."
    2) OK
    3) This is getting weirder. I had Fedora 28 as the host sharing (2) USB drives, one NTFS and the other EXT4, and Windows 7 has the guest and never had this problem. In fact, Windows 7 (as the guest) is the only guest platform that I haven't had any significant issues.

    Do you have the time/patience to try another distro of Linux to see if the issue persists? Fedora 27 is much more stable (as expected).

  7. #7
    Join Date
    Feb 2018
    Location
    Home
    Posts
    58

    Re: Setup Share Folder for Fedora27/28 Guested in Virtual Box 5.2

    My replies are below, next to each item quoted.
    Quote Originally Posted by ajgringo619
    1) On Fedora: rpm -qa | grep VirtualBox "I do not get any results when I run this command."
    On Windows: start VirtualBox, click "Help", then select "About..." "I have version 5.2.12."
    2) OK
    3) This is getting weirder. I had Fedora 28 as the host sharing (2) USB drives, one NTFS and the other EXT4, and Windows 7 has the guest and never had this problem. In fact, Windows 7 (as the guest) is the only guest platform that I haven't had any significant issues.

    Do you have the time/patience to try another distro of Linux to see if the issue persists? Fedora 27 is much more stable (as expected). "I may try Fedora 27 instead.
    I have running on another machine also in VirtualBox and then upgraded to Fedora 28, but do not have problems with the shared folder."

  8. #8
    Join Date
    Feb 2018
    Location
    Home
    Posts
    58

    Re: Setup Share Folder for Fedora27/28 Guested in Virtual Box 5.2

    ajgringo619, I downloaded Fedora 27 yesterday and installed it as a new VM guest. I followed your instructions for shared folders and it worked fine. I then upgraded to Fedora 28 and the shared folder is still working properly. So, I agree with you in that there is definitely an issue if a users tries shared folders from a fresh version of Fedora 28. Thank you.

Similar Threads

  1. samba share folder in mnt .
    By mypass604 in forum Servers & Networking
    Replies: 3
    Last Post: 4th December 2015, 06:59 AM
  2. Can't share folder via samba
    By MasterSergius in forum Servers & Networking
    Replies: 10
    Last Post: 17th March 2015, 11:31 PM
  3. /usr/share folder gone
    By Falconus in forum Using Fedora
    Replies: 4
    Last Post: 17th September 2009, 10:09 PM
  4. Share folder mac an ms
    By ardainbox in forum Using Fedora
    Replies: 0
    Last Post: 1st March 2007, 11:11 AM
  5. Share folder for all users?
    By gnomicGhost in forum Using Fedora
    Replies: 3
    Last Post: 19th April 2006, 08:35 PM

Tags for this Thread

Posting Permissions

  • You may not post new threads
  • You may not post replies
  • You may not post attachments
  • You may not edit your posts
  •