Jump to content

Search the Community

Showing results for tags 'admin-tool'.

More search options

  • Search By Tags

    Type tags separated by commas.
  • Search By Author

Content Type


  • Mangos Zero
    • Enhancement Requests (Zero)
    • Tasks (Zero)
  • Mangos One
    • Enhancement Requests (One)
    • Tasks (One)
  • Mangos Two
    • Enhancement Requests (Two)
    • Tasks (Two)
  • Mangos Three
    • Enhancement Requests (Three}
    • Tasks (Three)
  • Mangos Four
    • Enhancement Requests (Four)
    • Tasks (Four)
  • Mangos Five
    • Enhancement Requests (Five)
    • Tasks (Five)
  • Cross-Core
    • Bugs
    • Enhancement Requests
    • Tasks
    • Sub-Modules
    • Eluna
    • Linux
    • Windows
    • Archived Cross-Core/Other Reports
  • Others
    • Mangos VB
    • Third Party Software
    • Website
  • Bug Tracker Archives
    • Archived Reports (Zero)
    • Archived Tasks (Zero)
    • Archived Reports (One)
    • Archived Tasks (One)
    • Archived Reports (Two)
    • Archived Tasks (Two)
    • Archived Reports (Three)
    • Archived Reports (Five)


  • Development Roadmap
  • Documentation
    • Installation Guides
    • Playerbot AI
    • Standards And Practices
  • Tutorials
    • Advanced
    • Contributing to Mangos
    • Debugging
  • Reference Information
    • ClientFiles
    • Database Info
    • DBC Files
    • Other
    • Packet Info
    • Server Files
    • Server Components


  • MaNGOS Information
    • Announcements & Releases
    • Covenant-WoW.com Website - Official Mangos Test Servers
  • Community Discussion Areas
    • Introduce Yourself
    • Community Cafe
    • Community Input
    • Community Projects
    • MaNGOS University
  • Community Help and Support
    • Peer to Peer Technical Support
    • Frequently Asked Questions
    • Resources
  • Development & Patch Submissions
    • Development
    • Patch Submissions
  • Eluna LUA Engine
    • Eluna Central
  • International Help & Support
    • International Boards
  • Archived
    • Main Archives
    • Archive of Pre-2012 Forum

Product Groups

There are no results to display.


  • Mangos Zero
  • Mangos One
  • Mangos Two
  • Mangos Three
  • Addons
    • Classic Addons
  • World Of Warcraft Patches
    • WoW Patches
    • The Burning Crusade Patches
    • Wrath of the Lich King
    • Client Tools Patchers


  • getMaNGOS
  • DBC handling for mangos
  • The Road to Zero Release 21
  • Necrovoice's development blog.
  • What the Heck happened to Antz and MaNGOS in 2018 !!

Find results in...

Find results that contain...

Date Created

  • Start


Last Updated

  • Start


Filter by number of...


  • Start






Website URL





About Me




Found 1 result

  1. Hello everyone ! After setting-up your server on a Linux-based distro, you may wonder : how to let the realmd & mangosd deamons run on your server with all consoles closed ? how to automatically restart theses daemons if they crash ? hom to restart theses dameons ? ho to get access to the daemons consoles after having closed all your terminals ? Well, you are at the right place ! PREREQUISITE : The "screen" app must be installed and also "gdb" in order to correctly dump chrash data : sudo apt install screen gdb STEP 1 : Go to a folder where you would like to install the script. STEP 2 : Create a file called wowadmin.sh. Make it executable : chmod +x wowadmin.sh STEP 3 : Paste the code below in the file and change the variables "/path/to/your/realmd" and "/path/to/your/mangosd" as your real paths to realmd and mangosd : #!/bin/bash THIS_FULLPATH=$(cd `dirname "${BASH_SOURCE[0]}"` && pwd -P)/`basename "${BASH_SOURCE[0]}"` THIS_FOLDERPATH=$(cd `dirname "${BASH_SOURCE[0]}"` && pwd -P) APATH=/path/to/your/realmd WPATH=/path/to/your/mangosd ASRV_BIN=realmd #This usually doesnt change. TrinityCore: authserver MaNGOS: realmd ArcEmu: whocares? WSRV_BIN_ORG=mangosd #This usually doesnt change. TrinityCore: worldserver MaNGOS: mangosd ArcEmu: whocares? WSRV_BIN=mangosd WSRV_SCR=mangosd echo "run" > gdbcommands echo "shell echo -e \"\nCRASHLOG BEGIN\n\"" >> gdbcommands echo "info program" >> gdbcommands echo "shell echo -e \"\nBACKTRACE\n\"" >> gdbcommands echo "bt" >> gdbcommands echo "shell echo -e \"\nBACKTRACE FULL\n\"" >> gdbcommands echo "bt full" >> gdbcommands echo "shell echo -e \"\nTHREADS\n\"" >> gdbcommands echo "info threads" >> gdbcommands echo "shell echo -e \"\nTHREADS BACKTRACE\n\"" >> gdbcommands echo "thread apply all bt full" >> gdbcommands DEBUG=false #WORLD FUNCTIONS startWorld() { if [ "$(screen -ls | grep $WSRV_SCR)" ] then echo $WSRV_BIN is already running else cd $WPATH screen -AmdS $WSRV_SCR $THIS_FULLPATH $WSRV_BIN $DEBUG echo $WSRV_BIN is alive fi } restartWorld() { screen -S $WSRV_SCR -X stuff "saveall$(printf \\r)" echo saved all characters, and server restart initialized screen -S $WSRV_SCR -X stuff "server restart 5$(printf \\r)" } stopWorld() { screen -S $WSRV_SCR -X stuff "saveall " echo saveall sent, waiting 5 seconds to kill $WSRV_BIN sleep 5 screen -S $WSRV_SCR -X kill &>/dev/null echo $WSRV_BIN is dead } monitorWorld() { echo press ctrl+a+d to detach from the server without shutting it down sleep 5 screen -r $WSRV_SCR } #AUTH FUNCTIONS startAuth() { if [ "$(screen -ls | grep $ASRV_BIN)" ] then echo $ASRV_BIN is already running else cd $APATH screen -AmdS $ASRV_BIN $THIS_FULLPATH $ASRV_BIN echo $ASRV_BIN is alive fi } stopAuth() { screen -S $ASRV_BIN -X kill &>/dev/null echo $ASRV_BIN is dead } restartAuth() { stopAuth startAuth echo $ASRV_BIN restarted } monitorAuth() { echo press ctrl+a+d to detach from the server without shutting it down sleep 5 screen -r $ASRV_BIN } #FUNCTION SELECTION case "$1" in $WSRV_BIN ) if [ "$2" == "true" ] then while x=1; do gdb $WPATH/$WSRV_BIN --batch -x gdbcommands | tee current NOW=$(date +"%s-%d-%m-%Y") mkdir -p $THIS_FOLDERPATH/crashes mv current $THIS_FOLDERPATH/crashes/$NOW.log &>/dev/null killall -9 $WSRV_BIN echo $NOW $WSRV_BIN stopped, restarting! | tee -a $THIS_FULLPATH.log echo crashlog available at: $THIS_FOLDERPATH/crashes/$NOW.log sleep 1 done else while x=1; do ./$WSRV_BIN NOW=$(date +"%s-%d-%m-%Y") echo $NOW $WSRV_BIN stopped, restarting! | tee -a $THIS_FULLPATH.log sleep 1 done fi ;; $ASRV_BIN ) while x=1; do ./$ASRV_BIN NOW=$(date +"%s-%d-%m-%Y") echo $NOW $ASRV_BIN stopped, restarting! | tee -a $THIS_FULLPATH.log sleep 1 done ;; "wstart" ) startWorld ;; "wdstart" ) DEBUG=true startWorld ;; "wrestart" ) restartWorld ;; "wstop" ) stopWorld ;; "wmonitor" ) monitorWorld ;; "astart" ) startAuth ;; "arestart" ) restartAuth ;; "astop" ) stopAuth ;; "amonitor" ) monitorAuth ;; "start" ) startWorld startAuth ;; "stop" ) stopWorld stopAuth ;; "restart" ) restartWorld restartAuth ;; * ) echo Your argument is invalid echo "usage: start | stop | restart | wstart | wdstart | wrestart | wstop | wmonitor | astart | arestart | astop | amonitor" exit 1 ;; esac USAGE : You can use the script with its options like : ./wowadmin.sh start Available options are : start : Starts realmd and mangosd - in a screened process. stop : Stops realmd and mangosd - in a screened process. restart : Retarts realmd and mangosd - in a screened process. wstart : Starts only mangosd - in a screened process. wdstart : Starts only mangosd in DEBUG mode - in a screened process. wrestart : Restarts only mangosd - in a screened process wstop : Stops mangosd - screened process. wmonitor : Brings back the mangosd console from the screened process (press "Ctrl+A+D" to re-detach it). astart : Starts only realmd - in a screened process. arestart : Restarts only realmd - in a screened process. astop : Stops only realmd - in a screened process. amonitor : Brings back the realmd console (press "Ctrl+A+D" to re-detach it). Moreover, when there is a crash, the daemons will auto-restart dans there will be a crashlog dumped in "crashes" directory next to your deamons executable binaries. For your information, you can see the screened processes by typing : screen -ls You can use multiple wowadmin.sh files if you manage multiple realms but the more simple would be to add specific options in the same script for your differents mangosd dameons as there could be only 1 realmd daemon running and many mangosd daemons running. Source : adapted from Lillecarl Gist

Contact Us

To contact us click here
You can also email us at [email protected]

Privacy Policy | Terms & Conditions


The Link to the master list
of MaNGOS repositories:
Copyright © getMaNGOS. All rights Reserved.

This website is in no way associated with or endorsed by Blizzard Entertainment®
  • Create New...

Important Information

We have placed cookies on your device to help make this website better. You can adjust your cookie settings, otherwise we'll assume you're okay to continue. Privacy Policy Terms of Use