I installed Git for Windows and it came with the "Git Bash", which is basically MinGW32. I noticed that it has SSH, but doesn't have SSHD.

What is the easiest way to get SSHD in MinGW32?

migrated from stackoverflow.com Dec 7 '11 at 18:57

This question came from our site for professional and enthusiast programmers.


A Bash shell is not "MinGW32". I'm feeling generous today, so here goes...

Windows Bash shells

  1. Interix: abandonware, old subsystem developed by Microsoft providing a POSIX environment alongside the Win32 subsystem. It had a bunch of POSIX shells (ksh, csh, bash could be installed)
  2. Cygwin: provides a complete UNIX environment, through a compatibility DLL. Emulates fork and other UNIX-specific function calls. Contains a Bash shell.
  3. MSYS: A fork of an old Cygwin version, focused on running configure scripts (and later also git) on Windows. Using MSYS for anything more than a barebones Bash shell is suicide.

Other Unix-y stuff

  1. MinGW.org: project providing a native GCC compiler that links to msvcrt.dll. It provides an open implementation of the Windows API headers and allows using GNU tools to build native 32-bit Windows apps.
  2. Cygwin: Cygwin GCC is different from the above; you can only run your app when the Cygwin DLL is present, and it will always run under emulation of that POSIX environment.
  3. MinGW-w64: new alternative to MinGW.org, which provides the means to use GCC and GNU binutils to build native 32-bit and 64-bit Windows applications. It strives to provide a C99 compatible implementation, where msvcrt.dll allows that. You can also link to msvcr80, msvcr90, msvcr10 dll's if you wish.

Where does all the confusion come from?

MinGW.org maintain MSYS, and people not thinking clearly often give both the same name, or say both are the same thing. This is not true. MinGW(.org/-w64) is a CRT that heavily relies on msvcrt.dll. It has no Bash. It is not Bash. You could call "MinGW GCC" plain "MinGW", as the two are closely related. Don't call MSYS "MinGW32". That's just evil.

To answer your question: install cygwin, and use its package manager to install sshd.

  • 1
    Interix is not abandonware -- it has evolved into Services for Unix (available for Windows XP) and later Subsystem for Unix Applications (included with Windows 7). – grawity Dec 8 '11 at 10:48
  • grawity: Interix hasn't seen a decent update since its release as SUA. It is not included in Windows 7 (it is a seperate download) and it only contains GNU software from the stoneage. Sure, they still have the version from 5 years ago. – rubenvb Dec 8 '11 at 11:11
  • 3
    @rubenvb, you ignored the OP's question, "What is the easiest way to get SSHD in MinGW32?" Your response, "Install Cygwin..." misses the point: MSYS/MinGW and CygWin are two completely different things. – Codex24 Sep 16 '15 at 20:20
  • I'm with Codex24 on this one. The question is regarding the easiest way of getting an sshd into the environment that comes with MSYSGit. (The question as to whether using that kind of set-up or just using cygwin’s sshd is preferable is a completely separate discussion.) While this information is valuable, I think it would have been more suited as an answer to another question, e.g. stackoverflow.com/q/771756/2420847 – Mark G. May 7 '17 at 1:05

Your Answer

By clicking "Post Your Answer", you acknowledge that you have read our updated terms of service, privacy policy and cookie policy, and that your continued use of the website is subject to these policies.

Not the answer you're looking for? Browse other questions tagged or ask your own question.