Skip to content

Loading…

Error Deploying to an azure Web App #101

Open
DanKline opened this Issue · 6 comments

2 participants

@DanKline

I'm deploying my first nodejs Azure app and have pulled together most of the information needed to build and deploy the solution, which appeared to succeed without any issues. However, when I try to browse the app, I get a 500 Error with the following information:

Native sqlserver module not found. Did you remember to run node-gyp configure build?
Application has thrown an uncaught exception and is terminated:
Error: Unable to load shared library C:\DWASFiles\Sites\CCGlobal\VirtualDirectory0\site\wwwroot\node_modules\msnodesql\build\Release\sqlserver.node
at Object..node (module.js:477:11)
at Module.load (module.js:353:31)
at Function._load (module.js:311:12)
at Module.require (module.js:359:17)
at require (module.js:375:17)
at Object. (C:\DWASFiles\Sites\CCGlobal\VirtualDirectory0\site\wwwroot\node_modules\msnodesql\lib\sqlserver.native.js:25:23)
at Module._compile (module.js:446:26)
at Object..js (module.js:464:10)
at Module.load (module.js:353:31)
at Function._load (module.js:311:12)

Everything looks right in the directories:
Directory: D:\communitycare\lessons\timetrack

Mode LastWriteTime Length Name


d---- 12/27/2012 3:39 PM lib
d---- 1/1/2013 10:17 PM node_modules
-a--- 1/1/2013 10:02 PM 32 .gitignore
-a--- 1/1/2013 10:12 PM 105 package.json
-a--- 12/28/2012 11:26 AM 920 Server.js

Directory: D:\communitycare\lessons\timetrack\node_modules\msnodesql\lib

Mode LastWriteTime Length Name


-a--- 1/1/2013 10:17 PM 14044 sql.js
-a--- 1/1/2013 10:17 PM 1319 sqlserver.native.js

Directory: D:\communitycare\lessons\timetrack\node_modules\msnodesql\build\release

Mode LastWriteTime Length Name


d---- 1/1/2013 10:17 PM obj
-a--- 1/1/2013 10:17 PM 24551 sqlserver.exp
-a--- 1/1/2013 10:17 PM 40526 sqlserver.lib
-a--- 1/1/2013 10:17 PM 155648 sqlserver.node
-a--- 1/1/2013 10:17 PM 1846272 sqlserver.pdb

Any suggestions?

@jguerin

Hi @DanKline,

Are you deploying this to Windows Azure Web Sites, or your own Compute Instance? You should read this article to understand how to get the driver set up. Please note it is slightly out of date due to our name change to 'msnodesql', but accurate otherwise. We're working on deploying a fix which will make this step a lot simpler.

Cheers,

Jonathan

@DanKline
@jguerin

Hi @DanKline,

Our driver currently does NOT support that method due to the compilation step required, which is why we have the workaround documented. We are planning on fixing this in an upcoming release very soon.

Thanks,

Jonathan

@DanKline
@jguerin

FYI, the version 2.0.1 includes a fix that was aimed to work inside Windows Azure Web Sites, but we've hit a bug in that environment which is currently being investigated. In the meantime, please continue to use the workaround until we resolve the issue.

@DanKline

Thanks for the update. I sent Jay a copy of the libraries that included some built in diagnostics for the library users . I'm sure he hasn't had a chance to even look at them, but I found them helpful in getting my first sample to work. In the interim, I've been heads down reviewing JavaScript, HTML5 and CSS3 for the 70-480 & 70-481 certs. After I get over that hurdle, I'd love to contribute to the project.

I have a vision of being able to use NodeJS as a core server for Web Services attaching to multiple data sources (e.g MSSQL, DB2, Azure, External oData) and based on XML driven business rules present the homogenized data as a local web service that can be used by client web based apps. My thought being, I can abstract all the interfaces away from the client, build the business rules and authorization restrictions into the XML, and present a single interface for client development controlled by a centralized data authority and present the data through a restful web service.

Sounds daunting, and maybe I'm oversimplifying it, but I think it's worth the effort to prove it will or won't work.

I hope I can help you get some traction with this library. I think it has great potential for the enterprise.

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.