Linux Sysadmin Blog

Linux Sysadmin Blog header image 4

Entries Tagged as 'MySQL'

Server and backup woes

November 17th, 2008 · No Comments · cpanel, Down Time, hosting, monitoring, MySQL, sysadmin

Looking back it seems like most posts on this blog are helpful tips and not reports of problems we encountered. Not that we don’t have any problems but we mostly report our solutions instead of the actual problems. Of course now and again a problem comes along that doesn’t have a solution ready to copy-paste [...]

[Read more →]

Tags: ······

Homegrown MySQL monitoring

October 23rd, 2008 · No Comments · monitoring, MySQL, Nagios, sysadmin

If you can’t do it with a shell script it usually ain’t worth doin’, right? Of course the number and quality of monitoring tools available to sys admins has gone up dramatically. Thanks to Nagios and other great tools it’s pretty easy to keep track of what’s going on and where and get notified pretty [...]

[Read more →]

Tags: ···

MySQL replication problems

October 9th, 2008 · 2 Comments · monitoring, MySQL, Replication

We are using a replication setup for our databases. The master database takes care of all the transactions and the slave database is used for hot standby, making backups and running reports. Running mysqldump for backups locks the main tables one by one (we’re using the MyISAM storage engine) and was causing user interruptions. Hence [...]

[Read more →]

Tags: ···

When MySQL starts counting sheep

September 4th, 2008 · No Comments · monitoring, MySQL, Performance

We encountered a situation recently where the number of connections to our MySQL database started creeping up slowly but steadily. Strangely enough all the connections were in sleep mode and the database was not being stressed. The number of connections first reached 30 where it normally stays below 20 and started triggering our monitoring scripts. [...]

[Read more →]

Tags: ···

Enabling and using the slow query log in MySQL

August 26th, 2008 · 2 Comments · MySQL, Performance

By special request here is a post about the MySQL slow query log. MySQL has a wonderful feature that lets you keep track of all queries that took longer than a certain time to complete. To enable it simply add the following line to your my.cnf file: log-slow-queries = [path to the log file] Secondly [...]

[Read more →]

Tags: ··

Changing the MySQL replication master host

July 24th, 2008 · 2 Comments · MySQL

Here’s a little post on how to change the master database host that the replication slave in a MySQL replication setup uses. This can happen if there is a change in network addresses or when you want to switch over to using different internal network. The main thing to keep in mind is that when [...]

[Read more →]

Tags: ·

MySQL error 1449 “There is no ‘username’@'host’ registered”

June 27th, 2008 · 1 Comment · MySQL

The error message in the title occurs in a combination of circumstances. If you have 2 MySQL databases, one master and one slave in a replicating setup and you use triggers you may encounter this error. Although it is not necessary for the slave database to have the same users as the master for replication [...]

[Read more →]

Tags: ··