Jeremy Davis's picture

Having VBox tools pre-installed may be your preference (and perhaps ideal for your scenario), but using a shared folder from your Windows host may be easier than installing VBox tools? Samba uses SMB/CIFS which is Windows native filesharing. Obviously TKL Fileserver works as a fileserver (it's intended use) but it can also work as a client (ie connect to Windows shares) - so no additional software required to install on either TKL Fileserver or the Win host.

While this won't work OOTB for some TKL appliances (as most of them don't have Samba preinstalled) it works fine for the Fileserver appliance. Even for the other appliances, if you only want to connect to a remote Win share (rather than create SMB/CIFS shares in Linux) this is easily configured. I have just created a wiki page on how to do this (I was going to post here but figured a wiki page may be better).

So you could easily create a script to configure this automatically for any new TKL appliances you install. Here is an example script (adjust the variables to suit your setup) that you could copy/paste in. Another alternative is to save the script on your host and copy it across (eg with SFTP via Filezilla or similar).

Create the file:

nano automountcifs.sh

the script:

#!/bin/bash -ex
# script to configure TKL appliance to connect to a remote Windows share

# set variables - adjust the value on the right to suit your system
winserver=WinPC
winshare=share
winuser=Win-user
pass=pass
workgroup=WORKGROUP
localfolder=/media/win-share

# install smbfs - uncomment if using on TKL appliance other than Fileserver
#apt-get update && apt-get install smbfs -y

mkdir $localfolder
echo "//$winserver/$winshare $localfolder cifs username=$winuser,password=$pass,workgroup=$workgroup 0 0" >> /etc/fstab

make it executable:

chmod +x automountcifs.sh

and run it:

./automountcifs.sh

As fstab is readable by anyone your password will be readable by all. There are a number of ways to get around that if you desire, but i wanted to keep it simple.

FWIW VMware server is free (but not open source) last time I used it, although I never used the host shared folders but AFAIK it should work OOTB (as I said VMware tools should be installed and ready to go on TKL VM appliances).