Setting up NWNx as a windows service

Forum for scripters of NWN material and third party applications.
Post Reply
Arcsylver
Groundling
Posts: 105
Joined: Mon Nov 24, 2003 9:39 pm
Contact:

Setting up NWNx as a windows service

Post by Arcsylver »

I need to know how to set up nwnx as a windows service so that the server client can be launched automatically on windows bootup every time even if the computer restarts due to a power outage etc.

When I try to use the sc command on the command line in windows server 2003 I get this error when I try to start the service

error:1053 the service did not respond to the start or control request in a timely fashion
Jeff
World Leader: Ea
Posts: 130
Joined: Wed Nov 19, 2003 8:36 pm
Location: EA
Contact:

Post by Jeff »

Just add a shortcut to NWNX to your start menu.
Come by and see us at:
http://hanus.is-a-geek.net/
Arcsylver
Groundling
Posts: 105
Joined: Mon Nov 24, 2003 9:39 pm
Contact:

Post by Arcsylver »

I do that, unfortunately Windows Server 2003 is being a pain in the rear about letting me disable the login on startup so until the password is typed in the startup isnt processed. Thus the server doesnt load unless someone is physically here to type it in if the power goes out or something.

Was hoping to possibly set up something to auto launch somehow without the password being typed in since the services supposedly load prior to login.
Themicles
Leader: Tairis'nàdur & CoPaP Hak-Master
Posts: 887
Joined: Tue Nov 25, 2003 11:26 am
Location: Michigan
Contact:

Post by Themicles »

Suggest this feature for future versions of NWNX if someone picks up where Pap left off. I know someone wants to, but not sure if they are going to.

-Themicles
JollyOrc
Ambassador: Tairis'nàdur
Posts: 380
Joined: Tue Nov 25, 2003 1:13 am
Location: Catar, D'Aton Academy of the Blade
Contact:

Post by JollyOrc »

there are tools that let you run normal windows programs as system service.

Too lazy to do a google search right now, but they are out there.
bye,
JollyOrc
___________________
Tairis'nàdur - Senior DM, Catara World Owner
-= fewer rules - more fun =-
TimeLord
World Leader - LoT: Cormyr
Posts: 24
Joined: Thu Nov 27, 2003 11:43 pm
Location: LoT - Cormyr
Contact:

srvany.exe

Post by TimeLord »

Theres a program in the NT Resource kit called srvany.exe which is supposed to allow you to turn any .exe into a service.

Microsoft makes it difficult to download/support anything windows2000 so you may have a hard time finding the actual download. They would rather you buy Windows 2003 server. So do a search for svrany.exe on M$ site and you might get lucky.

The page here looks like its got an option or two, dont have time to evaluate this myself right now so let us know how it goes :)

http://www.nick.rozanski.com/software.htm
Maska
World Leader: Fairhaven
Posts: 45
Joined: Thu Nov 20, 2003 12:33 pm

Post by Maska »

FireDaemon works quite well too...
[color=red][size=150][b]Maska[/size][/color][/b]
Maska
World Leader: Fairhaven
Posts: 45
Joined: Thu Nov 20, 2003 12:33 pm

Post by Maska »

FireDaemon works quite well too...
[color=red][size=150][b]Maska[/size][/color][/b]
Silk
World Leader: Avlis
Posts: 20
Joined: Sun Dec 21, 2003 8:02 pm
Location: Avlis
Contact:

Post by Silk »

FireDaemon
-Silk
Themicles
Leader: Tairis'nàdur & CoPaP Hak-Master
Posts: 887
Joined: Tue Nov 25, 2003 11:26 am
Location: Michigan
Contact:

Post by Themicles »

I've now tried running NWNX as a service using FireDaemon. This does not work correctly, and I'm hoping someone can help me fix that.

If I start NWNX as a service with FireDaemon, I get the following errors:
* An error occured during OnCreate of odbc
in the NWNX.txt logfile.

AND
! Error while connecting to database: [Microsoft][ODBC Driver Manager] Data source name not found and no default driver specified
in the NWNX_ODBC.txt logfile.

This is not an issue with my setup of NWNX, MySQL or NWN directly, as it works JUST FINE if I launch it from my shortcut, instead of through FireDaemon.

Any help? Any suggestions? Would be really nice to have my server running without user login on the machine, AND be able to contact the database. Can't have the one without the other...

-Themicles
Rathaen
World Leader: Stormsea Rising
Posts: 14
Joined: Sat Apr 17, 2004 9:10 pm

Post by Rathaen »

What sort of DSN is your Neverwinter database? Make sure it's a machine-wide DSN. That could cause this problem, because if FireDaemon starts NWNX without you being logged in, any user-specific DSNs will be inaccessible. This is the same error message NWNX gives if no DSN exists.
-----
"Rathaen ni-Tethrain" and/or "Eilysian ab-Pharaki"
from "Stormsea Rising"
Themicles
Leader: Tairis'nàdur & CoPaP Hak-Master
Posts: 887
Joined: Tue Nov 25, 2003 11:26 am
Location: Michigan
Contact:

Post by Themicles »

I have it working now.

A warning to multi-server worlds.
If you want to run NWNX as a service, you are going to have to give up the ability to access the server program to see who's online, and even properly shut it down.

Why?
Only way to run NWNX as a service and still have both NWNX and NWServer.exe show on the desktop is to use LocalSystem. But, if you do that, NWServer.exe cannot access a server vault on another computer on the network. LocalSystem is obviously not allowed network access.

Now to get around this, you must run the service as a user that does have network access. But, this means that it will be hidden and cannot interact with the desktop.

-Themicles
"A wise man does not dwell on his past. He learns from it, he grows from it, and then moves ahead into his future." -me
lafferty
Planewalker
Posts: 31
Joined: Mon Nov 24, 2003 9:30 pm
Location: look at my hands... they are HUGE. And they cant touch themselves... (AVLIS)
Contact:

Post by lafferty »

Just pointing to the obvious:

http://support.microsoft.com/kb/q137890/

and then in the service dialogue (Management console) activate "May interact with desktop"

Maybe that works better....
[url=http://zope.lafferty.de]Crafter's helper[/url]
Post Reply