| Showing entries 1 to 20 of 18685 | Next 20 Older Entries |
Normally I like to use the OS’s package manager to manage the software on my system. This ensures that things are done consistently. When managing MySQL I’d also like to manage all my instances the same way. That makes life easier for me but also for my fellow DBAs and sysadmin colleagues.
I use CentOS and the rpm packages it provides and these work quite well. However, the MySQL rpms do not allow me to manage single and multiple instances alike and while mysqld runs as the mysql user the instance management needs to be done as root (stopping, starting instances, or default access). If you want to run multiple instances you can also use
[Read more...]Mark wrote about how to find situations where InnoDB read-ahead is a bottleneck. What he didn’t disclose, though, is his trick to disable read-ahead without restart or recompile of MySQL. See, there’s no internal “disable read ahead knob”. But there is…
buf_read_ahead_random(...){ ...
if (srv_startup_is_before_trx_rollback_phase) {
/* No read-ahead to avoid thread deadlocks */
return(0);
}
This variable is tested at two functions – buf_read_ahead_linear() and buf_read_ahead_linear() and nowhere else. So yeah, “server startup is before transaction rollback phase” is another way of saying “don’t do read ahead, please please”.
gdb -ex "set[Read more...]
MySQL has an unusual grants system that allows a user to be specified by host, ip or network address. That is you identify a user as ’some_user’@'host.host.name’, ’some_user’@'1.2.3.4′ or ’some_user’@'10.3.%’.
That is quite a nice facility but using it is rather tricky. This potentially provides a lot more security as it allows you to specify that different types of database users can only perform certain actions from different types of hosts. So even if you know the user and password you may have trouble getting into a mysqld server. That’s good.
However, this flexibility comes at a price. There are no tools to help you manage this and I have often seen people resorting to using the simplest type of grant, for some_user@’%', or some_user@’10.%’.
I recently wrote a small
[Read more...]It’s New Year’s Eve, a date that should strike terror into the hearts of many, because tomorrow a bunch of their queries are going to fail.
Queries to “find all birthdays in the next week” and similar are always a nightmare to write. If you want to see a bunch of examples, go look at the user-contributed comments on the MySQL date and time function reference. This post is about a slightly saner way to do that. There’s still some nasty math involved, but a) a lot less of it, and b) at least the query will be able to use indexes[1].
So here’s my tip: instead of storing the user’s full birthdate, just store the month and day they were born. Try it. You’ll love it!
[1] Yes, I know Postgres can
[Read more...]Having been a free software user and supporter for many years, I am disheartened by some of the comments made in the MySQL/Oracle debate regarding the GNU Public License (GPL) and other licenses. There is much throwing around of misconceptions and untruths about licenses and their differences. In this blog, I shall take on some of the bigger misconceptions.
While Linux is indeed distributed under the GPL, as is MySQL, Linux has an exception that allows anyone to run any kind of applications (including closed source applications) on top of Linux.
There is nothing in the GPL that forbids running closed source applications on top of GPL-licensed software. The only thing that
[Read more...]The Planet MySQL has been abuzz with opinions for or against the acquisition of Sun (and in particular MySQL) by Oracle, but I do not have a strong opinion to chime in with in support of either groups. The reason is that I do not know anything about antitrust laws, which is the legal basis for the EC blocking or not blocking the deal; and also I do not know what the alternative is to Oracle buying the MySQL part of Sun.
However, that does not mean that I can not join in the speculations about Oracles reasons for wanting MySQL in the first place ;-)
I think it is basically a matter of obtaining control over MySQL.
The horror scenario for Oracle is that MySQL (or Postgress or another Free Software program) does to the proprietary databases what Linux has done to the proprietary Unixes. Which is essentially to kill them,
[Read more...]On the eve of 2010.. and your boss wants to stick to these MacOS X 10.5 machines, too stubborn or chicken to upgrade. Some developers still have their old PowerBook laptops and they need MySQL flying on PowerPC machines. To top it all, one guy said he wanted to have 32 and 64-bit in one bite. *Sigh* .. But there is an easy way out! A universal binary!
This post shows you a way to create MySQL universal binaries using MacOS X 10.6 so you can run them on MacOS X 10.5/10.6 whether it is PowerPC or Intel, or 32bit or 64bit.
However, if you need
[Read more...]Dennis Wolf, former CFO of MySQL, is in the hospital undergoing treatment for neuromyelitis optica (NMO) also known as Devic's Disease. This is a spinal cord inflammation with similarities to Multiple Sclerosis. Dennis is a very special guy to get such a rare disease. He's also a tough son-of-a-gun, so I have no doubt that he will put this behind him with a full recovery just as he did 18 years ago.
[Read more...]| Showing entries 1 to 20 of 18685 | Next 20 Older Entries |