Search code examples
windowscygwinvagrantrsynccoreos

Using rsync with a vagrant CoreOS vm on windows


I am running windows 8.1 Pro and have installed rsync using cygwin and have a vagrant vm configured as follows (base image is coreOS)

config.vm.synced_folder "../sharedFolder", "/vagrant_data", type: "rsync"

When i execute vagrant reload or vagrant up however I get the following error. Do you have any idea how i can go around the problem?

C:\dev\vagrantBoxes\coreOS>vagrant reload
==> default: Attempting graceful shutdown of VM...
==> default: Checking if box 'yungsang/coreos' is up to date...
==> default: Clearing any previously set forwarded ports...
==> default: Clearing any previously set network interfaces...
==> default: Preparing network interfaces based on configuration...
    default: Adapter 1: nat
==> default: Forwarding ports...
    default: 22 => 2222 (adapter 1)
==> default: Running 'pre-boot' VM customizations...
==> default: Booting VM...
==> default: Waiting for machine to boot. This may take a few minutes...
    default: SSH address: 127.0.0.1:2222
    default: SSH username: core
    default: SSH auth method: private key
    default: Warning: Connection timeout. Retrying...
==> default: Machine booted and ready!
==> default: Rsyncing folder: /c/dev/vagrantBoxes/sharedFolder/ => /vagrant_data
There was an error when attempting to rsync a synced folder.
Please inspect the error message below for more info.

Host path: /c/dev/vagrantBoxes/sharedFolder/
Guest path: /vagrant_data
Command: rsync --verbose --archive --delete -z --copy-links --chmod=ugo=rwX --no-perms --no-owner --no-group --rsync-path sudo rsync -e ssh -p 2222 -o StrictHostKeyChecking=no -o UserKnownHostsFile=/d
ev/null -i 'C:/Users/aaron.axisa/.vagrant.d/insecure_private_key' --exclude .vagrant/ /c/dev/vagrantBoxes/sharedFolder/ [email protected]:/vagrant_data
Error: Warning: Permanently added '[127.0.0.1]:2222' (RSA) to the list of known hosts.
rsync: connection unexpectedly closed (0 bytes received so far) [Receiver]
rsync error: error in rsync protocol data stream (code 12) at io.c(601) [Receiver=3.0.8]
rsync: read error: Connection reset by peer (104)
rsync error: error in rsync protocol data stream (code 12) at io.c(759) [sender=3.0.6]

Solution

  • This particular error was solved.

    I had previously installed the sourceforge version of rsync and my PATH was still set to that rsync. When i configured it to use the cygwin version the error changed. I'll post the new error in a different question since it's not the same problem.

    New Question : 25687808