wpengine / github-action-wpe-site-deploy

A GitHub Action to deploy code directly to WP Engine.
MIT License
173 stars 36 forks source link

RSYNC Error - Error in RSYNC Protocol #88

Open samfrank opened 6 months ago

samfrank commented 6 months ago

Hey guys!

I can to run the action when deploying once of my sites, two days after a successful deploy to the env and I received this error rsync error: error in rsync protocol data stream (code 12) at io.c(228) [sender=v3.13.0_rc2-264-g725ac7fb] (full error log at the bottom). I have not changed the script over the either. Sometimes I get errors and I just run a redeploy and normally it sorts itself out and I noticed on this ticket, they kind of said the same thing here.

This is my script that takes the PHP files and transfers them to the WPE Env. I am not confident that this would reproduce the issue that I am having.

            - name: Deploy - Files to WPEngine Staging
              if: contains(github.ref, 'develop')
              uses: wpengine/github-action-wpe-site-deploy@v3.0
              with:
                  # Deploy vars
                  WPE_SSHG_KEY_PRIVATE: ${{ secrets.WPE_SSHG_KEY_PRIVATE }}
                  WPE_ENV: ${{ secrets.WPE_INSTALL_STAGING }}
                  # Deploy Options
                  REMOTE_PATH: 'wp-content/themes/theme-name-2023/'
                  PHP_LINT: FALSE
                  FLAGS: -azvr --inplace --delete --exclude=".*"
Deploying refs/heads/develop to *** ...
# ***.ssh.wpengine.net:22 SSH-2.0-Go
prepping file perms...
file perms set...
Skipping PHP Linting.
OpenSSH_8.4p1, OpenSSL 1.1.1k  25 Mar 2021
debug1: Reading configuration data /etc/ssh/ssh_config
debug1: Authenticator provider $SSH_SK_PROVIDER did not resolve; disabling
debug1: Connecting to ***.ssh.wpengine.net [35.244.1[18](https://github.com/frankdigital/l1-2023-theme/actions/runs/8871757625/job/24355348368#step:7:19).20] port 22.
debug1: Connection established.
debug1: identity file /github/home/.ssh/github_action type 3
debug1: identity file /github/home/.ssh/github_action-cert type -1
debug1: Local version string SSH-2.0-OpenSSH_8.4
debug1: Remote protocol version 2.0, remote software version Go
debug1: no match: Go
debug1: Authenticating to ***.ssh.wpengine.net:22 as 'wpe_gha+***'
debug1: SSH2_MSG_KEXINIT sent
debug1: SSH2_MSG_KEXINIT received
debug1: kex: algorithm: curve255[19](https://github.com/frankdigital/l1-2023-theme/actions/runs/8871757625/job/24355348368#step:7:20)-sha256@libssh.org
debug1: kex: host key algorithm: rsa-sha2-512
debug1: kex: server->client cipher: aes128-ctr MAC: hmac-sha2-256-etm@openssh.com compression: none
debug1: kex: client->server cipher: aes128-ctr MAC: hmac-sha2-256-etm@openssh.com compression: none
debug1: expecting SSH2_MSG_KEX_ECDH_REPLY
debug1: Server host key: ssh-rsa SHA256:T8IoIgBRJ3gDjA6/q7i33+nSrrpVfZipYtxo1rqvww4
Warning: Permanently added '***.ssh.wpengine.net,35.244.118.[20](https://github.com/frankdigital/l1-2023-theme/actions/runs/8871757625/job/24355348368#step:7:21)' (RSA) to the list of known hosts.
debug1: rekey out after 4294967296 blocks
debug1: SSH2_MSG_NEWKEYS sent
debug1: expecting SSH2_MSG_NEWKEYS
debug1: SSH2_MSG_NEWKEYS received
debug1: rekey in after 4294967296 blocks
debug1: Will attempt key: /github/home/.ssh/github_action ED25519 SHA256:9aTyrv1zIjzV4ZISKG28S8/ukVPohHhePjcp4qh2gCY explicit
debug1: SSH2_MSG_EXT_INFO received
debug1: kex_input_ext_info: server-sig-algs=<ssh-ed25519,sk-ssh-ed25519@openssh.com,sk-ecdsa-sha2-nistp256@openssh.com,ecdsa-sha2-nistp256,ecdsa-sha2-nistp384,ecdsa-sha2-nistp5[21](https://github.com/frankdigital/l1-2023-theme/actions/runs/8871757625/job/24355348368#step:7:22),rsa-sha2-256,rsa-sha2-512,ssh-rsa,ssh-dss>
debug1: kex_input_ext_info: ping@openssh.com (unrecognised)
debug1: SSH2_MSG_SERVICE_ACCEPT received
debug1: Authentications that can continue: publickey
debug1: Next authentication method: publickey
debug1: Offering public key: /github/home/.ssh/github_action ED25519 SHA256:9aTyrv1zIjzV4ZISKG28S8/ukVPohHhePjcp4qh2gCY explicit
debug1: Server accepts key: /github/home/.ssh/github_action ED25519 SHA256:9aTyrv1zIjzV4ZISKG28S8/ukVPohHhePjcp4qh2gCY explicit
debug1: Authentication succeeded (publickey).
!!! MASTER SSH CONNECTION ESTABLISHED !!!
Authenticated to ***.ssh.wpengine.net ([35.244.118.20]:[22](https://github.com/frankdigital/l1-2023-theme/actions/runs/8871757625/job/24355348368#step:7:23)).
debug1: setting up multiplex master socket
debug1: channel 0: new [/github/home/.ssh/ctl/53cb216414143769a5486a537f80b41ec28b72c2]
debug1: forking to background
debug1: Entering interactive session.
debug1: pledge: id
OpenSSH_8.4p1, OpenSSL 1.1.1k  25 Mar 2021
debug1: Reading configuration data /etc/ssh/ssh_config
debug1: Authenticator provider $SSH_SK_PROVIDER did not resolve; disabling
debug1: multiplexing control connection
debug1: channel 1: new [mux-control]
debug1: channel 2: new [client-session]
debug1: Sending command: rsync --server -vlogDtprze.iLsfxCIvu --delete --inplace . sites/***/wp-content/themes/l1-capital-20[23](https://github.com/frankdigital/l1-2023-theme/actions/runs/8871757625/job/24355348368#step:7:24)/
debug1: mux_client_request_session: master session id: 2
debug1: client_input_channel_req: channel 2 rtype exit-status reply 0
Failed to create shell
debug1: channel 2: free: client-session, nchannels 3
debug1: channel 1: free: mux-control, nchannels 2
rsync: connection unexpectedly closed (0 bytes received so far) [sender]
rsync error: error in rsync protocol data stream (code 12) at io.c(228) [sender=v3.13.0_rc2-264-g7[25](https://github.com/frankdigital/l1-2023-theme/actions/runs/8871757625/job/24355348368#step:7:26)ac7fb]

Version information

jonlow commented 6 months ago

Yep I get the same error too when I push to deploy.

Manually re-running the action in github deploys successfully.

jonlow commented 6 months ago

Happening all the time now. Even if I re-run the failed job. The last 2 lines of the error are:

rsync: connection unexpectedly closed (0 bytes received so far) [sender]
rsync error: error in rsync protocol data stream (code 12) at io.c(231) [sender=3.2.7]
samfrank commented 6 months ago

Yep - I am finding the same thing. I have an open support ticket with WPE so I will post anything they find here

frankhvam commented 6 months ago

Same issue here. I have contacted you support team twice, and they haven't helped me out. Now waiting for a solution a third time.

martylouis commented 6 months ago

The past two days, I encountered the same issue. I was able to update a static image file, but could not upgrade ACF through the composer.json file on another project. I have also reached out to the support team.

rsync error: some files/attrs were not transferred (see previous errors) (code 23) at main.c(1336) [sender=3.2.7]
martylouis commented 6 months ago

Got it fixed on my end. WPE customer service rep, James H., suggested updating exclude.txt and ignoring mu-plugins/wp-cache-memcached. He mentioned that this was a recent addition to their must-use plugins.

Arc--0516170636

frankhvam commented 6 months ago

This was fixed for me by contacting the WPEngine support team.

The supporter wrote:

"I have gone ahead and cleared the git cache on the server for the environment as stuck caches here can cause issues like the one you are seeing more recently. Please try the git push again and let us know if the changes are still not visible."

After this, it worked again.

yaroslav-borodii commented 5 months ago

Hey everyone, we have had the same bottleneck the last week. We couldn't figure out it on our own, so we asked WPEngine Support to deep into it.

if you have the same issue, the best solution would be to ask WPEngine Support about help.

Here is WPEngine comment regarding the issue:

So the issue was related to a git related node on the shared server on which youre hosted here. As this issue is related to a shared server node, we cannot disclose specifics for security reasons.

Regarding the comment you wish to leaveon the github thread, if any other users experience this issue, you can simply advise that they can contact us here in support and we can ensure the same changes are made for any other servers experiencing this issue

jakemason commented 3 months ago

Just updating here that this is still an issue in some environments.

jaireina commented 3 months ago

Having this issue on one of my sites, the others are working fine. Anything we can do to fix this?

Inclushe commented 3 months ago

@jakemason @jaireina This seems to be a different issue. I'm having trouble even SSHing into my server. This seems to be related to this incident.

jakemason commented 3 months ago

Yeah, same issue is just very widespread during this incident. Failure to create a shell for SSH in my case and the OPs.

apmatthews commented 3 weeks ago

The rsync error is secondary to the main error, "Failed to create shell" (about 4 lines above the end of the log). The "Failed to create shell" error is produced in the SSH Gateway and is an intermittent failure. It's not something the GitHub Action has any control over, unfortunately. The best thing to do is to re-run your workflow. If that doesn't help, please contact WP Engine Support (as many of you have done, thank you!). You can use the following to help them pinpoint your issue:

I am unable to connect to my site through the SSH Gateway. The error I receive is "Failed to create shell".

Again, this error will usually resolve itself quickly barring any active incidents on the WP Engine Status page.

We understand that even a temporary deployment interruption is frustrating and hope to have a better solution for this issue in the future.


Got it fixed on my end. WPE customer service rep, James H., suggested updating exclude.txt and ignoring mu-plugins/wp-cache-memcached. He mentioned that this was a recent addition to their must-use plugins.

Thanks for raising this @martylouis! It's unrelated to the "Failed to create shell" issue, but mu-plugins/wp-cache-memcached has been added to our default excludes list in the latest release.