How to create WoW Private Server using Mangos

This guide is about creating a WoW Private Server (WOTLK) using Mangos. And because previously we’ve learned on how to compile mangos obviously the next step would be setting up Mangos which is going to be covered in this guide :)


World of Warcraft Client version 3.3.3 (11723) or the latest version that Mangos support as stated on Mangos project description here

This guide is tested on WoW 3.3.3a client, and as long as the WoW client is supported by Mangos, it’ll work, although you might need to make some adjustment to several things listed in this guide, like the filename for example


If you currently don’t have MySQL installed on your computer, please follow my previous guide on how to install MySQL on Windows XP or how to install MySQL on Windows Vista or Windows 7

Compiled Mangos Binary / Executable

Check my previous mangos compile guide because without the binary / executable itself, you won’t be able to run your own WoW private server. And beside this guide is based on my mangos compilation guide. So if you follow my previous guide completely (including the directory structure) then it’ll make thing easier for you


This is needed in order to get the database for Mangos, as for the installation process i’ve described it on the compile guide. So if you follow the previous compile guide then you don’t need to reinstall it again

UDB and ACID Database

UDB and ACID is required so you can see NPC and doing quest in the WoW World, see below for instruction to get UDB and ACID

Downloading UDB and ACID

The first step is obviously downloading the required database in order for your WoW server to function as it should be, to do this we’re going to use TortoiseSVN to fetch the required files

1. Open Windows Explorer and right click on an empty space then choose SVN Checkout and type

as the repository address

udb svn co udb done

2. After finished with the above process, wow we need to download SD2 ACID. Type

as the svn repository url

sd2 acid svn co sd2 acid done

And now we’re done with the requirements

Initial Setup

Creating Directory Structure

Create new folder in C:\ named WoW and inside the WoW directory you just created, create two directories named data and mangos. So it’ll look like this

creating directory structure

Although this step can be considered non essential, but if you created a directory structure, it can make upgrading Mangos and the required files such as DBC and Maps much easier later and beside in this guide i’m using the directory structure specified here so other than that it can make things easier for you to follow this guide

Extracting DBC, Maps and VMaps

1. Copy the ad.exe from contrib directory inside your mangos compile directory (on my compile example, the mangos compile directory is C:\Mangos-git) into your WoW installation directory. Then run the ad.exe and when it’s done you’ll see two new folders created named DBC and Maps

copy ad.exe ad.exe done

2. After finished with the extraction process, now you need to move the DBC and Maps directory from your WoW installation directory to C:\WoW\data

Note: Back when i write this, VMaps is disabled by default so i didn’t include it in the steps here but because now it’s enabled by default, to reduce / hopefully prevent further question regarding vmaps, all you have to do:
1. Copy the vmapExtractor3.exe and vmap_assembler.exe from the extractor_binary directory and then copy the make_vmaps.bat from vmap_extractor_v3 directory (both of them are located under contrib directory) to your WoW installation directory
2. Run make_vmaps.bat and wait till it finished and move the vmaps directory to C:\WoW\Data

Copying Mangos Config Files

Remember the directory structure we’ve created earlier? if yes, then that’s good because in this example i’m going to use the directory structure created earlier, if you choose to skip the creating directory structure part then make sure to adjust everything accordingly

1. Now you’ll need to copy the,, from your Mangos compile directory (use the search function as shown at below image) to C:\WoW\Mangos

mangos conf

2. And then copy everything from the Bin directory inside your mangos compile directory into C:\WoW\Mangos and then rename, and into mangosd.conf, realmd.conf, scriptdev2.conf. So in the end, you have these files (see below image) inside C:\WoW\Mangos directory

mangos necessary files

Setting Mangos Datadir

Go to directory C:\WoW\Mangos and open mangosd.conf and search for

DataDir = "."

and replace it with

DataDir = "C:\WoW\data"

mangos datadir

Installing the Databases

Note: For future version (if you didn’t read this at the time this post published), adjust the SQL filename (for Mangos SQL Updates files and UDB SQL files) and directory name accordingly

Installing Mangos Databases

Before starting in this process, please note that the directory structure used is based on the mangos compile guide so if you use different path, make sure to adjust them accordingly. Also if you get "mysql is not recognized as an internal or external command, operable program or batch file." that means you didn’t set up MySQL to be installed to your Environment Variables PATH. See the MySQL Installation Guide on my previous guide for more info

Note: This step is intended for fresh installation only, if you’re upgrading mangos skip this step otherwise you’ll lose all your characters and logins data in your mangos database

1. Open Command prompt, and then type

cd /d c:\mangos-git\sql

then followed by

mysql -uroot -p -v < create_mysql.sql

creating mangos database

This will create mangos database structure and also create the necessary user (because using root is dangerous)

2. Then type

mysql -uroot -p -v -D realmd < realmd.sql

importing realmd

This will import the necessary realmd tables into the realmd database

3. Finally type (but don’t close the command prompt yet)

mysql -uroot -p -v -D characters < characters.sql

importing characters

This will import the necessary tables into the characters database

Installing UDB (Unified Database)

1. Remember the part about downloading database? if yes, then go to the directory where you download the UDB database, and then extract the inside the Full DB directory of your UnifiedDatabase directory so it’ll look like this

extracting udb

2. And now we’re going to import the database (it may take a while depending on how fast your computer is). From the command prompt window from before, type (don’t close the command prompt window yet again)

cd /d C:\unifieddb\Full_DB
mysql -uroot -p -v -D mangos < UDB_0.12.0_mangos_9582_SD2_1639.sql

importing udb fulldb

Updating Mangos Database

Because the Full UDB database is designed for Mangos Revision 9582, and at the time i wrote this the compiled Mangos binary we previously compiled at the compiling mangos guide is at Revision 9771, we need to import all sql files in your mangos compile directory\sql\updates after 9582 to mangos database unless there is no sql update file after that version (which is unlikely)

Tips: look at the UDB filename it state mangos 9582 which means that every mangos core update before and equal to Mangos 9582 has been applied and so we need to apply all sql updates that is released after revision 9582. And to check your mangos revision, just run mangosd.exe or realmd.exe and then open server.txt or server.log file to see the Mangos revision you’re running

For example right after 9582 in sql\updates\0.16 in mangos compile directory there is a sql file named 9589_01_mangos_creature_template.sql, so we need to import that one first and you can do this by simply typing:

mysql -uroot -p -v -D mangos < 9589_01_mangos_creature_template.sql

and right after 9589_01_mangos_creature_template.sql there’s another sql update filename called 9590_01_mangos_db_script_string.sql, so then you need to type

mysql -uroot -p -v -D mangos < 9590_01_mangos_db_script_string.sql

and so on, basically you’ll need to locate each sql update file that contain mangos in the filename (ignore the realmd and characters), and then manually import each sql file accordingly

In the future, in case you want to upgrade your mangos installation, you can do so by importing each sql file including the realmd and characters if there’s any. But why we didn’t import sql files that contains characters and realmd in it’s filename in this guide? the answer is, because we’re doing a fresh installation the realmd database and characters database already using the latest update, but if you’re upgrading in the future chances are there’s an update for either realmd and characters database also

For example, 9767_03_characters_characters.sql. Means that it should be imported to characters database and to import it you need to type

mysql -uroot -p -v -D characters < 9767_03_characters_characters.sql

And for realmd update, the sql filename 9748_01_realmd_realmlist.sql and to import it you need to type

mysql -uroot -p -v -D realmd < 9748_01_realmd_realmlist.sql

That’s it basically, this may be confusing at the beginning but once you get used to it, it’ll be easy for you

Updating UDB

Now we need to update our UDB database too (because there’s an update at the time i wrote this), here’s how to do this

cd /d c:\unifieddb\Updated\0.12.0_additions
mysql -uroot -p -v -D mangos < 389_updatepack_mangos.sql
mysql -uroot -p -v -D mangos < 390_updatepack_mangos.sql

importing udb updatepack 389 importing udb updatepack 390

Tips: if there’s an update for UDB in the future all you have to do is just import the correct update accordingly

Installing and Updating Scriptdev2

From the command prompt type

cd /d c:\scriptdev2\sql
mysql -uroot -p -v < scriptdev2_create_database.sql
mysql -uroot -p -v -D scriptdev2 < scriptdev2_create_structure_mysql.sql
mysql -uroot -p -v -D scriptdev2 < scriptdev2_script_full.sql
mysql -uroot -p -v -D mangos < mangos_scriptname_full.sql

creating scriptdev2 database installing scriptdev2 tables

installing scriptdev2 database install scriptdev2 to mangos database

In the future, if you want to upgrade Scriptdev2 (assuming that you have recompiled Mangos and Scriptdev2 and also imported the updated Mangos sql files and also UDB if there are updates as described in the Updating Mangos and Updating UDB). You just need to execute this from the command prompt:

mysql -uroot -p -v -D scriptdev2 < scriptdev2_script_full.sql
mysql -uroot -p -v -D mangos < mangos_scriptname_full.sql

Installing ACID Database

From the command prompt again type

cd /d c:\sd2-acid\trunk\wotlk\3.0.4
mysql -uroot -p -v -D mangos < 3.0.4_acid.sql

installing acid database

Adjusting Realmlist and Creating Account


The next step would be editing your file located inside your wow installation directory\data\enUS (or your WoW Region like enGB, etc) and insert this

set realmlist

replacing everything inside the (make sure to create backup)

Creating GM Account

Now before getting into the World of Warcraft world, you need to create an account first for you to use, and to do that first you need to make sure realmd and mangosd process is running and then in the mangosd window type

account create username password

Where username is whatever username you want, and password is whatever you want for the account password. And then type

account set addon username 2

To set the expansion pack to Wrath of the Lich King (0 = Classic WoW, 1 = The Burning Crusade, 2 = Wrath of the Lich King) for the username you choose. And finally type

account set gmlevel username 3

To give the highest GM (Game Master) level to the username you choose, so he/she can do anything he/she want from wreaking havoc to causing apocalypse

create mangos gm account

in the example above, i create a new gm account with reaper as username and ilovekeikokitagawa as the password (p.s don’t take the password seriously) :P

Note: later in the game you can to type .commands to see all available commands for you (or feel free to look at the GM Commands List page)

Optional: Setting up Public WoW Server (LAN or Internet)

If you’re planning on allowing people to connect to your server either from the Internet or LAN, then there’s one more thing you need to do so other people can connect to your wow server

First you need to open the command prompt as usual and then type

mysql -uroot -p

now type

use realmd;

and finally type

select * from realmlist;

and you’ll see the realm address is set to by default, but because you’re going to allow other people to connect to your server / computer, you need to change the ip address into your Public IP Address. The easy way to know your public ip address is by visiting and make a note of your IP Address

Once you’ve obtained the public ip address the next step would be changing the ip address in the realmlist table, and to do this just type

update realmlist set address = 'your public ip address';

then to make sure the change has been applied successfully, you need to type

select * from realmlist;

If you’ve changed it then you’ll see your new public ip address instead of

The next step is restart realmd.exe, and mangosd.exe process in order for the change to take effect

Now after finished with the above process, you’ll need to open your and change the set realmlist into your public IP Address …. and tell your client to use the your public ip address in their file and you’re all set ;)

Note: if you’re behind router, make sure to forward port 3724 and 8085 (default port used by WoW) on your router or set up DMZ. And if you’re behind firewall make sure to allow incoming connection on port 3724 and 8085

Special Note: To those with Dynamic IP Address

If your internet provider gave you a dynamic ip address, then the solution is to get yourself a dyndns address first, and to do this you need to go to and register an account there, and i assume that your wow server is called

Then after finished with the registration process, all you have to do is just follow the above but instead of writing your public ip address you need write your address

For example at this part:

update realmlist set address = 'your public ip address';

You need to replace the command with

update realmlist set address = '';

And then continue with the rest of setting up public wow server part. And after finished with all public wow server part, now you need to open hosts file located in Windows\System32\drivers\etc (C:\Windows\System32\drivers\etc\hosts), and then add this at the bottom of the file (for lan users change the below to the LAN IP address where the mangos server located)

And …

WoW Screenshot

That’s it you’re done … if i forgot something, don’t be shy just let me know so i can fix it immediately. And if you got any questions or have a request for the next article, feel free to post your comment :)

And, if you want to create custom npc on your mangos server, please check how to create custom npc guide

Too much work, give me the fastest way

If you feel overwhelmed by everything listed in this guide then feel free to use this option, but make sure you have mysql installed as listed on mysql guide for vista and 7 (for vista users) and mysql guide for xp for windows xp users

  1. Extract the file into C:\
  2. Copy ad.exe from tools directory into your WoW installation directory and let ad.exe finished with extracting DBC and MAPS and then move the DBC and MAPS directory to C:\WoW\data
  3. Run import.bat and when prompted for password, enter your mysql root password
  4. Start realmd.exe and mangosd.exe
  5. Edit the file and create new account as described in the Adjusting Realmlist and Creating Account part … and play

Enjoy, consider this as a supplement for this extremely long guide and oh make sure your WoW client is version 3.3.3 and it’ll create a fresh installation so if you previously have used mangos and don’t want to lose your precious data make sure to create backup first

Download Supplement from Megaupload | Download Supplement from Rapidshare


Note: Comment may not appear right away.

846 comments on “How to create WoW Private Server using Mangos

  1. Hey! Do you know if they make any plugins tto protect against hackers?
    I’m kinda paranoid about losing everything I’ve worked hard on.
    Anyy tips?

  2. iv used your guide and got to the point where i want to make the realm public
    when i type
    use realmd;
    i get the error
    ERROR 1049 : Unknown database ‘realmd’
    been trying for about a week to get it going and your guide has got me the farthest

  3. Hi! Thanks for this awesome howto.
    One question, will this work on the windows server 2012 edition (datacenter version).

  4. I like how your instructions are more about teaching how to do it step by step. The long way is the best way to learn. I’m using your explanations of MySQL commands to teach myself how to manage the database.

  5. Hey reaper,

    Thanks for the guide so far everything is working out for me. Until I hit updating the mangos sql set.
    It seems straight forward and I’ve been able to update the main update packs (up to 12097_01_mangos_mangos_string.sql)and corepatches but when I try to update to the next one (s1691_12112_01_mangos_spell_template.sql) it returns an error 1054 (42S22) at line 1: unkown column ‘required_s1667_12097_01_mangos_mangos_string’ in ‘db_version’

    I figured that the database didn’t update correctly with from the update packs so i started going backwards to find the next in sequence to start applying but to no avail. any ideas?

    1. Mangaed to figure it out, I had to alter the .sql file so the the required file matched the version i was at and it updated fine from that point on.

      Everything else worked for me, Thanks

  6. Hello , First of all . thank you for all kinds of guides you made for us :3

    Been using your guides for around 1 year by now :P

    I’ve got abit problem here , been having errors since started creating and compiling but all passed when I tried various ways to fix stuff . but now I got this problem and it looks like it’s stuck.

    At the end of the creating server, When you are about to create your account & log. Mangosd.exe won’t stay open , it closes after 1-2 seconds.

    I appreciate any kind of help.

    1. You’re welcome Shayan and sorry for the delay in response, as for Mangosd wont stay open i need to know what is in the server.txt file (or the log file as defined in mangosd.conf in your mangos directory, and paste it to so i can see what causes the problem =)

    2. oh it’s fine :3 , and sorry i can’t paste it anymore since I deleted the whole deal and I start again , no pain no gain huh? ;p

      But if I recall correctly , in server log . It said that 12002_mangos_spell_template.sql is missing from the database. Odd that I tried to fix it but it only referred to another missing sql , for example XXXX_mangos_chain_spell.sql ( dunno if I said it right).

      But well I’m trying again and thank you once again for your time and these guides.

  7. I was wondering if you were going to do a cataclysm mangos server setup? I love your work on WOTLK server. I set up these servers for my daugher, niece’s, nephew’s, so they can have a place that I can feel safe letting them play without the fear of herbert the pervert trying to get to them. I hope to hear from you soon. Keep up the good work. James

    1. Hello James,

      First of all i’m sorry for the delay in response because i’ve been away for a while and glad to hear that you liked it. And about Cataclysm, unfortunately the only thing available (even now) is still for client version 4.0.6a only, so if you’re using newer client it won’t work (well there’s the development branch, it might work, but anything higher than 4.0.6a is not supported). But i’m not sure whether it’s stable or not because i don’t even have Cataclysm installed so i can’t test it

    2. No problem with the delay, I understand you can’t be on here 24/7 and I am thankful for the responce. Do you think that you’ll be creating a Cata pack anytime in the future. I just like your style. You make the instructions easy to follow and you don’t make me feel like a monkey doing a math problem with your directions.

    3. You’re welcome James, as for creating Cata guide, actually i do have a plan on writing about it but because i’m sure people aren’t interested on reinstalling WoW again, i don’t think it is a good idea

      The reason for this is mainly because many people have patched their WoW (Cata) installation above the supported version (4.0.6a) and because this time there’s no way to revert to the old patches, you’ll need to reinstall WoW till Cataclysm expansion (4.0.6a) and then stop updating it and don’t forget that i need to download Cataclysm client first because i don’t have it lol

      Note: If you have large hard drive(s) you can easily have two separate installation one is for the emulator only while the other installation is for official servers if you’re playing on official Blizzard servers but that would take up a big portion of your harddrive

  8. Hi, i am having a problem, I am at installing the databases- installing mangos databases. i am on part installing UDB #2 And now we’re going to import the database (it may take a while depending on how fast your computer is). From the command prompt window from before, type (don’t close the command prompt window yet again) well when i put in mysql -uroot -p -v -D mangos < UDB_0.12.0_mangos_9582_SD2_1639.sql

    the command promp it says system cannot find the file specified. i downloaded the DB and extracted i just dont no what else to do from here. thanks :)

    1. You need to change directory first to where you extracted the database by using cd /d x:\location where x:\location should be changed to the sql file location :)

  9. First of all great job on these how-tos, love them. Great work.

    Now here is my question. I have setup all of this before back on the BC expansion you had a while back and even had it to were all my friends could connect to my server which was setup on it’s own box. Now I have setup a new one with all the latest updates to Mangos and the fixings, It works really well and my roommate and I can play. However I can no longer get it to be setup for external connections.

    I have all the port forwarding setup correctly as well as the firewall settings have been checked and double checked.

    I am running this now in VMware on a Windows 2008 R2 with a dedicated 2+ gigs of ram and a dedicated processor core and a dedicated NIC. It is pulling a network aaddress and is being recognized by the router. I have it set to my DDNS as the address and the is set properly too. Mind you I can setup for LAN play just fine but when I reconfigure everything for external connections it won’t work.

    Any suggestions?

    1. You’re welcome Lord Nikon, and glad to hear that you liked it :)

      As for your question, because you says about VMWare, i assume that you put and run Mangos inside a virtual machine. I have to ask you first, does your DynDNS address is set to your external/public IP Address and not your lan ip address?

      If your DDNS is already set to your external ip address, but other people from outside still can’t access your server; to make sure that there’s nothing blocking connections made to that specific port (3724) from outside source (internet) the easiest way to confirm it is by:

      0. Make sure that mangos isn’t running / stopped
      1. Install Apache or other web server you’re familiar with in that virtual machine
      2. Change Apache / the web server process to listen on port 3724 then start Apache process
      3. Try to access it from your browser using from external machine (internet)

  10. I do want to add a post here to make everyone that reads this guide aware that when you are importing the UDB sql file to your database you may find your self unable to import the file due to the fact it is 76.0mb in size and if you use mysql with php or anything else you might have sizing turned down so it can not handle that big of a file. I do how ever suggest any one that has this issue should consider opening the sql up in word pad and cutting the sql codes down in smaller sql files and import it that way. Lol the writer of this guide sorta left that warning out i guess. I also want to add that the updating of the mango database is tricky and I believe strongly that the writer of this guide should consider to redo that in a more detailed fashion.

    1. To answer your question again or perhaps criticism? because i see it that way judging from the tone of your comments on the how to compile mangos and your comment here on this page. (i love constructive criticism or good suggestions as long as they’re valid of course) =)

      I do want to add a post here to make everyone that reads this guide aware that when you are importing the UDB sql file to your database you may find your self unable to import the file due to the fact it is 76.0mb in size and if you use mysql with php or anything else you might have sizing turned down so it can not handle that big of a file

      76MB is small, and MySQL were designed to handle data much larger than that, if your system can’t handle importing 76MB mysql data there’s something completely wrong with your computer even if you’re using MySQL with PHP such size is small and NO you don’t need to edit the sql file manually in wordpad

      If you’re using phpmyadmin to import and get an error message that’s a different story but i didn’t tell anyone here to use PHPMyAdmin to import the database so if you’re doing that then it’s your fault

      As a note: due to error on anti spam protection used here, the database size of this small site gets to the size of 465MB and no problem at all if you’re importing and exporting such large data from mysql cli because even that amount is still small … but if you use php or anything other than mysql cli to import it to the mysql database then you’re not doing it right unless, you don’t have access to the mysql cli, like if you’re on shared hosting and no ssh access available, but who’s going to run a wow server on shared hosting and if you run a site and your database gets to that size you won’t be on a shared hosting plan

      Lol the writer of this guide sorta left that warning out i guess. I also want to add that the updating of the mango database is tricky and I believe strongly that the writer of this guide should consider to redo that in a more detailed fashion

      For the warning part see above, as for updating mangos database tricky? That depend on the person. I’ve tried to explain it as clearly as i can

      Tips: look at the UDB filename it state mangos 9582 which means that every mangos core update before and equal to Mangos 9582 has been applied and so we need to apply all sql updates that is released after revision 9582. And to check your mangos revision, just run mangosd.exe or realmd.exe and then open server.txt or server.log file to see the Mangos revision you’re running

      As quoted from the Updating Mangos Database part, followed by example after. So i believe i already made it as clear as i can as i believe that is already more than enough for most people except for some. But as i’m not a native english speaker, i can’t write it in proper english, so if you could write it better, could you perhaps post a correction?

      And finally I’d recommend you to head over to mangos forums instead that i think might be best for you =)

      Btw, i have replied to all of your comments on the how to compile mangos page just in case you didn’t notice

  11. It is once again time for me to reply. You said in the part Extracting DBC and Maps to add the ad.exe file found in the contrib folder to the wow installion folder. That is do able but there is a small issue here. Inside the contrib folder there are many other folders and there are at least two ad.exe files i have seen. So the question really is now which one of the two are you talking about? The one from the folder extractor or the one from the folder extractor_binary? The other issue is neither one of these work.

    1. They both same, the extractor_binary is where they put all the pre-built contrib binaries there (don’t know since when, but back then it’s located in extractor only). If it’s not working, are you running a supported wow client? at the moment the supported wow client version is 3.3.5a and older