Lots of fun today, dealing with what feels like the innards of MySQL but probably just barely scratches the epidermis. What I did learn today though was how to set MySQL system variables using a configuration file on Mac OSX. I figure that this will come up again and I’ll have to learn it all over again unless I write it down, thus, I’m writing it down while a 22 minute query runs on the other machine.
Today, I needed to increase the innodb_buffer_pool_size value from the default 8MB to something useful for my purposes like 2 GB. You can’t do that from SqlYog or from the command line as it happens to be a readonly variable. So you need to create a configuration file. That file lives in root directory at /etc/my.cnf. I first tried to create this file using vi, got it all typed up and then when I saved it, was told that wasn’t going to fly, you don’t have the requisite permissions. Stupid *nix operating system. Not that I’m complaining but after the day I’ve had, I would have liked to have just created the file.
So back to the command prompt and try sudo vi my.cnf. Lo and behold that works like a champ. The file looked like this when I was done:
Saved that, restarted the MySQL server and it had updated correctly as seen using SHOW VARIABLES;
Probably all very elementary stuff but for a guy who prefers not to get his hands dirty with database stuff, good to know for the future. Also learned about profiling which you can enable in a script in SqlYog with a SET profiling=1; at the beginning of your script and a SHOW profiles; at the end.
The backstory: In March of last year, the City of Dallas passed an ordinance allowing cabs that are powered by natural gas to jump the line at Love Field. The city council voted unanimously for this change, a change that clearly positions the government in a place to make market decisions.
Current: Independent cab drivers are currently striking during the Super Bowl because they see the ordinance as discriminatory and unfair. Independent cab drivers are more likely to be negatively affected by decisions such as these because they do not have the capital or ability to buy a new car that conforms with the requirements of the ordinance. Cab drivers are encountering days where they might not ever get to pick up a passenger at Love Field because large cab companies vehicles that are powered by natural gas are jumping the line so frequently. Large cab companies do have the resources to change their cars and therefore are largely benefited by a decision like this.
One would think that in a conservative state like Texas, our local government might be more friendly to small and independent business owners but the creep of government oversight continues to strengthen even here in ways that are almost unfathomable. The net effects on the environment from an ordinance such as this are almost certainly minuscule. I don’t see any reason for an ordinance like this other than the benefits the politicians involved might receive from both large cab companies and natural gas producers. Oddly, this isn’t even illegal as a federal judge upheld the ordinance in September after the independent cab owners challenged it.
It’s sickening that in the economic environment we find ourselves in, our local government is doing things that specifically and directly have a negative effect on our small business owners. It’s shocking to me that this wouldn’t have more impact on the polls but then, when I didn’t even see it for 11 months, it probably isn’t getting much coverage. Eventually, the complexity of our government will cause it to collapse in on itself. We cannot continue to operate in a way that is beneficial for the monied interests in our society. Small decisions like these at the local level are just symptoms of a larger and more insidious cancer that affects our ability to govern ourselves.
There’s a link to the story that started all this here. However, now that the DMN has moved most of its content behind the subscriber wall, it’s not particularly useful.