VMware Communities
Mike101
Contributor
Contributor

can not copy file from window host to linux guest

I have installed the workstation tools but still can not copy files from window host to linux guest. Do I need to do any configuration after installed the tools on guest (linux) OS?

Or any other things missing.

Thanks,

Mike

Reply
0 Kudos
11 Replies
alelievre
Enthusiast
Enthusiast

You might run this command after installing tools on your linux guest:

/usr/bin/vmware-config-tools.pl

Reply
0 Kudos
Mike101
Contributor
Contributor

I have tried but still can not copy files from host to guest. Are there any firewalls in Suse could stop it from transferring or any thing from window side?

Reply
0 Kudos
KKeezer
Contributor
Contributor

Hi Mike,

Not sure if this is any help but I found this info..

Copying between Windows and Linux

You again have several options for copying files to and from windows.

  1. Shared Folders

The easiest option in VMware workstation is shared folders. You can specify which linux directories you want to appear as network places in your windows partition

  1. Traditional network tools

If you want to access files from a range of machines then installing an ftp client on the windows machine is again fairly easy and trouble free. A dedicate samba share will also work fine

  1. VMware API

VMware also comes with an C and a simple perl api set to run commands on the windows guest OS, this includes copying files between the two. The perl api [[1]|http://www.vmware.com/pdf/Prog_API_Ref_Guide.pdf|http://www.VMware.com/pdf/Prog API Ref Guide.pdf] provides the following

VMCopyFileFromGuestToHost

VMCopyFileFromHostToGuest

VMRunProgramInGuest

Hari created a simple wrapper for us to also retrieve the appropriate vm handle from the server and login. (a combination of HostConnect, FindRunningVms, VMOpen and finally VMLoginInGuest]

Link Source: http://developer.spikesource.com/wiki/index.php/Tips_for_windows_vmware_images_on_linux

Good Luck,

Kyle


If you found this information useful, please consider awarding points for "Correct" or "Helpful" answers/replies. Thanks!!
Reply
0 Kudos
lamw
Community Manager
Community Manager

If you're running VMware WS 6.5.1, I believe that supports VMware VIX 1.6.2 and vmrun and if you have VMware Tools installed on your Linux guestOS, you can use vmrun to upload/download files from your hosted OS to your guest OS.

You can find more information about VIX here

Also take a look at vmrun command documentation for further command details

=========================================================================

--William

VMware ESX/ESXi scripts and resources at:

Reply
0 Kudos
Mike101
Contributor
Contributor

Hi, thanks for quick response.

I am interested in the first option. Can you give more detail on how to implement that solution? I tried to make window share certain folders but no success. It told me that folder was shared but when I checked it again it still was not shared. How to make linux folder as shared network places?

Also, why Drag and drop or copy and paste is not working?

Reply
0 Kudos
Mike101
Contributor
Contributor

I am not familiar with VIX. Could I just download it, install it and using it right away without any coding or need to do some coding (an API)?

Reply
0 Kudos
wila
Immortal
Immortal

The VIX api is already installed with VMware Workstation 6.5 and you can use the vmrun command in batch files or straight from the command line.

copyFileFromHostToGuest  Path to vmx file     Copy a file from host OS to guest OS
                         Path on host
                         Path in guest

copyFileFromGuestToHost  Path to vmx file     Copy a file from guest OS to host OS

Here's an example:

http://www.vi-toolkit.com/wiki/index.php/Vmrun_return_all_IPs_for_running_VMs

You can drop the whole host url/user/password bit on workstation so it changes into:

vmrun -T ws -gu root -gp passwd copyFileFromGuestToHost "[standard] test/SLES10sp1.vmx" /tmp/ip-info.txt /host/path/ip-info.txt"

Also type "vmrun" without anything behind it to get help with a list of examples.



--

Wil

_____________________________________________________

Visit the new VMware developers wiki at http://www.vi-toolkit.com

| Author of Vimalin. The virtual machine Backup app for VMware Fusion, VMware Workstation and Player |
| More info at vimalin.com | Twitter @wilva
Reply
0 Kudos
Mike101
Contributor
Contributor

Where to invoke the vmrun command? I meant under which directory to call the command?

Reply
0 Kudos
wila
Immortal
Immortal

Hey I'm spoiled as I usually run this from a linux host and there it just works everywhere Smiley Wink

But I booted my windows box and its here:

C:\Program Files\VMware\VMware VIX\



--

Wil

_____________________________________________________

Visit the new VMware developers wiki at http://www.vi-toolkit.com

| Author of Vimalin. The virtual machine Backup app for VMware Fusion, VMware Workstation and Player |
| More info at vimalin.com | Twitter @wilva
Reply
0 Kudos
wila
Immortal
Immortal

Hi,

It sounds like your vmware tools are not completely installed somehow.

What linux distribution and version are you running? Never mind, you said suse, I do not have a SUSE guest right away now. But there's a up-to-date vmware tools under Yast if you are running a really new SUSE distribution.

I've just tried here with a ubuntu breezy (yeah really old) VM and I can drag & drop both ways (from linux to windows and the other way around)

The share also works and should show up under:

/mnt/hgfs/yourfolder



--

Wil

_____________________________________________________

Visit the new VMware developers wiki at http://www.vi-toolkit.com

| Author of Vimalin. The virtual machine Backup app for VMware Fusion, VMware Workstation and Player |
| More info at vimalin.com | Twitter @wilva
Reply
0 Kudos
Mike101
Contributor
Contributor

It is installed on window side but it is empty on linux under the mnt\hgfs\ . My Linux is Suse server 10.

Thanks.

Reply
0 Kudos