Closed bsamek closed 6 years ago
I am seeing this also in an automated build.
I have the same issue, the majority of the times. @bsamek were you able to find a solution? Thanks
@adecarolis - No, I just run it in a loop.
I simply switched to using https://github.com/unibet/kitchen-transport-rsync as this issue was very annoying.
https://github.com/coderanger/kitchen-sync is a convenient workaround for Windows since rsync is kinda annoying to install
We pulled in a fix to instance store backed instances which are most often Amazon linux which should resolve this partially. Going to close this one out for now but happy to re-open a fresh issue with current versions if we need to hunt this one down more.
@cheeseplus What commit fixes this issue?
There were improvements to instance store backed instances here https://github.com/test-kitchen/kitchen-ec2/commit/fb12ad38b2ba07d6b382de33cf4d91f3f9f0b94d but also a lots of other movement in other deps in the ecosystem.
If this is still reproducible with current versions I'm happy to keep this open but we would needed updated logs, versions, and ideally a repro case
@cheeseplus I'm cool with closing this for now. Just wanted to see the code. Thanks again!
I'm afraid I still experience this issue when using kitchen-ec2 v2.2.1 and net-scp 1.2.1 :( Anyone else?
We have also observed similar behavior outside of test-kitchen. Occasionally our CI system can start a host in EC2 and run an SSH command. Then, some seconds later, when it attempts to SCP a small file onto the host, the SCP command returns host unreachable. I think the most probable explanation is that hosts aren't truly up yet, that there is some moment in the init process when the host is accessible over SSH, but then SSH restarts, for example.
We're running kitchen-ec2 as part of our CI workflow. About 3% of the time on Amazon Linux there is an error transferring files after installing Chef. We run on a variety of ec2 variants, including several versions of Debian, RHEL, SUSE, and Ubuntu, and I've only seen this on Amazon.
One thing that stands out to me is how much more quickly Amazon Linux instances boot than other instance types. Is it possible there is something that isn't yet ready about the instance even though ec2-kitchen can SSH into it? Does installing Chef use a different code path (i.e., not Net::SCP) than the transferring files step? If so, is it possible to insert a wait somewhere to give the instance some more time to prep?