How to share folders b/n VirtualBox and Win 7 using NAT adapter and Samba

11,087

Solution 1

You can have two network adapters configured and use them at the same time. Use the Host-only as well as the NAT adapter. In the Virtualbox settings page just add another network adapter.

Solution 2

In your VirtualBox GUI click on your VM. - then click Settings (Ctrl+S) - click Network - click Advanced - click Port Forwarding

Configure port forwarding on ports 139 and 445

This port forwarding setup will work only if you don't have samba on your HOST machine, otherwise those port are reserved so virtualbox can not take them over to forward to your guest machine.

Better solution to share files between Host and Guest machine is to install and configure VirtualBox Guest Additions.

Solution 3

What OS do you have installed on yor VM ¿? ... The only way (for me to know) for get in work the share over NAT it's with the VBox Guest Additions...

It is not very difficult to install the guest additions; assuming you have an *buntu OS Family, mint or even debian linux, you can try this tutorials...

DEBIAN
*BUNTU

Then you can test the connection again ...

Share:
11,087

Related videos on Youtube

iOi
Author by

iOi

Do the world a favor and

Updated on June 04, 2022

Comments

  • iOi
    iOi almost 2 years

    When I had my Adapter set to Host Only I followed this tutorial and was able to view the folder # \samba\share\ only buy typing \\192.168.55.444 in my windows start up. So, this means I could share this folder without any problem between two machines. But, now that I have switched to NAT adapter, and my ifconfig eth0 shows this as the host address 10.0.2.15 I am unable to access my samba shared folder no matter how I try to access it.

  • iOi
    iOi about 10 years
    Thanks for the response. But I could not get guest additions to work. I have been trying literally for weeks. And I have finally given up. But, I don't understand about the port forwarding. Do I just enter the ports? What about the IP? Leave them blank?
  • iOi
    iOi about 10 years
    I have CentOs 6.4. I hope you have some experience with it, because it is driving me crazy
  • victorjordan
    victorjordan about 10 years
    Directly from the wiki -->, and from the Official --> sorry for my english :)
  • blamb
    blamb over 6 years
    I know this is old, but if you couldnt get guest add's working, wanted to note that you need to mount the drive after each reboot, until you get it into fstab
  • phil
    phil over 5 years
    With this I was able to finally access guest shared folders from the host