Skip to content


Subversion checkout URL

You can clone with
Download ZIP


"msnodesql-0.2.1-v0.8-ia32.msi" does not work on Azure Web Sites #114

siacomuzzi opened this Issue · 13 comments

3 participants


Hi, I have problems to run the module in Azure Web Sites.

Repro steps:

1) Remove msnodesql from dependencies in my package.json
2) Copy content of "msnodesql-0.2.1-v0.8-ia32.msi" to "node_modules\msnodesql"
3) Include "node_modules\msnodesql" content in my GIT repository
4) Deploy to Azure
5) When deployment is ready, and navigate to the web page, the error is the following:

"Error: Cannot find module '../build/Release/sqlserver.node'"
Error details:


Please try msnodesql-0.2.1-v0.6-{ia32|x64}.msi. I believe Windows Azure Web Sites uses node.js 0.6, though I don't know the processor version.

To verify, it should be easy enough to write a simple website that outputs process.version and process.arch.

Thanks, and let us know the results are.


Thanks Jay!

  • With "msnodesql-0.2.1-v0.6-{ia32|x64}.msi" -> same error
  • Azure websites: (process.version: v0.8.2; process.arch: ia32)

Okay, well that eliminates that possibility. :)

Where is the sqlserver.node file within the archive? It should be in the node_modules\msnodesql\lib directory.

With your layout as I understand it, you should be able to do a "var sql=require('msnodesql')" from a node REPL prompt and have it load successfully. Is this successful prior to deploying on Windows Azure Web Sites?

  • My "node_modules\msnodesql\lib" folder:
  • And yes, the module works fine on my machine

Well, I'm not sure what's wrong. Just for completeness, I'll refer you to our article on the subject, but I think you've already done as it instructs.

I don't know... What does your package.json look like?


My package.json:


I've had some success, but I'm still working on making the solution more robust.


So the crux of the issue is that Windows Azure Web Sites deploys node.js 0.8.2, and we distribute .node files built against 0.8.8, which can't be loaded by 0.8.2. If you were to rebuild against 0.8.2, it should work...


Thanks Jay!
I'll try and let you know how it went.


Same error :( =>

I'm generating the sqlserver.node file with the following environment:
Could you please send me your copy of the sqlserver.node file that works on Azure Web Sites?



I can do that. I hope to check in to a private branch that you can access later today/tomorrow.

Just FYI, Windows Azure Web Sites is set to 0.8.2. Download it from and put node.exe in a directory, e.g. c:\nodejs-0.8.2:

rem done in a Visual Studio command prompt
set PATH=c:\nodejs-0.8.2;%PATH%
rem should print v0.8.2
node -v
rem should print ia32
node -e "console.log( process.arch );"
cd \msnodesql
rem should produce a sqlserver.node file in build\release
node-gyp rebuild
cd build\release
> var sql=require( './sqlserver.node');
undefined <-- printed by node.js if the require was successful
> process.exit();

This should give you a sqlserver.node file that is compatible with Windows Azure Web Sites. Otherwise, you can wait until I have my private branch set up to try out. That make take a day or two :(.


I think I'm having a similar issue in deploying msnodesql to Azure.

@siacomuzzi did you have any luck deploying @jkint's copy of the sqlserver.node file?

I've created my sqlserver.node file using node version 8.2.0 but I'm still getting deployment errors on Azure.

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Something went wrong with that request. Please try again.