How To: Connect to a Linux shared drive from a Windows guest in VMware

I always forget how to do this, so I’m writing it down…

1 – Getting and installing VMware Tools

First, we’ll need the VMware Tools installed. If VMware is being a dick and failing to get the tools ISO automatically then you can power down the VM, then in the main VMware Player window before you’ve opened any VM up, go to File | Player Preferences and click [Download All Components Now].

Once done, the iso files will be in a location such as: /usr/lib/vmware/isoimages. In this case (with a Windows 10 guest) I want the windows.iso image – so launch the VM, mount the ISO (from Virtual Machine | Removable Devices | CD/DVD | Settings…) then go to “This PC”, right-click on the mounted drive and select “Open Autoplay…” and let it install.

Update – 2017-03-03

Sometimes VMware tools is also a dick and needs repairing, so do the above but select the “Repair” option to uninstall/re-install it, then power down the VM.

As I found out today, the repair option is rubbish and doesn’t work – to get mapping of network drives working if it isn’t already you need to completely uninstall VMware tools in your guest OS, then reboot, then reinstall VMware tools, then reboot again. On this final reboot (and assuming you have the ‘Map to network drive’ option ticked in your VM settings – see below) then it should all be sorted and if you go to My PC | Network you should see a vmware-host folder which is mapped to Z: (by default – map it to something else if you want to) – from which you can then use Z:\WHATEVER_SHARE_NAME_YOU_GAVE to access your shared folders.

2 – Enabling Shared Folders

With the VM still off, go to the settings for your virtual machine select the Options tab and then the Shared Folders option, then select the “Always Enabled” radio-button. Now add a folder to share and give it a friendly name, I chose “Linux” and pointed it at my linux user’s home folder (so for me that’d be “/home/r3dux”).

I haven’t been able to get the “Map as a network drive in Windows guests” option working for a while, but it shouldn’t be a massive problem as you can access it via the double-backslash notation in the next step.

3 – Access the shared folder from the guest

Boot up your VM (i.e. Windows guest), and from the search bar or URL entry in windows explorer enter:

So for example, I’d access my shared folder via going to:

This should work, or at least it works fine for me. However, if I try to map the drive – like if I want to map that location to Z:, and I enter the exact same (known working) path to the shared folder… it doesn’t work. And I have absolutely no idea why. If you let the troubleshooter run it just shrugs at you, which to be fair is basically all any Windows troubleshooter has pretty much ever done in my experience.

To access the network shared folder easily without assigning a drive letter you can just go up one level (i.e. to \\vmware-host\Shared Folders) and then right-click on your shared folder and choose to send a shortcut to the windows desktop, from which you can access it easily enough just like any other folder.

Wrap Up

Hope this gets things working for you, even if it won’t map the drive to a letter for some bizarre reason. If you figure out why that might be I’d love to know!.

Cheers!

How To: Migrate a VirtualBox Windows 7 client to VMware Player

Step 0 – [Linux-specific instruction] When installing VMware Player, let it use /etc/init.d/ even if your system uses Systemd. After install you can create a service for vmware like this:

/etc/systemd/system/vmware.service

Start the service with systemctl start vmware to make sure it kicks off. If you want it to start automatically at boot use systemctl enable vmware.

Step 1 – Disable any devices in the virtual machine that run on VirtualBox/Oracle drivers.

Step 2 – Convert the VirtualBox.vdi hard drive to VMDK format via “vboxmanage clonehd source.vdi target.vmdk –format VMDK”

Step 3 – Launch vmplayer and create a new virtual machine. Say that you’ll add the operating system later and let it use a ‘single large drive’ or such.

Step 4 – Replace the default created .vmdk drive with the one you converted in step 2.

Step 5 – You can try booting your VM at this point – if it works, GREAT! But it’s likely to bluescreen with a 0x000007b error, if so you’ll need to follow the rest of the steps below:

With all that done, the Windows 7 client should boot in vmware player and start installing the VMware specific drivers.

Twiddles / Housekeeping

VM audio crackling? Live with it – it crackles for a few seconds then sorts itself out. Fixing it as per the below causes VM crashes with “vcpu-0 unexpected signal 11” errors.
In Windows client go: Control Panel | Hardware and Audio | Sound | Speakers | Properties | set it to 24-bit @ 44.1KHz or higher.
Source: http://kb.vmware.com/selfservice/microsites/search.do?language=en_US&cmd=displayKC&externalId=2012007

VM suspends and stops Linux host from suspending? Shut down the VM, then edit the .VMX file it and add the line suspend.disabled = “TRUE” then restart.

VM generating “spurius APIC interrupt on #CPU X, should never happen”? Edit /etc/vmware/config and add the line monitor_control.disable_hostedIPI = TRUE then restart VM.

VMware tools won’t install? Either try to find the ISO to mount and install from or install ncurses5-compat-libs – on Arch this is in the AUR at: https://aur.archlinux.org/packages/ncurses5-compat-libs/