Solving “error: RPC failed; curl 92 HTTP/2 stream 5 was not closed cleanly: CANCEL (err 8)” During Homebrew Installation

Introduction

This guide is specifically designed for beginners who are facing the Homebrew installation error related to network issues, particularly the “error: RPC failed; curl 92 HTTP/2 stream 5 was not closed cleanly: CANCEL (err 8)” message. Follow these steps to resolve this issue.

Step-by-Step Solutions

  1. Check Network Connection

    • Ensure your internet connection is stable. If unstable, take steps to stabilize your connection.
    • If using a VPN, try disconnecting it to see if access to GitHub improves.
  2. Change Git’s HTTP Transport

    • To potentially bypass the issue, switch Git’s HTTP transport to HTTP/1.1:
     git config --global http.version HTTP/1.1
    
  3. Extend Git Timeout Settings

    • Increase timeout settings to accommodate slower connections:
     git config --global http.postBuffer 524288000 git config --global http.lowSpeedLimit 0 git config --global http.lowSpeedTime 999999
    
  4. Retry Installing Homebrew

    • Run the Homebrew installation script again:
     /bin/bash -c "$(curl -fsSL https://raw.githubusercontent.com/Homebrew/install/HEAD/install.sh)"
    

Resetting Changes

If you need to revert the changes made to Git settings, use the following commands to return to default behaviors:

git config --global --unset http.version
git config --global --unset http.postBuffer
git config --global --unset http.lowSpeedLimit
git config --global --unset http.lowSpeedTime
Enter fullscreen mode
Exit fullscreen mode

Discover more from Coursity

Subscribe to get the latest posts sent to your email.

Leave a Comment

Your email address will not be published. Required fields are marked *

Discover more from Coursity

Subscribe now to keep reading and get access to the full archive.

Continue reading

Scroll to Top
Ui/ux design services. And here’s another atm llc difference ! it’s service not available from other aircraft ferry services.