I encountered a situation at work that I feel would be a good brain teaser. I was working on a project and needed a way to swap values from 2 different rows in a SQL table. Obviously I can do it on client side (like PHP) to do it; but that wouldn’t be a good […]
Ronald Bradford wants to know what kind of
Monitoring you use..
He specifically wants to know about Alerting tools
There's different cases , looking at it from a full infrastructure point my current favourite is Zabbix or good old Nagios,
But when looking at it from a debugging perspective you have MySQLAR or Hyperic, but those aren't in the alerting list.
However, when you are building HA clusters, you have custom scripts running either from mon or from pacemaker ..
Still .. Ronald probably wants more input :)
Technorati Tags: ha monitoring msql …
[Read more]How To Set Up Apache2 With mod_fcgid And PHP5 On Fedora 11
This tutorial describes how you can install Apache2 with mod_fcgid and PHP5 on Fedora 11. mod_fcgid is a compatible alternative to the older mod_fastcgi. It lets you execute PHP scripts with the permissions of their owners instead of the Apache user.
I recently relocated to Khon Kaen, Thailand for 3 months. Since I can do my Open Query work from anywhere (as long as there is a decent internet connection with not too much latency) that is entirely no problem. It is a nice city, far from the business/busyness of Bangkok. Almost noone speaks english here, which makes even the simplest task an adventure (imagine miming an umbrella in front of 10 giggling store employees)
Now that I have gotten settled in Khon Kaen, I am looking for fun work-related things to do around here: conferences, user groups, interesting projects etc. Anything goes really, even if it is not so much work-related. I also have free time on my hands
I am quite likely going to do a tutorial on MMM at FOSS.my in Kuala Lumpur. It’s still waiting on a few things since I announced my availability super-late, but I have good hope. I am turning to our readers to ask for …
[Read more]You finished the development phase of your Web project, and you are now heading to production. This means that your web-site will be soon on-line, visible on the Internet, and may become a potential target for attacks.
During development, you have been using MySQL on your laptop, and
since you are the only one accessing your laptop you used the
default configuration as-is. You are perfectly right in doing
that, in fact MySQL is pretty secure by default, but here are a
set of post-installation best practices to bring MySQL security
to the next level.
1) Set a password for the root account. Note that by "root
account" I don't mean the super-user of the operating system, but
the super-user of MySQL itself:
$ mysql -u root mysql
mysql> SET PASSWORD FOR
root@localhost=PASSWORD('new_password');
2) If they exist, remove the MySQL anonymous account - or assign a password to it - and …
[Read more]
This post describes how MySQL Cluster executes queries. First of
all, Cluster is a storage engine. It doesn't actually execute
queries because it doesn't speak SQL. That is why you use a MySQL
server, which parses your queries and sends low-level storage
engine API calls to the Cluster data nodes. The data nodes know
how to retrieve or store data. Or you can talk to the data nodes
directly using the NDB API(s).
MySQL Cluster has various means of executing queries. They boil
down to:
- Primary key lookup
- Unique key lookup
- Ordered index scan (i.e., non-unique indexes that use T-trees)
- Full table scan
Let's say you have 4 data nodes in your cluster (NoOfReplicas=2).
This means you have 2 node groups and each one has half the data.
Cluster uses a hash on the primary key (unless you've controlled
the partitioning using the 5.1 partitioning features). So for …
As my first contribution to the MySQL Performance Blog, I joined Percona at the beginning September, I chose to cover the various high-availability (HA) options available for MySQL. I have done dozen of MySQL HA related engagements while working for Sun/MySQL over the last couple of years using Heartbeat, DRBD and NDB cluster and I'll probably be doing the same at Percona. I have built my first DRBD based HA solution nearly 10 years ago.
There is quite a lot of confusion surrounding HA solutions for MySQL, I will try to present them objectively, my goal here been not to sell any specific technology but to help people choose the right one for their needs. This post is first of a series, I don't yet know how many I will write in the series.
Before we start, it must be stated that high-availability is not only a matter of technical solutions, good management practices covering monitoring, alerting, security and …
[Read more]Since I started doing the occasional consulting job for Open Query, I've seen a lot of MySQL servers that have been installed once and then forgotten about. This gave me the idea to do a short presentation about some basic MySQL server configuration. The first go was at DrupalCampMelbourne and I recently tried (and failed) to cram it into a three minute lightning talk slot at the LUV September meeting.
The title of the talk is (now) MySQL > YourSQL. I chose this not because I think that MySQL is better than the $other_database you use or because I may or may not run a newer version of MySQL on better hardware, but because I use InnoDB and …
[Read more]Since I started doing the occasional consulting job for Open Query, I've seen a lot of MySQL servers that have been installed once and then forgotten about. This gave me the idea to do a short presentation about some basic MySQL server configuration. The first go was at DrupalCampMelbourne and I recently tried (and failed) to cram it into a three minute lightning talk slot at the LUV September meeting.
The title of the talk is (now) MySQL > YourSQL. I chose this not because I think that MySQL is better than the $other_database you use or because I may or may not run a newer version of MySQL on better hardware, but because I use InnoDB …
[Read more]I like profilers. I use them when trying to make software (such as Drizzle) faster. Many profilers suck – and pretty much all of them are impossible to attach to a running system. Two notable exceptions are oprofile and dtrace (for Linux and Solaris respectively). The downside of oprofile is that it is non trivial to configure and get running and is pretty much all or nothing. Dtrace has the major disadvantage of that it is Solaris specific, so is only available to a minority of our users (and developers).
The new Linux Performance Events interface (perf_event) presents to userspace a nice abstraction of the hardware Performance Monitoring Unit inside the CPU. Typically these are processor specific (i.e. the one in a Core is different than the one in a Core 2) and can only be used by one thing at a time. The perf_events interface lets multiple applications/threads use the PMU (switching state at context switch as needed), even giving us …
[Read more]