Debuggging day. The MySQL 5.0 server I tried to run as part of a MediaWiki installation under FreeBSD, crashed during initialization, and a Tomy Walkabout digital baby monitor started emitting a low beeping sound. I solved both cases through educated guesses.
The most tricky problem was the mySQL server crash.
The server starts up through two layers of shell scripts,
so I first had to untangle those by running them through
After I found how the actual server binary got executed I could
probe it with strace, to see whether it was correctly reading
its configuration files.
(The FreeBSD port installation
I used did not install a configuration file, so I installed
one by hand.
cp work/mysql-5.0.24/support-files/my-medium.cnf /var/db/mysql/my.cnf
--with-debugto config), and run the code under gdb. A stack trace at the point of crash showed me a fairly innocuous line in C++. Given that C++ can sometimes be tricky to compile correctly, I guessed that the problem was a bug in the fairly old (2.95.4) gcc installation on the FreeBSD 4.11 system where MySQL got compiled. I reinstalled the server from a precompiled binary (
pkg_add -r mysql50-server), and everything worked fine.
The baby monitor case was more tricky, mainly because I lacked proper diagnostic tools. An interesting symptom was that the beeping sound stopped once I put entirely fresh batteries in the transmitting unit. After verifying with a multimeter the voltage output of the power brick, I decided to try a bold move. I opened the transmitting unit, and replaced the 100μF electrolytic capacitor that was near the power supply cables with a new one. My hypothesis was that the capacitor was leaky and failed to filter the power supply voltage. Indeed, the unit worked flawlessly after the change. A lucky educated guess.Read and post comments.
Last modified: Saturday, September 2, 2006 11:47 pm
Unless otherwise expressly stated, all original material on this page created by Diomidis Spinellis is licensed under a Creative Commons Attribution-NonCommercial 4.0 International License.