I have recently moved to HP's Advanced Technology Group which is
a new group in HP and as part of that I will be blogging a lot
more about the Open Source things I and others in HP work on day
to day. I thought I would kick this off by talking about
work that a colleague of mine, Patrick Crews, worked on several months
ago.
For those who don't know Patrick, he is a great Devops Engineer
and QA. He will find new automated ways of breaking things
that will torture applications (and the Engineers who write
them). I don't know if I am proud or ashamed to say he has found
many bugs in code that I have written by doing the software
equivalent of beating it with a sledgehammer.
Every Devops Engineer worth his salt knows that backups are
important, but one thing that is regularly forgotten about is to
check whether the backups are good. A colleague of mine …
Another obscure issue I ran into not long ago was when using MySQL Workbench, and clicking on a table, it became stuck in fetching mode.
What triggered the issue was a recent MySQL upgrade, but MySQL itself, not Workbench.
After checking the error log, we saw an error like:
Incorrect definition of table mysql.proc: expected column 'comment' at position 15 to have type text, found type char(64)
Instantly, I knew mysql_upgrade needed to be ran in order to fix the “Incorrect definition” issue, and turns out that is the root cause for Workbench getting stuck in the “fetching” mode.
So the solution is to run mysql_upgrade. Should that not fix the table for some reason, then you can also fix it alternatively with:
ALTER TABLE mysql.proc MODIFY `comment` text CHARACTER SET utf8 COLLATE utf8_bin NOT NULL; FLUSH TABLES;
Hope this helps.
Since MySQL Workbench 6.0 isn’t available for Fedora, Version 20,
I’m having my students install it on their local Windows and Mac
OS X operating systems. You can configure the
/etc/sysconfig/iptables
file to enable port 3306
after installing MySQL on Fedora.
You can open a port by adding the following line to the
/etc/sysconfig/iptables
file (Fedora’s instructions
on editing iptables
). The file won’t
exist initially, but you can create it by running the following
command as the root
superuser or sudoer:
shell> service iptables save |
You you can run the following commands as the root
superuser, …
When looking back at 2013, one of the things that really stand out is what we’ve done with MySQL in Linux distros. At least it stands out to me, but for most people it’s probably the janitorial work that they never notice as long as everything keeps working perfectly. Although invisible to most, this is the important work that makes it possible for all Linux users to run MySQL.
Most distros are maintained by volunteers doing packaging work in their spare time, and we as software developers should be very grateful for all the work and effort they put into distributing our software (for free!). I know we at Oracle are!
We’ve had a distro-like project of our own in 2013. We have created our own repositories for various Linux distros (I hope to see more in the future), so that users that want the latest and greatest can get that even if their …
[Read more]I ran into a rather obscure bug the other day, but while uncommon, it can cause damage you would not otherwise expect if you use file-level symbolic links. So this is just a warning about that.
Specifically, if you create a table with the .MYI and .MYD files in a different directory, using symbolic links – either manually or using CREATE TABLE .. INDEX DIRECTORY=”" DATA DIRECTORY=”", and then run myisamchk on the table and specify .MYI, you will corrupt the table.
Creating these manually is not so common, but the CREATE TABLE .. INDEX DIRECTORY=”" DATA DIRECTORY=”" is much more common, which creates file-level symbolic links (for the .MYI and .MYD files, respectively) in the datadir and stores the actual file(s) in the location specified. So it leaves you with this setup.
Therefore, if you later run myisamchk on one of these files, do not specify .MYI in the command invocation. If you invoke myisamchk –help, …
[Read more]
Dear Perl and MySQL community,
I’m pleased to announce the release of DBD::mysql 4.026
In this release:
2014-01-15 Patrick Galbraith, Michiel Beijen, DBI/DBD community
(4.026)
* t/29warnings.t fails on MySQL Server 5.1.something - Reported
by RT91202, Gisle Aas. Now is handled depending on version.
* README.pod misses proper NAME heading - RT90101 - Damyan
Ivanov, Debian Perl Group
* Added fix and test for RT91715 (ability to obtain
$dbh->{mysql_use_result} value)
* Added feature from Jacob Gelbman (cPanel)
mysql_skip_secure_auth
Thanks to everyone who contributed!
For more information: http://search.cpan.org/~capttofu/DBD-mysql-4.026
There is a good article over at Re-Code by ex-Microsoft VP Steven Sinofsky called "The Four Stages of Disruption". It describes the evolution of products and markets through disruption, drawing from Sinofsky's own insights and also building on the work of Everett Rogers ("The Diffusion of Innovations") and Clayton Christensen ("The …
[Read more]There is much more to write about all the work we do at Facebook with memory management efficiency on our systems, but there was this one detour investigation in the middle of 2012 that I had to revisit recently courtesy of Wikipedia.
There are lots of factors that make machines page out memory segments into disk, thus slowing everything down and locking software up – from file system cache pressure to runaway memory leaks to kernel drivers being greedy. But certain swap-out scenarios are confusing – systems seem to have lots of memory available, with proper settings file system cache should not cause swapping, and obviously in production environment all the memory leaks are ironed out.
And yet in mid-2012 we noticed that our new kernel machines were swapping out for no obvious reason. When it comes to swapping, MySQL community will always point to Jeremy’s post on …
[Read more]This is a followup to Jay Janssen’s October post, “Using keepalived for HA on top of Percona XtraDB Cluster.” We got a request recently where the customer has 2 VIPs (Virtual IP addresses), one for reader and one for a writer for a cluster of 3 nodes. They wanted to keep it simple, with low latency and does not require an external node resource like HaProxy would.
keepalived is a simple load balancer with HA capabilities, which means it can proxy TCP services behind it and at the same time, keep itself highly available using VRRP as failover mechanism. This post is about taking advantage of the …
[Read more]Many installations of MySQL server come with a built-in database called test. It's initially empty, and you might wonder what it's for, or even if you can delete it without any problems.
What is it for?
The test database is installed by the MySQL Server RPM as part of the mysql_install_db process, and some other package managers run that script too. If you run that script as part of a manual install of MySQL, you'll get the same effect. It creates the database by creating an empty directory called "test" in the data directory, and creates wide-open access to the database test and any database with a name beginning with test_ by inserting a couple of rows into the mysql.db table that give everyone full access to create or use those databases.
The configuration is designed to make it easy for new users to create a playground or sandbox database to work with, one that doesn't require asking the DBA …
[Read more]