Jump to content
TrinityCore

trouble with ubuntu init.d script


m_pan
 Share

Recommended Posts

I'm attempting to use https://github.com/BrnoPCmaniak/WoW-init.d-script to start Trinity when I boot my server but it seems that it's not working as it should and was wondering if anyone here wanted to take a shot at seeing what I'm missing.

Watching the system boot messages it says that it *is* starting the auth and world servers, but when checking the status once the boot process finishes they aren't running any longer. Manually invoking 'start', 'stop', 'restart' and the script works as I'd expect (though 'version' errors and says the server needs to be running even when it is). In the config I've set the user to my trinity user so I should be seeing the screen sessions from that user but nothing.

Suggestions?

Link to comment
Share on other sites

  • 4 weeks later...

Looking at that script, the current "version" code will always be broken. "if is_running; then" is always false since "is_running" isn't a defined subroutine, unless you added it. Make it "if is_running_worldserver; then" and it should work. Also, I suspect that the "tac" command after that if should be "cat". However, the log file could simply be added to the "grep" command to get the same result. Plus, the "This server is running" needs to be changed to something that matches the Trinity log. You could try using 'grep -m 1 "TrinityCore rev" $LOGPATH/server.log' in place of the current grep line. There are other issues with that script, telling me to stick with what I wrote (something I currently run manually because I simply haven't added it at boot time, and I have companion scripts using both bash and perl):

http://pastebin.com/uaC8GF83

http://pastebin.com/3BVJ5SpC

http://pastebin.com/bPedQwZK

http://pastebin.com/mtfn5dCV or http://pastebin.com/8KzB13En

 

I don't know if bnetserver is a required aspect for normal worldserver operation or not, but that init.d script (as it is) doesn't do a thing with the bnetserver process. I know that my scripts start/stop bnetserver, though.

As far as it starting at boot and then not being active after the boot process, it may be getting run at the wrong time (too early), then a runlevel change is performed. That runlevel change will likely stop processes not being used by the new runlevel, resulting in the servers being stopped.

Link to comment
Share on other sites

 Share

  • Recently Browsing   0 members

    No registered users viewing this page.

×
×
  • Create New...