Skip to content

A short tutorial for building mongodb with openssl support on Windows.

License

Notifications You must be signed in to change notification settings

claycollier/mongodb-ssl

 
 

Folders and files

NameName
Last commit message
Last commit date

Latest commit

 

History

12 Commits
 
 
 
 

Repository files navigation

Mongodb with openssl support

Building mongodb with openssl support on Windows is not for the faint hearted. This short tutorial teaches you how to do it.

Prebuilt binaries

You can download my prebuilt binaries from Sourceforge if you want to get started quickly. Binaries for both x86 and x64 are available starting from mongo 2.4.9.

In order to run mongodb with ssl support on Windows Server 2008 R2 or newer the following prerequisites are required:

Grabbing mongo sources

  1. Create a new folder on your disk called mongodb-ssl
  2. Download and extract Winpcap 4.1.2 Developers pack into mongodb-ssl\winpcap
  3. git clone https://github.com/mongodb/mongo.git mongodb-ssl\mongo
  4. cd mongodb-ssl\mongo
  5. git checkout r2.4.9

Downloading thirdparty dependencies

NB! You do not need a working Visual Studio 2010 CD-KEY after your trial expires because we are only interested in the compilers.

NB! If the python installer does not do it for you, please remember to add C:\Python27\scripts to your PATH environment variable otherwise scons will not be found.

32-bit build

NB! Before you continue you need to change line 71 in C:\OpenSSL-Win32\include\openssl\dtls1.h from winsock.h to winsock2.h otherwise mongosniffer.exe will fail to compile.

  1. Modify mongodb-ssl\mongo\SConstruct at line 287 and add the following entry to env = Environment(:

    MSVC_USE_SCRIPT = "C:\\Program Files (x86)\\Microsoft Visual Studio 10.0\\VC\\vcvarsall.bat",

  2. Run the following line in a Visual Studio 2010 command prompt

    scons all --release --32 --ssl --win2008plus --extrapath="C:\OpenSSL-Win32"

  3. You shall see unicorns in mongodb-ssl\mongo\build\win32\32\extrapath_C__OpenSSL-Win32\release\ssl\mongo folder.

64-bit build

  1. Modify mongodb-ssl\mongo\SConstruct at line 287 and add the following entry to env = Environment(:

    MSVC_USE_SCRIPT = "C:\\Program Files (x86)\\Microsoft Visual Studio 10.0\\VC\\bin\\amd64\\vcvars64.bat",

  2. Run the following line in a Visual Studio 2010 command prompt

    scons all --release --64 --ssl --win2008plus --extrapath="C:\OpenSSL-Win64"

  3. You shall see unicorns in mongodb-ssl\mongo\build\win32\64\extrapath_C__OpenSSL-Win64\release\ssl\mongo folder.

About

A short tutorial for building mongodb with openssl support on Windows.

Resources

License

Stars

Watchers

Forks

Packages

No packages published