Showing entries 1 to 10 of 15
5 Older Entries »
Displaying posts with tag: debug (reset)
MySQL QA Episode 3: How to use the debugging tool GDB

Welcome to MySQL QA Episode 3: “Debugging: GDB, Backtraces, Frames and Library Dependencies”

In this episode you’ll learn how to use debugging tool GDB. The following debugging topics are covered:

1. GDB Introduction
2. Backtrace, Stack trace
3. Frames
4. Commands & Logging
5. Variables
6. Library dependencies
7. c++filt
8. Handy references
– GDB Cheat sheet (page #2): https://goo.gl/rrmB9i
– From Crash to testcase: https://goo.gl/3aSvVW

Also expands on live debugging & more. In HD quality (set your player to 720p!)

The post MySQL QA Episode 3: How to use the debugging tool GDB appeared …

[Read more]
Debugging Percona Xtradb (Galera) Cluster node startup / SST errors

A Percona Xtradb (Galera) Cluster node may fail to join it due to many possible mistakes causing SST to fail. It could be a configuration item or purely setup requirement. In this article we will be troubleshooting step by step the SST issues faced.

The post Debugging Percona Xtradb (Galera) Cluster node startup / SST errors first appeared on Change Is Inevitable.

Compiling & Debugging MariaDB(and MySQL) in Eclipse from scratch - Part 5: "Profiling in Eclipse with OProfile"

Section 6: "Profile a real case" 6.1 INTRODUCTION

Profiling & Debugging is an argument that would require an entire book, the aim of this(and the others) posts of this series is to give you the basic knowledge on how to work with these tools and techniques withing Eclipse. For instance if you want to learn to profile with OProfile you should study on the abundant and separate resources, you may start from: http://OProfile.sourceforge.net

6.2 ABOUT NAMING THE PROJECT

read more

Compiling & Debugging MariaDB(and MySQL) in Eclipse from scratch - Part 4: "Profiling in Eclipse - Preparation"

Section 5: "Prepare Eclipse for profiling" 5.1 INTRODUCTION

In this part we will prepare Eclipse to profile our recently compiled(see Part 3) MariaDB(or MySQL).
Profiling means basically measuring where the time is spent by the application.
You may be interested in knowing how much time is spent in a specific function execution,
or you may want to know statistics about the dustribution of function calls, that is operating a data aggregation.

read more

Compiling & Debugging MariaDB(and MySQL) in Eclipse from scratch - Part 3: "Running in Eclipse"

Introduction:

To run MariaDB from Eclipse we will actually create and install the tar.gz package resulting from compilation(See Part 2) in a separate directory, this will allow us to have MariaDB cleanly installed on a separate location and so it will be also easily possible to run it independently from Eclipse.

In these Blog posts series we assume:


yoda                                                    as developer user
 

read more

Compiling & Debugging MariaDB(and MySQL) in Eclipse from scratch - Part 2: "Compile in Eclipse"

Section 2: "COMPILE MARIADB IN ECLIPSE"

2.1 Download and prepare sources folder/>

We will need a directory to use as our playground, if you create the user yoda in Section 1:

$ su - yoda
$ mkdir -p ~/playground

Download latest MariaDB 10 sources tar.gz and copy the archive into the above directory, you can latest sources from:

read more

Compiling & Debugging MariaDB(and MySQL) in Eclipse from scratch - Part 1: "Setup the building environment"

This guide will help you in compiling and debugging MariaDB (MySQL, Percona) within the Eclipse IDE on Linux and using cmake for source project preparation. It will be split in parts to keep each post lightweight and with a finite objective. At the end of reading this series of blog posts you should be able to:

  1. Prepare for compilation any MariaDB (MySQL, Percona) source release based on cmake framework.

read more

How to obtain all executing queries from a core file

When investigating core files from crashes, one can quite easily figure out which query crashed, as we've seen.

Sometimes you want to just list all the currently executing statements, this is useful for diagnosing hangs or corruptions.

At least GDB 7 supports python macros, which can help us a lot here.   I use a core file from 5.5.27, also a non-debug build but not "stripped".   So it's a standard build made with -g allowing us to reference symbols.

I wrote a simplistic macro to iterate through mysqld's global "threads" variable.
This is what my …

[Read more]
Using the MySQL stack trace to isolate bugs

I came across an interesting error reported on #mysql the other day. When I went through it with the reporter it looks like we uncovered up to two bugs in InnoDB (or rather XtraDB as it was Percona Server). I thought it might be useful to go through the error message, including the stack trace, to show that you don't need to be a developer to track down some useful information.

read more

How to produce a full stack trace for mysqld

The information here was adapted from the AskMonty Knowledgebase.

There are two main parts to MariaDB and MySQL: The mysqld server and whatever client you use to interact with the server. The server is absolutely essential and must remain up and running. mysqld is normally very reliable, but there are rare occasions when it will fail. When mysqld fails hard (or core dump) it will, by default, write a stack trace in the 'hostname'.err file in the database directory. However, in some cases this is not enough to find out exactly what happened.

If you ever run into a situation where mysqld crashes and the 'hostname'.err file does not contain enough information for your DBA or support provider to diagnose the problem, you may need to use what is known as a "debug" build to produce a "full stack trace" and a core file. …

[Read more]
Showing entries 1 to 10 of 15
5 Older Entries »