• Home
  • Disclaimer
  • Contact
  • Archives
  • About
  • Subscribe
  • Support
  • Advertise

Kernel Talks

Unix, Linux, & Cloud!

  • How-to guides
    • Howto
    • Disk management
    • Configurations
    • Troubleshooting
  • OS
    • HPUX
    • Linux
  • Miscellaneous
    • Software & Tools
    • Cloud Services
    • System services
    • Virtualization
  • Certification Preparations
    • AWS Certified Solutions Architect – Associate
    • AWS Certified Solutions Architect – Professional
    • AWS Certified SysOps Administrator – Associate
    • AWS Certified Cloud Practitioner
    • Certified Kubernetes Administrator
    • Hashicorp Certified Terraform Associate
    • Oracle Cloud Infrastructure Foundations 2020 – Associate
  • Tips & Tricks
  • Linux commands
You are here: Home / Tips & Tricks

GitBash not prompting for MFA in AWS CLI

Published: January 22, 2022 | Modified: January 26, 2022



A quick post on how to resolve an issue with Gitbash that prevents MFA prompts while using AWS CLI.

MFA GitBsah issue.

Problem

GitBash under the hood uses winpty emulator for providing a bash experience on windows. Winpty does not work well with AWS CLI especially when dealing with MFA prompts. Hence you need to replace this with bash.exe and you should be good.

Procedure

Go to the Windows start menu and search for Git Bash. Click on Open file location.

Right click on the shortcut and select Properties

Under properties change the target from “C:\Program Files\Git\git-bash.exe” to “C:\Program Files\Git\bin\bash.exe“

Now launch GitBash and you should be good.

⇠ Previous article
How to resolve the MFA entity already exists error
Next article ⇢
How to configure kubectl for AWS EKS

Related stuff:

  • How to change UID or GID safely in Linux
  • 4 tools to download any file using the command line in Linux
  • Format date and time for Linux shell script or variable
  • Create beautiful ASCII text banners in Linux
  • How to configure login banners in Linux (RedHat, Ubuntu, CentOS, Fedora)
  • Hollywood movie MATRIX like desktop in Linux terminal
  • Cowsay: Fun in Linux terminal
  • How to save PuTTY session output automatically
  • How to test internet speed in Linux terminal
  • How to list open ports on Linux/Unix server
  • 8 ways to generate random password in Linux
  • 3 tricks to get multiple commands output in the same row

Filed Under: Tips & Tricks Tagged With: Gitbash and AWS MFA, Gitbash error AWS CLI MFA

If you like my tutorials and if they helped you in any way, then

  • Consider buying me a cup of coffee via paypal!
  • Subscribe to our newsletter here!
  • Like KernelTalks Facebook page.
  • Follow us on Twitter.
  • Add our RSS feed to your feed reader.

Share Your Comments & Feedback: Cancel reply

This site uses Akismet to reduce spam. Learn how your comment data is processed.

Get fresh content from KernelTalks

  • Email
  • Facebook
  • RSS
  • Twitter

Get Linux & Unix stuff right into your mailbox. Subscribe now!

* indicates required

This work is licensed under a CC-BY-NC license · Privacy Policy
© Copyright 2016-2026 KernelTalks · All Rights Reserved.
The content is copyrighted to Shrikant Lavhate & can not be reproduced either online or offline without prior permission.