Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

provisioning via puppet requires rsync, which fails #2

Closed
vishagilityroots opened this issue Jul 24, 2017 · 2 comments
Closed

provisioning via puppet requires rsync, which fails #2

vishagilityroots opened this issue Jul 24, 2017 · 2 comments

Comments

@vishagilityroots
Copy link
Contributor

During provisioning phase, the Vagrant box needs to rsync several folders to the remote machine.
The remote directory does appear to get created but it fails unexpectedly.

DEBUG winrmshell: Output: #<WinRM::Output:0x0000000408c600 @data=[{:stdout=>"\r\n"}, {:stdout=>"\r\n"}, {:stdout=>"    Directory: C:\\tmp\\vagrant-puppet\r\n"}, {:stdout=>"\r\n"}, {:stdout=>"\r\n"}, {:stdout=>"Mode                LastWriteTime     Length Name                                                                                                                                                                                                        \r\n"}, {:stdout=>"----                -------------     ------ ----                                                                                                                                                                                                        \r\n"}, {:stdout=>"d----         7/24/2017   8:18 AM            manifests-aa0e7a61aebfb30adf6effefa1b25cdc                                                                                                                                                                  \r\n"}, {:stdout=>"\r\n"}, {:stdout=>"\r\n"}], @exitcode=0>
 INFO subprocess: Starting process: ["/usr/bin/rsync", "--verbose", "--archive", "--delete", "-z", "--copy-links", "--no-owner", "--no-group", "-e", "ssh -p 22 -o LogLevel=FATAL  -o ControlMaster=auto -o ControlPath=/tmp/ssh.248 -o ControlPersist=10m  -o IdentitiesOnly=yes -o StrictHostKeyChecking=no -o UserKnownHostsFile=/dev/null -i '/home/vagrant/.vagrant.d/insecure_private_key'", "--exclude", ".vagrant/", "/work/agilityroots/biztalk-provisioner/provisioning/environments/production/manifests/", "vagrant@ec2-13-126-91-144.ap-south-1.compute.amazonaws.com:/tmp/vagrant-puppet/manifests-aa0e7a61aebfb30adf6effefa1b25cdc"]
 INFO subprocess: Command not in installer, restoring original environment...
DEBUG subprocess: Selecting on IO
DEBUG subprocess: stderr: rsync: connection unexpectedly closed (0 bytes received so far) [sender]
rsync error: unexplained error (code 255) at io.c(226) [sender=3.1.0]
DEBUG subprocess: Waiting for process to exit. Remaining to timeout: 31872
DEBUG subprocess: Exit status: 255
ERROR warden: Error occurred: There was an error when attempting to rsync a synced folder.
Please inspect the error message below for more info.

Host path: /work/agilityroots/biztalk-provisioner/provisioning/environments/production/manifests/
Guest path: /tmp/vagrant-puppet/manifests-aa0e7a61aebfb30adf6effefa1b25cdc
Command: "rsync" "--verbose" "--archive" "--delete" "-z" "--copy-links" "--no-owner" "--no-group" "-e" "ssh -p 22 -o LogLevel=FATAL  -o ControlMaster=auto -o ControlPath=/tmp/ssh.248 -o ControlPersist=10m  -o IdentitiesOnly=yes -o StrictHostKeyChecking=no -o UserKnownHostsFile=/dev/null -i '/home/vagrant/.vagrant.d/insecure_private_key'" "--exclude" ".vagrant/" "/work/agilityroots/biztalk-provisioner/provisioning/environments/production/manifests/" "vagrant@ec2-13-126-91-144.ap-south-1.compute.amazonaws.com:/tmp/vagrant-puppet/manifests-aa0e7a61aebfb30adf6effefa1b25cdc"
Error: rsync: connection unexpectedly closed (0 bytes received so far) [sender]
rsync error: unexplained error (code 255) at io.c(226) [sender=3.1.0]

@vishagilityroots
Copy link
Contributor Author

If you look at the error

Guest path: /tmp/vagrant-puppet/manifests-aa0e7a61aebfb30adf6effefa1b25cdc
Command: "rsync" "--verbose" "--archive" "--delete" "-z" "--copy-links" "--no-owner" "--no-group" "-e" "ssh -p 22 -o LogLevel=FATAL  -o ControlMaster=auto -o ControlPath=/tmp/ssh.248 -o ControlPersist=10m  -o IdentitiesOnly=yes -o StrictHostKeyChecking=no -o UserKnownHostsFile=/dev/null -i '/home/vagrant/.vagrant.d/insecure_private_key'" "--exclude" ".vagrant/" "/work/agilityroots/biztalk-provisioner/provisioning/environments/production/manifests/" "vagrant@ec2-13-126-91-144.ap-south-1.compute.amazonaws.com:/tmp/vagrant-puppet/manifests-aa0e7a61aebfb30adf6effefa1b25cdc"
Error: rsync: connection unexpectedly closed (0 bytes received so far) [sender]

This error occurred on Cygwin; the paths are cygwin-specific and will not work on the Windows host. It appears I may have encountered hashicorp/vagrant#6702.

There are lots of comments in that issue that say Cygwin is not a good choice for Windows provisioning. I tried moving to cmd.exe.

@vishagilityroots
Copy link
Contributor Author

This should already be fixed by #5 .

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

No branches or pull requests

1 participant