MySQL Tech-Feed (en)

Reading other processes memory

Shinguz - Wed, 2009-08-19 09:34

[http://www.blogger.com/profile/11195863756524022642 Shinguz] said…

A colleague pointed out that I was missing some information:

The operative worklog task is WL#2360 and its dependencies, WL#4034 is a raw-idea bin item of no current significance.

The complete specification of the performance schema can be found here:

[http://forge.mysql.com/worklog/task.php?id=2333 WL#2333: SHOW ENGINE … LOCK STATUS] [http://forge.mysql.com/worklog/task.php?id=2360 WL#2360: Performance Schema] …


Taxonomy upgrade extras: 

Reading other processes memory

Shinguz - Fri, 2009-08-14 20:32

[http://www.blogger.com/profile/11195863756524022642 Shinguz] said…

Hi Morgan,

Do not get this. With the script read_process_memory.sh you can sample at a specific interval with a timestamp in the record and write a *.csv. That must be ideal for Cacti or any other monitoring/graphing tool, is it not? You could even extend it to write directly to a database…

Please elaborate a bit more your concern.


Taxonomy upgrade extras: 

Reading other processes memory

Shinguz - Fri, 2009-08-14 14:49

As you probably have experienced yet MySQL does not always provide all internal information as you might want to have them and as you are used to have from other RDBMS.

MySQL plans to improve this implementing the/a performance schema and its probably already partly done in MySQL 5.4. But who knows when this will be finished and what it contains at all…

What is not provided to me I want to gather myself… But how? Other RDBMS provide interfaces to attach applications directly to their memory to …


Taxonomy upgrade extras:  English  Process  Memory  Read  Debug 

MySQL licenses for dummies

Shinguz - Tue, 2008-12-23 12:03

The following summary shows my personal understanding of MySQL 5.1 licenses, packages and products. It does not necessarily reflect 100% the way MySQL understands it. But after all the discussions I hope it is as close as possible to the reality:

MySQL Embedded Database Server

(Download → OEM Software)

Classic  (OEM license, -MEM -InnoDB)
Pro      (= Classic +InnoDB)
Advanced (= Pro +Partitioning)

MySQL Community Sever

(Download → Download)

Community (GPL, -NDB)

MySQL Enterprise Server

(Download → …


Taxonomy upgrade extras:  English  Mysql  Upgrade  License 

Why does MySQL Cluster takes so long for --initial?

Shinguz - Fri, 2008-11-14 12:27

[http://www.blogger.com/profile/11195863756524022642 Shinguz] said…

Hey guys,

Have a look at the addendum. I have updated it.

Regards, Oli


Taxonomy upgrade extras: 

Why does MySQL Cluster takes so long for --initial?

Shinguz - Thu, 2008-11-13 21:43

This week we had a very interesting problem at a customer: They complained, that their MySQL Cluster takes about 1 hour for a --initial start-up. After some tuning on the hardware and the config.ini they brought it down to around 40 minutes. But this is still unacceptable long…

This sounds a little strange to me. But let us have a look at their config.ini first. It looked more or less like the following (which is already tuned!):

#
# config.ini
#

[NDB_MGMD DEFAULT]
DataDir                      = …

Taxonomy upgrade extras:  English  Mysql Cluster  Initial  Slow 

MySQL Multi-Master – Single-Slave – Replication (Episode 2)

Shinguz - Sun, 2008-10-19 13:33

[http://www.blogger.com/profile/11195863756524022642 Shinguz] said…

Hi Baron

Hmmm. Did not know about it. But to be honest: I did not yet have time to look at all the nice stuff from your Maatkit and all the cool Google Patches and OurDelta etc… :-(

But thanks for the hint!


Taxonomy upgrade extras: 

MySQL Multi-Master – Single-Slave – Replication (Episode 2)

Shinguz - Sun, 2008-10-19 13:30

[http://www.blogger.com/profile/11195863756524022642 Shinguz] said…

Hi Willy

Yes. MySQL circular replication usually works fine (technically). I hope you have a good concept cleaning it up again when it some how messes up!

We usually recommend customers to be very very careful with this kind of replication!

Regards Oli


Taxonomy upgrade extras: 

MySQL Multi-Master – Single-Slave – Replication (Episode 2)

Shinguz - Mon, 2008-10-13 16:17

Introduction

One of the features that make MySQL so great is its easy replication set-up. If you are experienced and know-how to do it, it takes you about 15 minutes to set-up a slave. What you have in the end is a replication from one master to one or several slaves. So you can build a top-down data stream pyramid and spread your data on many slaves.

MySQL Replication

From time to time some customers are asking for the other way: Many masters replicating to one slave (which is also called multi-source replication). For …


Taxonomy upgrade extras:  Multi-Master  Slave  Replication  Multi-Source 

Test application for MySQL high availability (HA) set-up

Shinguz - Thu, 2008-10-09 16:25

When I set-up a MySQL HA environment for customers I usually do some final failover tests after configuring the whole beast.

To check if the application behaves like expected I always run my little test application (test.sh) from the server(s) where the customers application runs. It displays “graphically” how the application behaves and you can show to the customer immediately what is going on…

Make sure, that you point it to the virtual IP (VIP) or the load balancer (LB).

It was really …


Taxonomy upgrade extras:  English  High Availability  Test  Mysql  Application  Ha 

Citation of the week

Shinguz - Thu, 2008-09-25 16:02

Das dreieckige Rad hat gegenüber dem viereckigen einen gewaltigen Vorteil: Ein Rumms weniger pro Umdrehung!

Translation:

The triangular wheel has one enormous advantage over the quadrangular: One knock less per revolution!

Maybe not new, but I have not heard it yet and I love it. It was about reinventing functionality in a well known product…


Taxonomy upgrade extras:  English  Mysql  Citation  Week 

Typical automated MySQL maintenance jobs

Shinguz - Wed, 2008-09-24 12:43

[http://www.blogger.com/profile/11195863756524022642 Shinguz] said…

Hi knetknight

Thanks for your comment.

When your are facing time/scheduling issues I recommend you to go through the MySQL online documentation (Chapter: Table Maintenance Statements and Restrictions on InnoDB Tables) because some of these commands have no effect on some table types (InnoDB) and some of them do the work already done in a previous command.

Regards Oli


Taxonomy upgrade extras: 

MySQL Cluster: No more room in index file

Shinguz - Wed, 2008-09-24 12:19

[http://www.blogger.com/profile/11195863756524022642 Shinguz] said… Hi Matthew

Thanks for your comment. This could have helped a lot. I do NOT ask why there was no message like:

Query OK, 1 row affected, 1 warning (0.10 sec)

or why the real cause was not displayed at all…


Taxonomy upgrade extras: 

MySQL Cluster: No more room in index file

Shinguz - Tue, 2008-09-23 17:18

Recently we were migrating an InnoDB/MyISAM schema to NDB. I was too lazy to calculate all the needed MySQL Cluster parameters (for example with ndb_size.pl) and just took my default config.ini template.

Because I am really lazy I have a little script doing this for me (alter_engine.pl).

But suddenly my euphoria was stopped abruptly by the following error:

MySQL error code 136: No more room in index file

The usual command that helps me in such a situation is a follows:

# perror 136
MySQL error code 136: No …

Taxonomy upgrade extras:  English  Mysql Cluster  Index File 

Possible memory leak in NDB-API applications?

Shinguz - Tue, 2008-09-23 14:20

A customer has recently experienced a possible memory leak in its NDB-API application. What he did was something like:

# ps aux | grep <pid>

over time and then he saw the RSS increasing. When he would have had a look a little longer he would have seen that the RSS consumption would increase up to a certain level and then becomes stable. Which is the expected behavior.

Possible Memory Leak

But how to explain to the customer that his application, which was in fact not doing anything, consumes more RSS?

With a diff over …


Taxonomy upgrade extras:  English  Memory Leak  Ndb-Api  Memory 

Active/active failover cluster with MySQL Replication

Shinguz - Fri, 2008-09-05 17:00

Electing a slave as new master and aligning the other slaves to the new master

In a simple MySQL Replication set-up you have high-availability (HA) on the read side (r). But for the master which covers all the writes (w) and the time critical read (rt) there is no HA implemented. For some situations this can be OK. For example if you have rarely writes or if you can wait until a new Master is set up.

But in other cases you need a fast failover to a new master.

In the following article it is shown how to …


Taxonomy upgrade extras:  English  High Availability  Mysql  Replication  Cluster  Active-Active  Failover 

Typical automated MySQL maintenance jobs, query cache

Shinguz - Mon, 2008-08-25 20:06

The following maintenance jobs are typically run against a MySQL database:

  • Backup
  • Clean-up binary logs
  • Optimize tables
  • Purge query cache
  • Rotate binary logs

Backup

A backup is not a typical maintenance job. But it behaves more or less like one. The backup should be done regularly depending on the restore/PITR (Point in Time Recovery) requirements.

Make sure, that in the backup all the necessary files (data files, transaction log files, configuration files and binary log files) are included. To prove that …


Taxonomy upgrade extras:  English  Operations  Mysql  Mainenance Jobs  Query Cache 

My thoughts about MySQL (Cluster) replication

Shinguz - Sat, 2008-06-28 13:00

According to Johans wishes I write down my concerns about MySQL (Cluster) replication. These items are things I run again and again into it with customers:

  • SQL-nodes are still loosing too easy connection to cluster after data node or management node restart (which leads into gaps, see next point). Automatic failover or reconnection is just a dream (maybe it works in about 90% of the cases at least).
  • Gaps: Whenever I do a cluster reconfiguration (should not be necessary too often, see loosing connection …

Taxonomy upgrade extras:  English  Mysql  Replication  Mysql Cluster 

Some more details about DiskSyncSize

Shinguz - Thu, 2008-05-29 14:43

The parameter DiskSyncSize is a MySQL Cluster parameter and was added in MySQL 5.1.23.

After the amount of stored bytes of data per file, the data node will fsync (flush) the LCP file to disk, even if a fsync is not needed for consistency.

This is done because the OS will otherwise buffer all the writes, and when a fsync is really needed, it can take a lot of time…

Originally this parameter was hard coded. Now it defaults to 4 Mbyte.

The parameter DiskSyncSize is related to the parameters …


Taxonomy upgrade extras:  English  Mysql Cluster  Disksyncsize  Parameter 

With MySQL-Enterprise Montior through firewalls

Shinguz - Sun, 2008-05-18 17:44

Sometimes it is nice to show customers the functionality of MySQL-Enterprise Monitor (aka Merlin). I install the agents on the servers and the dashboard runs on my laptop. But very often only ssh is open to these servers.

So how to dig a whole through the firewall for MySQL-Enterprise Monitor?

# ssh -R 18080:localhost:18080 oli@where_the_agent_sits

Maybe trivial for you but for me its hard to remember…


Taxonomy upgrade extras:  English  Mysql  Enterprise Monitor  Firewall 

Pages

Subscribe to FromDual aggregator - MySQL Tech-Feed (en)