Jump to content
TrinityCore

"unknown column" "missing table" "duplicate column" error / sql problems / SQLDriverLogFile < answer on 1st post of 1st page


Apple
 Share

Recommended Posts

Hi all again, sorry to open a new thread but after my problems i've restarted with a bran new DB but i keep getting error applying automatic updates. I'm quite desperate now.

Using configuration file /usr/local/etc/worldserver.conf.
Using SSL version: OpenSSL 1.0.2a 19 Mar 2015 (library: OpenSSL 1.0.2a 19 Mar 2015)
Using Boost version: 1.58.0
Database Auth is empty, auto populating it...
>> Applying '/Users/ikirserver/Applications/trinityserver/sql/base/auth_database.sql'...
Warning: Using a password on the command line interface can be insecure.
>> Done!
Database Character is empty, auto populating it...
>> Applying '/Users/ikirserver/Applications/trinityserver/sql/base/characters_database.sql'...
Warning: Using a password on the command line interface can be insecure.
>> Done!
Database World is empty, auto populating it...
>> Applying 'TDB_full_335.58_2015_03_21.sql'...
Warning: Using a password on the command line interface can be insecure.
>> Done!
Updating Auth database...
>> Auth database is up-to-date! Containing 11 new and 24 archived updates.
Updating Character database...
>> Applying update "2015_05_08_00_characters.sql" '0F14B78'...
Warning: Using a password on the command line interface can be insecure.
>> Applying update "2015_05_22_00_characters.sql" '65B8215'...
Warning: Using a password on the command line interface can be insecure.
>> Applied 2 queries. Containing 3 new and 22 archived updates.
Updating World database...
DBUpdater: Given update include directory "/Users/ikirserver/Applications/trinityserver/sql/old/3.3.5a/world" isn't existing, skipped!
>> Applying update "2015_03_21_00_world.sql" 'C53246C'...
Warning: Using a password on the command line interface can be insecure.
>> Applying update "2015_03_21_01_world.sql" '0432783'...
Warning: Using a password on the command line interface can be insecure.
>> Applying update "2015_03_21_02_world.sql" '6D86E0C'...
Warning: Using a password on the command line interface can be insecure.
>> Applying update "2015_03_22_00_world.sql" 'D96C821'...
Warning: Using a password on the command line interface can be insecure.
>> Applying update "2015_03_22_01_world.sql" '629EE57'...
Warning: Using a password on the command line interface can be insecure.
ERROR 1146 (42S02) at line 22: Table 'world.quest_template_addon' doesn't exist
Applying of file '/Users/ikirserver/Applications/trinityserver/sql/updates/world/2015_03_22_01_world.sql' to database 'world' failed! If you are an user pull the latest revision from the repository. If you are a developer fix your sql query.
Could not update the World database, see log for details.
Assertion failed: (ec == 0), function unlock, file /SourceCache/libcxx/libcxx-120/src/mutex.cpp, line 45.
Abort trap: 6
ikir-server:bin ikirserver$ 

Any idea? I've dowloaded the DB as new but when i run the world server for the fist time i got this

Link to comment
Share on other sites

I've downloaded compiled trinity core as usuale with those commands:

cd ~/Downloads

rm -d -f -r ./TrinityCore

git clone git://github.com/TrinityCore/TrinityCore.git ./TrinityCore



cd ~/Downloads/TrinityCore
git checkout 3.3.5

 

 

Compiled this way

sudo chown -R `whoami` $HOME/Applications/trinityserver



rm -d -f -r ~/Downloads/TrinityCore/build
mkdir ~/Downloads/TrinityCore/build
cd ~/Downloads/TrinityCore/build
export PATH=/usr/local:/usr:$PATH
/usr/local/bin/cmake ../ -GXcode \
-DPREFIX="$HOME/Applications/trinityserver" \
-DWITH_COREDEBUG=0 \
-DWITH_WARNINGS=1 \
-DTOOLS=1 \
-DSERVERS=1 \
-DSCRIPTS=1 \
-DUSE_SCRIPTPCH=1 \
-DUSE_COREPCH=1 \
-DOPENSSL_CRYPTO_LIBRARIES="/usr/local/lib/libcrypto.a" \
-DOPENSSL_SSL_LIBRARIES="/usr/local/lib/libssl.a" \
-DMYSQL_LIBRARY="$HOME/Applications/trinityserver/mysql/lib/libmysqlclient.a" \
-DMYSQL_CONFIG="$HOME/Applications/trinityserver/mysql/bin/mysql_config" \
-DBoost_THREAD_LIBRARY_DEBUG="/usr/local/lib/libboost_thread.a" \
-DBoost_PROGRAM_OPTIONS_LIBRARY_DEBUG="/usr/local/lib/libboost_program_options.a" \
-DBoost_SYSTEM_LIBRARY_RELEASE="/usr/local/lib/libboost_system.a" \
-DBoost_PROGRAM_OPTIONS_LIBRARY_RELEASE="/usr/local/lib/libboost_program_options.a" \
-DBoost_SYSTEM_LIBRARY_DEBUG="/usr/local/lib/libboost_system.a" \
-DBoost_THREAD_LIBRARY_RELEASE="/usr/local/lib/libboost_thread.a" \
-DMYSQL_CONFIG="$HOME/Applications/trinityserver/mysql/bin/mysql_config" \
-DCMAKE_C_FLAGS="-m64 -Ofast" \
-DCMAKE_CXX_FLAGS="-m64 -Ofast"
xcodebuild -alltargets clean
xcodebuild -target install -config Release -arch x86_64 -sdk macosx10.9 -jobs $(sysctl -n hw.ncpu)

 

 

Always done that to compile/update. Without touching the databases if i run my server with updated world server i got error on characters database posted in the older thread. If i start brand new i got this issue instead.

Link to comment
Share on other sites

I'm not sure how this would have been fixed by an update to a table in the characters database that doesn't even exist in my database... Not that having an update log with hashes isn't a good idea, just not sure why the table was never added via updates.

EDIT: Found the characters-db updates from March in my 'sql/old/3.3.5a/characters/57_2014_10_19' folder. Strange that they were moved there without my noticing. Applying them now.

At any rate, I got much of the same output as ikir when I tried to start my worldserver after compiling two hours ago. It looks as though the build files weren't updated to match the new column names in the characters database.

Edited by shadedmagus
Link to comment
Share on other sites

  • 1 month later...

I just got this error :

TDB version : TDB_full_world_335.59_2015_07_14
Applied updates :
2015_07_14_00_world
2015_07_15_00_world_2015_07_14_02
2015_07_15_01_world_2015_07_14_05
2015_07_15_02_world_2015_07_14_03
2015_07_15_03_world_2015_07_14_04
2015_07_15_04_world_2015_07_15_00
2015_07_18_00_world

File : 2015_07_18_01_world.sql

Error occured at:2015-08-15 18:43:50
Line no.:287
Error Code: 1054 - Unknown column 'phaseId' in 'field list'

 

My bad didnt apply branch 3.3.5 on clone xD

Edited by SumiaGaming
Link to comment
Share on other sites

I have followed all the guides closely.  I created a new SQL user with root-level permissions and seemed to get Trinity to talk to SQL.

However, when I try to start worldserver for the first time, so it can install the databases, I get the following:                    

Using configuration file /home/server/server/etc/worldserver.conf.
Using SSL version: OpenSSL 1.0.1f 6 Jan 2014 (library: OpenSSL 1.0.1f 6 Jan 2014)
Using Boost version: 1.55.0
Could not connect to MySQL database at 192.168.1.101: Unknown database 'auth'
Database "auth" does not exist, do you want to create it? [yes (default) / no]: 
yes
Creating database "auth"...
Applying of file 'create_table.sql' to database 'auth' failed! If you are an user pull the latest revision from the repository. If you are a developer fix your sql query.
Failed to create database auth! Has the user `CREATE` priviliges?

DatabasePool Login NOT opened. There were errors opening the MySQL connections. Check your SQLDriverLogFile for specific errors.

I am not seeing any errors in my MySQL error.log  Any ideas?  I extracted the latest TDB (TDB_full_world_335.59_2015_07_14.sql) from the ZIP and placed it in the /bin folder.  Am I missing something?  Did I skip a step?  Any help is appreciated!

Link to comment
Share on other sites

I found two issues.  1st, I created the 3 databases manually through the mysql CLI.  Then, I tried starting worldserver again, it threw an error stating it didn't have the location of the mysql CLI in the worldserver.conf  Once I remedied that, it seemed to go through and populate the databases as expected.

Link to comment
Share on other sites

Hello,

I'm having troubles starting the server, I've been fixing errors for 5 days now :/

Here's my problem now :

TrinityCore rev. unknown 1970-01-01 00:00:00 +0000 (Archived branch) (Win32, Debug) (worldserver-daemon)
<Ctrl-C> to stop.

 ______                       __
/\__  _\       __          __/\ \__
\/_/\ \/ _ __ /\_\    ___ /\_\ \, _\  __  __
   \ \ \/\`'__\/\ \ /' _ `\/\ \ \ \/ /\ \/\ \
    \ \ \ \ \/ \ \ \/\ \/\ \ \ \ \ \_\ \ \_\ \
     \ \_\ \_\  \ \_\ \_\ \_\ \_\ \__\\/`____ \
      \/_/\/_/   \/_/\/_/\/_/\/_/\/__/ `/___/> \
                                 C O R E  /\___/
http://TrinityCore.org                    \/__/

Using configuration file worldserver.conf.
Using SSL version: OpenSSL 1.0.2d 9 Jul 2015 (library: OpenSSL 1.0.1e 11 Feb 2013)
Using Boost version: 1.55.0
Updating Auth database...
>> Auth database is up-to-date! Containing 2 new and 39 archived updates.
Updating Character database...
>> Applying update "2015_08_12_00_characters.sql" '4FD7F89'...
Applying of file 'D:/Trinity/Src/sql/updates/characters/2015_08_12_00_characters.sql' to database 'character' failed! If you are an user pull the latest revision from the repository. If you are a developer fix your sql query.
Could not update the Character database, see log for details.

 

Link to comment
Share on other sites

I couldnt get the updates to work so I set my config to skip it now im stuck with it saying my world database is out of date. It says im missing "gameobject.template.local". Ive already installed the latest update and Im just stuck at how to fix thise. Its one error after another everytime i try to get this world started.

Link to comment
Share on other sites

  • 4 weeks later...

Before I get into this, I just want to state that I've been a programming hobbyist for over 15 years. I've simply never gotten into any project that required so many different programs to compile and run the final product. Call me a noob if you must.

The title states the problem I am having. I've followed the instructions at http://collab.kpsn.org/display/tc/Installation+Guide to the letter, but when I got to the step to run bnetserver (on Server Setup), it gave me the following error log:

TrinityCore rev. 3fceabfa1139 2015-09-29 00:11:26 +0200 (6.x branch) (Win32, Release) (bnetserver)
<Ctrl-C> to stop.
Using configuration file bnetserver.conf.
Using SSL version: OpenSSL 1.0.2d 9 Jul 2015 (library: OpenSSL 1.0.2d 9 Jul 2015)
Using Boost version: 1.59.0
Automatic database updates are disabled for all databases!
Opening DatabasePool 'auth'. Asynchronous connections: 1, synchronous connections: 1.
Could not connect to MySQL database at 127.0.0.1: Access denied for user 'root'@'localhost' (using password: YES)
DatabasePool Login NOT opened. There were errors opening the MySQL connections. Check your SQLDriverLogFile for specific errors. Read wiki at http://collab.kpsn.org/display/tc/TrinityCore+Home

I'm running windows 7 32bit. I'm not sure what else to offer. I feel like there was something I've missed, but I've gone over the instructions about a dozen times. The one thing that bothers me is that when I downloaded the Trinity Repack and ran it, there was MySQLStarter.exe to run before bnetserver. Apparently, something else is supposed to take the place of that in the collab instructions. When I open HeidiSQL to look at the MySQL database, it doesn't look anything like the repack database. I know I either missed some step or messed something up regarding that, but for the life of me I cannot figure out what. ANY help would be appreciated.

Going over the Database installation page again...

Downloading the Database
Download the latest database compilation from TrinityCore Downloads.
Click the green Download button on top right next to right column.
The file is in .7z format, so you will need an archive program like 7zip to unpack it.
Important: There are multiple .sql files to choose from in the .7z archive. If this is your first time installing TrinityCore, you will ONLY need the file with "TDB_full" at the beginning.
Installing The Trinity Databases
6.x
Trinity needs 4 databases to run at 6.x branch - Auth, Characters, Hotfixes and World:
auth - holds account data - usernames, passwords, GM access, realm information, etc.
characters - holds character data - created characters, inventory, bank items, auction house, tickets, etc.
world - holds game-experience content such as NPCs, quests, objects, etc.
hotfixes - holds fixes not already added to the core or other official databases.

The very next step is to open the worldserver.conf file, but it doesn't say what to do with the data files I got from the .7z file. I tried to run them in Heidisql, but that only led to errors and didn't change the database that currently running on my system. I'm pretty sure something needs to be done to add those files to the database, or to start a new database with those files somehow, but I'm lost as to what to do and the instructions don't say anything about it. Again, any help would be appreciated.

Edited by TechnicDragon
Link to comment
Share on other sites

You said a dirty word around these parts... repack. The devs here won't offer support or assistance if you are attempting to setup a repack and will tell you to ask on the forums where you found the repack if you are having trouble setting it up.

Regardless of that... your problem has something to do with your SQL access rights... user, pass or remote access using 'root'. Accessing SQL via 'root' is typically advised against.

 

Link to comment
Share on other sites

My apologies for my word choice, but I was using the repack as a sort of gauge, to see what my target final compilation should/could/might look like. I'm not attempting to distribute anything. Should I programmatically fix something that's not working, then I'm happy to share that, but that's all this is about, right?

Problem: Okay, I uninstalled MySQL to run the installation again with screenshots.

001.png002.png003.png004.png

After the above step, I went back and removed Python from the list via custom install...

005.png006.png007.png008.png009.png010.png011.png

The above step is exactly as it appeared when I got to it, like most, I left the settings as they were.

012.png

The above screenshot is where I believe I messed up originally.

I added a password, because without it, I couldn't continue. This time though, I also noticed the "Add User" button.

013.png

I added a user...

017.png

Then things really went sideways...

The WindowsServiceName changed automatically to what you see below. I checked running services on my system. Even after uninstalling MySQL, it was still listed. It wasn't running, but it was listed. I think that's why this changed like it did.

018.png

I pressed on...

019.png

I clicked on Execute in the above screenshot and when it got down to "Applying security settings" it errored out. Here's the error log:

Beginning configuration step: Stopping Server [if necessary]
Ended configuration step: Stopping Server [if necessary]

Beginning configuration step: Writing configuration file
Ended configuration step: Writing configuration file

Beginning configuration step: Updating firewall
Adding firewall rule for MySQL56 on port 3306.
Successfully added firewall rule.
Ended configuration step: Updating firewall

Beginning configuration step: Adjusting Windows service [if necessary]
Attempting to grant Network Service require filesystem permissions.
Granted permissions.
Adding new service
New service added
Ended configuration step: Adjusting Windows service [if necessary]

Beginning configuration step: Initializing Database [if necessary]
Initialize is only compatible for 5.7.7 or above, no need for Initialize the Database
Ended configuration step: Initializing Database [if necessary]

Beginning configuration step: Starting Server
Starting MySQL as a service
Ended configuration step: Starting Server

Beginning configuration step: Applying security settings
Attempting to update security settings.
Authentication to host 'localhost' for user 'root' using method 'mysql_native_password' failed with message: Access denied for user 'root'@'localhost' (using password: YES)
Ended configuration step: Applying security settings

It asks if I would like to try again. I click Yes, but it can't seem to shut down the server to apply the security settings. So, now i'm stuck again, only a step back from where I was before. I feel like I'm digging myself a nice deep hole that I'm not going to be able to get out of (short of formatting my hard drive!)

Any suggestions?

Link to comment
Share on other sites

Hello!

I have been following the official guide for a while now, and was just about to launch for the first time. Now I am stuck here:

TrinityCore rev. ba009ea2e2d1 2015-09-29 21:15:19 +0200 (3.3.5 branch) (Unix, Release) (worldserver-daemon)
<Ctrl-C> to stop.

 ______                       __
/\__  _\       __          __/\ \__
\/_/\ \/ _ __ /\_\    ___ /\_\ \, _\  __  __
   \ \ \/\`'__\/\ \ /' _ `\/\ \ \ \/ /\ \/\ \
    \ \ \ \ \/ \ \ \/\ \/\ \ \ \ \ \_\ \ \_\ \
     \ \_\ \_\  \ \_\ \_\ \_\ \_\ \__\\/`____ \
      \/_/\/_/   \/_/\/_/\/_/\/_/\/__/ `/___/> \
                                 C O R E  /\___/
http://TrinityCore.org                    \/__/

Using configuration file /home/trinity/server/etc/worldserver.conf.
Using SSL version: OpenSSL 1.0.1k 8 Jan 2015 (library: OpenSSL 1.0.1k 8 Jan 2015)
Using Boost version: 1.55.0
Database Auth is empty, auto populating it...
>> Applying '/home/baron/TrinityCore/sql/base/auth_database.sql'...
Applying of file '/home/baron/TrinityCore/sql/base/auth_database.sql' to database 'auth' failed! If you are an user pull the latest revision from the repository. If you are a developer fix your sql query.
Could not populate the Login database, see log for details.

I'm not sure what is causing this, as the log it tells me to view doesn't have anything in it.

Where do I go from here?

Link to comment
Share on other sites

re: repacks... it's not about you distributing anything it's more about supporting something that may have been mangled by whoever put the repack together that you are using.

To be clear- to get anything beyond what limited help I can provide you'll need to be self-compiling from the source that is in the TrinityCore GitHub repository.

re: the mySQL issues... uninstalling mySQL is not as easy as Control Panel > Add\Remove Programs > Uninstall mySQL.

http://serverfault.com/questions/103127/how-to-completely-remove-mysql-from-windows

...I run my Trinity install on a linux server so won't be of much help on the windows side.

Link to comment
Share on other sites

I think the wiki skips over the part where you're supposed to import the sqls that setup the database structure.

If you check your source directory there should be a directory that has import scripts for auth and characters. My server is shut down right now so I can't tell you the exact path but I think it might be \source\sql\base?

Edited by m_pan
Link to comment
Share on other sites

The wiki states that if I just leave the TDB_full sql file in the same folder as worldserver, it will simply import itself and set everything up automatically, so manual import isn't necessary. It appears that it is trying to do that, but is failing for some unknown reason.

There are two files in TrinityCore/sql/base titled auth_database.sql and characters_database.sql, as you said, but I don't know what to do with them. Running them tells me no permissions, running them with sudo just throws "command not found". According to the error these are the files that worldserver is trying to start.

Link to comment
Share on other sites

This step gave me issues too and I remember not being certain of what I was doing at the time so I didn't take notes on what finally worked for me. I need to boot my server up to be certain but here's the jist- (read the TL;DR at the bottom before you do anything.)

Trinity runs on three databases- auth, character and world. auth handles credentials like account name, password, email and the like. characters handles character names, class, level, etc. and world contains the game world proper- NPCs, creatures, quests, game objects, armor, weapons, items and everything else you see once you're logged in and playing.

For the most part the only ones that get modified by your actual install are the auth and characters DBs... world for the most part is static unless you get into custom stuff like adding NPCs or custom items. TDB_full_:blahblah::.sql only contains content for the world database. auth and characters gets populated as you add accounts and those accounts create characters.

Before these databases can be populated with data the table structure needs to be defined and this is the step that I think you (and the install wiki) may be missing. I think the wiki is missing steps 1-5 below... I used the 3.3.5 branch so YMMV if using the 6.X branch...

I think these are the steps I took that finally resulted in success...

(As mysql root) - I used /source/sql/create/create_mysql.sql as a template but probably just copy\pasted commands directly into the mysql console.

1. Created a new user for Trinity. (You can run Trinity under the sql root account, but this is a bad security practice. A dedicated user should be created with only the permissions on just the 3 databases needed to function.)

2. Created the three databases: auth, characters, world.

3. Grant needed privileges on auth, characters and world to the new user

(switch to trinity user)

4. import auth structure (/source/sql/base/auth_database.sql)

5. import characters structure (/source/sql/base/characters_database.sql)

(really unsure past this point)

I can't remember if I manually imported TDB_full or if I let the server startup do this automatically. I think I did it manually but the preceding steps should give you an idea of the workflow as it's really just repeating the same steps for each database. Now that I'm thinking about it again I think I may have done steps 1 - 3 manually by SSH through the mysql console then connected to the database using my SQL client (I use SQLyog Community, others recommend HeidiSQL) to import the structure queries in the /source/sql/base/ directory.

If you create a dedicated trinity user don't forget to update the auth and worldserver configs with the new name and password.

 

TL;DR- looking at all that I've written I'm sure that I could probably rewrite it to be more concise and to the point but it is what it is. Entirely possible that all you're missing is importing the /source/sql/create/create_mysql.sql query. As I said above I don't like running as root and I don't like running as the default 'trinity;trinity' that the create_mysql query sets it up as. Hell... probably get away with just creating your database user and editing the create query with the new user and password.

Link to comment
Share on other sites

Okay, got MySQL completely uninstalled and then reinstalled again. No errors. I have the user and password I made during the install. HeidiSQL finds the database and opens it. However, what I get does not include Auth, Characters, World, or Hotfixes. Here is what I get when I open HeidiSQL:

Heidi_SQL_000.png

I've gone through the instructions several times. There is nothing in there about either creating a database or adding the Loads that I downloaded for the database. oh, and when I try to run bnetserver.exe, this shows up in the log:

TrinityCore rev. 3fceabfa1139 2015-09-29 00:11:26 +0200 (6.x branch) (Win32, Release) (bnetserver)
<Ctrl-C> to stop.

Using configuration file bnetserver.conf.
Using SSL version: OpenSSL 1.0.2d 9 Jul 2015 (library: OpenSSL 1.0.2d 9 Jul 2015)
Using Boost version: 1.59.0
Automatic database updates are disabled for all databases!
Opening DatabasePool 'auth'. Asynchronous connections: 1, synchronous connections: 1.
Could not connect to MySQL database at 127.0.0.1: Unknown database 'auth'

DatabasePool Login NOT opened. There were errors opening the MySQL connections. Check your SQLDriverLogFile for specific errors. Read wiki at http://collab.kpsn.org/display/tc/TrinityCore+Home

Unknown database 'auth' is the line that concerns me. It's not in HeidiSQL and bnetserver isn't finding it. I'll walk through the compilation again from the start, but I do not believe I'm wrong (again, I'm following the instructions http://collab.kpsn.org/display/tc/Installation+Guide).

Link to comment
Share on other sites

Join the conversation

You can post now and register later. If you have an account, sign in now to post with your account.

Guest
Reply to this topic...

×   Pasted as rich text.   Paste as plain text instead

  Only 75 emoji are allowed.

×   Your link has been automatically embedded.   Display as a link instead

×   Your previous content has been restored.   Clear editor

×   You cannot paste images directly. Upload or insert images from URL.

 Share

  • Recently Browsing   0 members

    No registered users viewing this page.


  • Similar Content

    • By xgamerninjax
      Hello all, first time posting here and it's really got me scratching my head.
      I've compiled everything on my own computer, and then transferred everything to a host computer so the server can stay live. The server was running fine for a month or so and then suddenly it just crashes when it hits "Loading C++ scripts", exiting saying "caught signal 22"
      I tried setting up the host computer from scratch and transferred everything over fresh and it's still happening for some reason. (Note, I can run the server perfectly on my personal pc where I compiled it.)
      Any help would be greatly appreciated, thanks!
      3d7e3a40e2b3+_worldserver.exe_[1-4_15-19-45].dmp 3d7e3a40e2b3+_worldserver.exe_[1-4_15-19-45].txt
    • By Rochet2
      A lot of people have asked how to debug so I made this short guide on how to set up debugging.
      This guide only tells you how to actually set up debugging in TrinityCore on Windows and Linux.
      This will not explain the basics of debugging. You can google those or play around with the debugger to learn.
      Here are a few videos that explain how to actually debug after setting debugging up on visual studio: https://youtu.be/0ebzPwixrJA and linux: https://www.youtube.com/watch?v=sCtY--xRUyI

      This guide contains multiple guides. Each list of bullet points is it's own guide.
      Make sure you can run the server normally before trying to debug.

      Windows:
      On Windows before anything you should check these
      - Before debugging or making crashlogs etc. with Visual Studio you must compile the core in "Debug" instead of "Release". You can select this in "Build>Configuration Manager" or at the top of Visual Studio window http://i.imgur.com/5oHd59j.png
      - You also need to move the new pdb files generate by compiling in debug mode on Visual Studio from the compile output folder (bin) to your server folder - these files contain information needed for debugging.
      - It is assumed that Solution Explorer is open. Open it by selecting "View>Solution Explorer" in Visual Studio http://i.imgur.com/hkW6Gk0.png
      -- You may want to click on the Home icon to reset the view on Solution Explorer http://i.imgur.com/N8UPwDh.png
      - You can place breakpoints in Visual Studio editor by right clicking a line of code and selecting "Breakpoint>Insert Breakpoint" http://i.imgur.com/L2TxBVG.png
      - At the top of the window you should see controls for stepping and continuing when you have started to debug.
      - Here is a video showing the basic Visual Studio functionality https://www.youtube.com/watch?v=Ijdk4z8-2OI
      Fastest way to debug on windows. This is the easiest way to start up debugging a script.
      - Start the authserver and worldserver normally
      - Open TrinityCore.sln in Visual Studio. This is what you usually open when you want to compile the core
      - In Visual Studio at the top select "Debug>Attach to process...>worldserver.exe" and click "Attach" http://i.imgur.com/jDEI2Hq.png
      - You are now debugging
       
      The second slower way of debugging on windows. This is useful for debugging something that occurs in the startup of the server.
      - Open TrinityCore.sln in Visual Studio. This is what you usually open when you want to compile the core
      - In solution explorer right click on worldserver and select "Set as StartUp Project" http://i.imgur.com/wvMzeRA.png
      - In solution explorer right click on worldserver and select "Properties" http://i.imgur.com/rTNEF9O.png
      -- In Properties you should go to "Configuration Properties>Debugging" and edit "Working Directory" to point to the server folder. For me this is the default compile folder so I use "$(OutDir)" http://i.imgur.com/aRI29fB.png
      - Start the authserver normally
      - Start the worldserver by selecting "Debug>Start Debugging". The server will start with debugging attached from the beginning http://i.imgur.com/cg1KJNw.png
      - You are now debugging
      Crashlogs on windows. Once you have a way to reproduce a crash you can get a crashlog that can help you resolve it.
      - After compiling the core in "Debug" instead of "Release" start up the worldserver and authserver
      - Reproduce the crash you have
      - In the server folder there is now a folder called Crashes that contains txt and dmp files. http://i.imgur.com/9eQIdql.png
      - You can open the txt files in text editors http://i.imgur.com/EH6R17E.png
      -- At the top of a txt file there is some information about your system and below it there is the Call Stack and below that there are Variables of each part of the call stack
      -- The Call Stack will tell you at the top what was the last function call before crashing and what function calls led to that function call.
      -- Next to the function names there is the file that the function is defined in and the line number the code was executing in that function.
      -- In the Variables section you can inspect variables that were present at each function call.
      -- Based on this information you are often able to see what crashed or get a better view of what you need to inspect more in your code.
      - The dmp file can be opened in Visual Studio
      -- Open TrinityCore.sln in Visual Studio. This is what you usually open when you want to compile the core
      -- Drag and drop the dmp file to Visual Studio
      -- In the window that opens click to "Debug with Native Only" http://i.imgur.com/OgyU2kM.png
      -- In the window popup click "Break" http://i.imgur.com/4jDzqRn.png
      -- You are now in a state like you would have hit a break point in the code or a crash while debugging. You can inspect the call stack and the variables.
      Edit and continue on windows. When debugging this allows you to change the code and without restarting the server apply those changes so they actually work ingame.
      - Open TrinityCore.sln in Visual Studio. This is what you usually open when you want to compile the core
      - In solution explorer right click on worldserver and select "Properties" http://i.imgur.com/rTNEF9O.png
      -- In Properties select "Configuration Properties>Linker>General" and set "Enable Incremental Linking" to "Yes". http://i.imgur.com/caQqwN5.png
      -- In Properties select "Configuration Properties>Linker>Advanced" and set "Image Has Safe Exception Handlers" to "No". http://i.imgur.com/FYzN8Ks.png
      -- In Properties select "Configuration Properties>C/C++>General" and set "Debug Information Format" to "Program Database for Edit And Continue". http://i.imgur.com/pxQ6I8N.png
      - At the top of the window select "Tools>Options". In the Options select "Debugging>General" and in there select "Enable Edit and Continue", "Enable Native Edit and Continue" and "Require source files to exactly match the original version".
      - Compile the server for the changes to take effect.
      - Set up "The second slower way of debugging" (I did not test edit and continue on other configurations)
      - Start the authserver normally
      - Start the worldserver by selecting "Debug>Start Debugging".
      - Try edit a cpp file a little and save it.
      - At top of Visual Studio window select "Debug>Apply Code Changes" and wait until the changes are applied. Warning: it can take considerable amount of time for the changes to be applied. http://i.imgur.com/77pb58E.png
      - If you have issues, be sure to check the error messages in Output. You can view it by selecting "View>Output" http://i.imgur.com/4cIznW9.png
      - This guide was written based on https://msdn.microsoft.com/en-us/library/esaeyddf.aspx and https://blogs.msdn.microsoft.com/vcblog/2015/07/22/c-edit-and-continue-in-visual-studio-2015/
      Linux:
      First we need to compile the server in debug mode.
      - Compile the server with the cmake flag -DCMAKE_BUILD_TYPE=Debug

      Debugging on linux. You can debug on linux by using GDB.
      - Here is a good video about it: https://www.youtube.com/watch?v=sCtY--xRUyI
      - Basically you
      -- Start the authserver
      -- Start the worldserver by using "gdb ./worldserver"
      -- Enter breakpoints by using break command on gdb
      -- Use the run command on gdb to start the server
      -- You are now debugging
      - You may also be interested in using VScode or some other more visual debuggers. https://www.youtube.com/watch?v=B0xTgyCwsAo
      Crashlogs on linux. Once you have a way to reproduce a crash you can get a crashlog that can help you resolve it.
      - Take crashreport.gdb from /contrib/debugger from source folder and place it to your server folder
      - Start the authserver
      - Start the worldserver by using "gdb -x crashreport.gdb ./worldserver"
      - Reproduce your crash
      - There should be a backtrace.log in your server folder that contains information about the crash like the callstack and variables in each function call in the call stack
      - This guide was written based on https://github.com/TrinityCore/TrinityCore/blob/master/contrib/debugger/README
      Running valgrind on linux. This helps you find memory errors like invalid reads and writes and memory leaks.
      - Here is a good video about it: https://www.youtube.com/watch?v=fvTsFjDuag8
      - Basically you
      -- Start the authserver
      -- Start the worldserver by using "valgrind ./worldserver"
      -- Run your code that you want to analyze and close the server
      -- The console or an output log should contain the valgrind log
    • By reyne
      Hey there!

      I've followed a few threads here about map extraction, and am still having issues. Originally, I was having the issue described here.
      After following the advice given in that thread (creating characters of both BC races and running around for a bit), I am no longer getting that error, however now I get the following error while trying to extract maps:

      `Error loading World\Maps\Expansion01\Expansion01_42_6.adt`

      This repeats for every line in Expansion01, and then the extractor crashes.

      I'm not sure where else to go from here.

      Thanks for your help

      Edit: I've created an 85 on an i85 server and flown all around Outland now, same issue.
    • By Uee
      I recently found the Trinity Cataclsym Preservation Project and thought I will try it out.
      I am already running 3.3.5a and Master - both server run great
      Pulled 4.3.4 down using Git and built it same way as others:
      boost_1_73_0 cmake 3.17.2 Mysql 5.7.30 VS Community 2019 Built fine - no issue. Used 'Extractor.bat' to run all the map extractors - worked great!
      Noticed there was extra file 'connection_patcher.exe`, ran that - worked great! Now have "wow_patched" and use this to launch client
      MySQL runs in standalone mode, -initialize, added base sql files, imported, auth and character sql files
      Configured both the .conf files and passwords, IPs etc are all in place.
      Note: When loading the exe and built conf file, bnetserver complain about these items missing, so I add them:
      Updates.AutoSetup = 1 Updates.EnableDatabases = 0 LoginDatabase.SynchThreads = 1 Load up Mysql - loads fine
      Load up bnetserver and appears to load ok - last few lines look like this:
      Connected to MySQL database at 127.0.0.1
      DatabasePool 'auth' opened successfully. 2 total connections running.
      Started auth database connection pool.
      Listening on connections from worldservers on port 1118...
      Load up worldserver and it adds the FULL world and hotfixes, then applied all updates (confirmed archived in SQL) - last few lines look like this:
      Calculate next monthly quest reset time...
      Calculate random battleground reset time...
      Calculate guild limitation(s) reset time...
      Calculate next currency reset time...
      World initialized in 0 minutes 13 seconds
      TrinityCore rev. d0c7bbab40bc 2020-05-06 00:01:21 +0200 (master branch) (Win64, RelWithDebInfo, Static) (worldserver-daemon) ready...
       
      There are no db errors in logs.
      Config.wtf contain portal, realmlist as remote server and patchlist as localhost.
      When I try to connecting using "[email protected]" and password I get immediately disconnected.
      What I did noticed different is that the bnetserver doesnt add "Added realm "Battle for Azeroth" at 192.168.10.213:8085." (From my Master log) 
      3.3.5a also have this line as last line in authserver - but 4.3.4 is not giving me this one.
      Realmlist table is accurate with right information.
      Anyone know why bnetserver is not starting me realm?
       
    • By Deer_Hunter
      Hello all,
      I just updated from the latest Git 
      Trinity Core REV. ac6baa547376 + 2020-02-21  3.3.5 Branch.
      I'm getting this error after crash.
      Problem signature:
        Problem Event Name:    APPCRASH
        Application Name:    worldserver.exe
        Application Version:    0.0.0.0
        Application Timestamp:    5e50a462
        Fault Module Name:    StackHash_f12f
        Fault Module Version:    6.3.9600.19629
        Fault Module Timestamp:    5e2fdc0d
        Exception Code:    c0000374
        Exception Offset:    PCH_9E_FROM_ntdll+0x0000000000090D0A
        OS Version:    6.3.9600.2.0.0.272.7
        Locale ID:    1033
        Additional Information 1:    f12f
        Additional Information 2:    f12f0934d3e965f73c68e60f20f2cd40
        Additional Information 3:    7595
        Additional Information 4:    7595e4d8d703db9dcd3d2f6ea540e357
      the exception code says its a Heap error,  I'm not sure how to troubleshoot this.
      Thanks
×
×
  • Create New...