What should I install?

I was asked a simple question today by a collegue who is an experiened Java Developer and Oracle user and had just installed SUSE on his personal laptop, to align closer with his work environment. What MySQL should I install, the MySQL web site has this and this and this?

Simple question, but the answer isn’t as simple, especially when MySQL now has a number of different products encompassing client functionality in addition to the MySQL server.

Oracle got it right with the latest edition Oracle 10g Express Edition (XE). A simple one rpm install that includes the Oracle Server, Oracle client, a Web Based Administrator, Query Tool and Application Development tool. I guess as we are all experienced, the simple question isn’t something we have a some notes on handy, hence the purpose of my entry A Basic MySQL Developer Installation. NOTE: This is for a developer environment, installation would be simplier using RPM’s for a compatible Distro.

On that note, It would be good for MySQL to provide a more complete installation of it’s suite of products rather then letting 3rd parties package it all together. Problem is there are so many possible combinations, what do you do.

Data Modelling

I’m a data modeller. I specialise in this, and for a number of years on large projects I’ve been able to focus on this single task within the System Development Life Cycle of software development for several months at a time. Unfortunately what depresses me the most, is I can’t get a full time position in what I’m an expert in. It’s not a specialised skill that an organisation can use on a full-time basis, unless it’s a large organisation, and quite frankly, Brisbane isn’t a market that can support the diversity of large organisations. (caveat, large organisations that are proactive in software development, not just large organisations that have significant IT requirements, but do not work proactively). This is why I can also do Software Development, Database Administration, and even System Administration. Again, I’m not good enough to fill one of these positions in a larger organisation as an expert, but I can generally hold my own, usually even with surpising results. (Side note, even this week, I was providing a possible solution and tool for system adminstration across a large organisation, and it was 5 mins work. Something the paid full-time system administrators were not providing????)

I only started looking at Domas Mituzas wordpress: friendly look at query log. I didn’t have to read far to see where it was going, and well I quite quickly turned off, sorry Domas, I’m sure your concluding points were valid. This is my point, and it has been echoed in our local MySQL users group as well, the lack of appropiate database design in open source projects. There are several contributors, but one I put down to the “Hobbist and the Professional Syndrome”. A topic for further discussion, but in summary here are the bullet points from a slide in a presentation I prepared.

Hobbist

  • Downloadable software and examples
  • Online tutorials
  • Books like Learn in 24 hours/For Dummies

Professional

  • Formal Qualifications
  • Grounding in sound programming practices
  • Understanding of SDLC principles
  • Worked in team environment

Middle Ground Developer

  • Time to skill verses output productivity
  • Depends on environment and requirements

And on a final note, I guess why doing some raving. I find it criminal that organisations encourage at times a level of incompetence by promoting people that develop bad code into positions where they can continue to ensure that bad code stays, and further business decisions only engrain an organisation down the continued wrong path. There is already enough poor software developers out there that give the industry a bad name, but the good ones are few and far between.

What do we do, how can we solve this problem? I don’t think it can be solved now in the Open Source community. Adopting an Agile Development methodology such as Extreme Programming (XP) for example, it a very good start in organisations, something I’ve been working with now, or working with the principles for 6 years.

PS: Modelling is actually spelt both Modeling and Modelling (2 l’s) across the various English derivitives. Just incase somebody wanted to make comment.

Format new Linux Disk

fdisk /dev/hdb
mkfs.ext3 /dev/hdb1
mkdir /u03
mount -t ext3 /dev/hdb1 /u03
ls /u03
umount /u03
vi /etc/fstab
mount /u03

Contributing to JMeter

As part of my using JMeter for the purpose of testing a new Transactional storage engine PBXT for MySQL, I’ve been investigating the best approach for handling transactions. Read more about earlier decisions at my earlier post Testing a new MySQL Transactional Storage Engine.

I found that the JMeter JDBC Sampler only supports SELECT and UPDATE Statements, and not calls to stored procedures. This is just one approach I’m considering taking.

Well, I guess it’s time to contribute code to an Apache Project. I’ve modified code and logged bugs before for Tomcat, but this will be my first attempt of modify code and submit.

A summary of what I did (really for my own short term memory):

Now I just have to wait to see if it’s accepted. Regardless, it works for me. And that’s Open Source. FREEDOM

svn checkout http://svn.apache.org/repos/asf/jakarta/jmeter/trunk/ jmeter

$ svn diff JDBCSampler.java > JDBCSampler.java.patch
$ cat  JDBCSampler.java.patch
Index: JDBCSampler.java
===================================================================
--- JDBCSampler.java    (revision 388876)
+++ JDBCSampler.java    (working copy)
@@ -23,6 +23,7 @@
 import java.sql.ResultSetMetaData;
 import java.sql.SQLException;
 import java.sql.Statement;
+import java.sql.CallableStatement;

 import org.apache.avalon.excalibur.datasource.DataSourceComponent;
 import org.apache.jmeter.samplers.Entry;
@@ -45,6 +46,8 @@

        public static final String QUERY = "query";
        public static final String SELECT = "Select Statement";
+       public static final String UPDATE = "Update Statement";
+       public static final String STATEMENT = "Call Statement";

        public String query = "";

@@ -69,6 +72,7 @@
                log.debug("DataSourceComponent: " + pool);
                Connection conn = null;
                Statement stmt = null;
+               CallableStatement cs = null;

                try {

@@ -88,14 +92,19 @@
                                        Data data = getDataFromResultSet(rs);
                                        res.setResponseData(data.toString().getBytes());
                                } finally {
-                                       if (rs != null) {
-                                               try {
-                                                       rs.close();
-                                               } catch (SQLException exc) {
-                                                       log.warn("Error closing ResultSet", exc);
-                                               }
-                                       }
+                                       close(rs);
                                }
+                       // execute stored procedure
+                       } else if (STATEMENT.equals(getQueryType())) {
+                               try {
+                                       cs = conn.prepareCall(getQuery());
+                                       cs.execute();
+                                       String results = "Executed";
+                                       res.setResponseData(results.getBytes());
+                               } finally {
+                                       close(cs);
+                               }
+                       // Insert/Update/Delete statement
                        } else {
                                stmt.execute(getQuery());
                                int updateCount = stmt.getUpdateCount();
@@ -112,20 +121,8 @@
                        res.setResponseMessage(ex.toString());
                        res.setSuccessful(false);
                } finally {
-                       if (stmt != null) {
-                               try {
-                                       stmt.close();
-                               } catch (SQLException ex) {
-                                       log.warn("Error closing statement", ex);
-                               }
-                       }
-                       if (conn != null) {
-                               try {
-                                       conn.close();
-                               } catch (SQLException ex) {
-                                       log.warn("Error closing connection", ex);
-                               }
-                       }
+                       close(stmt);
+                       close(conn);
                }

                res.sampleEnd();
@@ -164,6 +161,38 @@
                return data;
        }

+       public static void close(Connection c) {
+               try {
+                       if (c != null) c.close();
+               } catch (SQLException e) {
+                       log.warn("Error closing Connection", e);
+               }
+       }
+
+       public static void close(Statement s) {
+               try {
+                       if (s != null) s.close();
+               } catch (SQLException e) {
+                       log.warn("Error closing Statement", e);
+               }
+       }
+
+       public static void close(CallableStatement cs) {
+               try {
+                       if (cs != null) cs.close();
+               } catch (SQLException e) {
+                       log.warn("Error closing CallableStatement", e);
+               }
+       }
+
+       public static void close(ResultSet rs) {
+               try {
+                       if (rs != null) rs.close();
+               } catch (SQLException e) {
+                       log.warn("Error closing ResultSet", e);
+               }
+       }
+
        public String getQuery() {
                return query;
        }

$ svn diff JDBCSamplerBeanInfo.java > JDBCSamplerBeanInfo.java.patch
$ cat JDBCSamplerBeanInfo.java.patch
Index: JDBCSamplerBeanInfo.java
===================================================================
--- JDBCSamplerBeanInfo.java    (revision 388876)
+++ JDBCSamplerBeanInfo.java    (working copy)
@@ -50,7 +50,7 @@
                p.setValue(NOT_UNDEFINED, Boolean.TRUE);
                p.setValue(DEFAULT, JDBCSampler.SELECT);
                p.setValue(NOT_OTHER,Boolean.TRUE);
-               p.setValue(TAGS,new String[]{JDBCSampler.SELECT,"Update Statement"});
+               p.setValue(TAGS,new String[]{JDBCSampler.SELECT,JDBCSampler.UPDATE,JDBCSampler.STATEMENT});

                p = property("query");
                p.setValue(NOT_UNDEFINED, Boolean.TRUE);

Update

Good to know somebody read my post, and responded positively. The quickest way for patches is to log a Bugzilla request. Seemed somebody already had, so it was easy for me to just to contribute to Bug #38682

Withdrawl symptoms

I’ve recently started a new contract position, and the combination of more restrictive working hours, and at least 1 hour travel each way each day, has lead to me not being about to write like I have of late.

I seem to have far more draft blogs at moment, many things I want to write, and I have to temper this with a number of extra projects but I guess that’s life.

Emulating Oracle Output Functionality

Updated 28-mar-2006
There really is no way to do a comparision by numbers in features and functionality when it comes to Oracle and MySQL in the area of Stored Procedures and Triggers. Oracle does provide a far greater and extensive features list, however having more only means it has more.

We all know this, MySQL is a growing evolving database product, having just celebrated it’s tenth anniversary, Oracle on the other hand, will next year be 30, and has had significant funding in R&D being up until recently the second largest software company world wide. However, being open source, MySQL has the advantages of being lean and mean, providing only functionality users actually want and use, and has the community and organisation that is focussed clearly on providing new and improved functionality that users need.

I’ll have a lot more to speak about on this topic at my MySQL User Conference presentation MySQL for Oracle Developers next month, however in the preceeding weeks I thought I’d open some discussion and debate on various features, particularly in the area of Stored Procedures.

Here are some initial points, I’d like to talk about today. The purpose of this discussion is to highlight the difference between these two products, and possibilly other RDBMS products. While a RDBMS offers a feature, I am not stating that MySQL should necessarily also have this feature, however as part of comparing products in these articles, I am comparing existing Oracle Functionality to MySQL, so it will generally involve the description of functionality that is not presently comparable.

  1. Package Space
  2. Provider Supplied Procedures

1. Package Space

MySQL provides for Stored Procedures and Functions only the definition of individual procedures and functions. There is no way to group them into logical groupings.

Oracle provides the functionality of Package Space. Groups of procedures and functions can be defined within a package. Consider it like a wrapper of a group of procedures and functions. The package definition consists of 2 parts, the header section, which defines the scope of the procedures and functions, and the body which defines the actual procedures and functions. An added advantage of this that within Oracle you can protect your package body code (making it unavailable for view). I’ll discuss this more at a later time.

I’d like to see MySQL consider a package syntax particularly as businesses start to work more extensively with stored procedures and functions in larger enterprise applications. UPDATE: As stated by Roland in the comments, you can register your support for this functionality at MySQL under Bug #11696.

Within MySQL you can emulate package name, at least in syntax. You can use a dot ‘.’ within a procedure name, unlike this restriction for tables. The down side is the call must be quoted. I’ll discuss this more next.

2. Provider Supplied Procedures

Oracle provides an extensive list of supplied procedures and functions, defined in many packages. One of the earliest you learn in Oracle development is DBMS_OUTPUT.PUT_LINE. As the name indicates, this allows your to output a line of information. This is a common means of debugging output. Andrew Gilfrin post on Debugging Stored Procedures in MySQL raises this point, and an interesting solution using a debugging table. While this functionality works, one of my goals is to provide compability functions so that any migration of code could be simplified. Here is a much simplier solution.

$ more dbms_output.put_line.mysql
DELIMITER //
DROP PROCEDURE `dbms_output.put_line`
//
CREATE PROCEDURE `dbms_output.put_line` (output  VARCHAR(255))
BEGIN
  SELECT output;
END;
//
DELIMITER ;

A MySQL Usage:

mysql> CALL `dbms_output.put_line` ('hello world');

A comparision Oracle Usage:

SQL> SET SERVER OUTPUT ON
SQL> BEGIN
SQL> DBMS_OUTPUT.PUT_LINE ('hello world');
SQL> END;

This is as close the syntax can be. With MySQL you require the CALL and the backqoutes (`). Both things that can be easily added in an automated way.

References:
DBMS_OUTPUT Note: this is a public web version of the Version 8i manual online. Oracle provides online documentation, but you require a login (which is free) to the Oracle Technology Network.

Oracle8i Supplied Packages Reference. Again this is dated information, being an older version, but gives you an indication. For reference Oracle 7 released in 1993 first provided Package/Procedure/Function functionality.

Other

On a side note, I’d really like to see a IF EXISTS syntax for DROP PROCEDURE. IF EXISTS is an excellent MySQL extension. Oracle for stored procedures has the CREATE OR REPLACE syntax.

Just how many articles are at Planet MySQL?

I was trying to find an old article at Planet MySQL. One about a MySQL UDF to write to /var/log/messages. No luck.

Anyway, there is no search option on the site, and the latest addition of 10 entries per page makes it difficult to review pages. The RSS feed doesn’t give me a full option.

Anyway, it led me to look back in time to just how many articles are listed on Planet MySQL, and read some old stuff. I only came across it after I stumbled across the Brisbane MySQL Users Group back in Sep 2005.

Anyway the count was 2146. I’d like to see a stat on the home page of how many articles, and perhaps how many, last day, last week, last month.

MySQL Forge

I was reading Zack Urlocker’s MySQL Workbench Beta article and was keen to look at the Extensible architecture. Not much detail yet in the Figure Stylesheets, Scripts and Plugins, which will be good when it’s there, however it lead me to another secret.

The MySQL Forge. This was mentioned at the Brisbane MySQL Users Group Meeting with Brian Aker in January. There isn’t much content at present, but there is a Call for Content.

I don’t recall anybody blogging about it, or maybe I just missed it. Giuseppe Maxia should get his MySQL General Purpose Stored Routines Library up there. On that thought, I’ve been looking for a post several months ago, about a UDF that wrote to the system log /var/log/messages. Does anybody remember this?

Another dissappointing MySQL article

Another slightly disappointing article regarding MySQL, this one from a printed magazine. Below are my comments to the editor of Linux Format. The Dear Editor is an email link should others wish to make any comments. (Previous article comments What makes your blood boil?, Review of Database Magazine Article – “The Usual Suspects”)

Dear Editor,

I’ve recently subscribed to LXF, and have generally been very happy with the content in past months. I’m disappointed in your recent LXF77 article “Harness a database” Pg 57. Being a strong MySQL supporter, your article includes a number of practices which are less then ideal, and especially for the newly initiated, overly complicated when simplier alternatives exist.

I am happy to see that you had the current version 5.0.18. However in 7 years of using MySQL I’ve never had to compile from source, a binary has always been available, yet in your article you take the compile from source approach. While you may have done this to appease all possible readers of all POSIX variants, the binary for at least Linux could have been included.

In addition, much like your earlier article for Samba where you make reference to “most distros include this”, indeed MySQL is also included in most popular Linux distros.

You could have also made reference to the MySQL downloads area website. Infact, the MySQL 5.0 download area provides some 70+ dedicated distro versions for optimal usage. The site also states “For maximum stability and performance, we recommend that you use the binaries we provide.”

The second point that I do believe is completely unnecessary, and not recommended by MySQL, is the manual creation of user security. MySQL provides the CREATE USER command to achieve this. In your article, you would execute CREATE USER lxf@localhost IDENTIFIED BY ‘orangutan'; rather then an INSERT INTO user and a FLUSH PRIVILEGES.

Throughout your article you make no reference to the MySQL website, perhaps this is a policy, however it’s always ideal to have online references. At worst, a link to say www.linuxformat.co.uk/products/mysql (or appropiate) that provides links to the product information, in this case MySQL. This will allow you to undertake your necessary advertising, as well as track traffic.

I’m also sure, that contacting the MySQL Community Relations Manager for review of any MySQL content in future would be openly accepted, I’m even happy to review MySQL content in your magazine.

Atomicity, Consistency, Isolation, and Durability = ACID

ACID is the key transaction processing feature for a RDBMS. Without this, the integrity of the database cannot be guaranteed.

In Summary.

Atomicity is an all-or-none proposition.
Consistency guarantees that a transaction never leaves your database in a half-finished state.
Isolation keeps transactions separated from each other until they’re finished.
Durability guarantees that the database will keep track of pending changes in such a way that the server can recover from an abnormal termination.

A clearer definition from the Wikipedia.

  • Atomicity refers to the ability of the DBMS to guarantee that either all of the tasks of a transaction are performed or none of them are. The transfer of funds can be completed or it can fail for a multitude of reasons, but atomicity guarantees that one account won’t be debited if the other is not credited as well.
  • Consistency refers to the database being in a legal state when the transaction begins and when it ends. This means that a transaction can’t break the rules, or integrity constraints, of the database. If an integrity constraint states that all accounts must have a positive balance, then any transaction violating this rule will be aborted.
  • Isolation refers to the ability of the application to make operations in a transaction appear isolated from all other operations. This means that no operation outside the transaction can ever see the data in an intermediate state; a bank manager can see the transferred funds on one account or the other, but never on both—even if she ran her query while the transfer was still being processed. More formally, isolation means the transaction history (or schedule) is serializable. For performance reasons, this ability is the most often relaxed constraint.
  • Durability refers to the guarantee that once the user has been notified of success, the transaction will persist, and not be undone. This means it will survive system failure, and that the database system has checked the integrity constraints and won’t need to abort the transaction. Typically, all transactions are written into a log that can be played back to recreate the system to its state right before the failure. A transaction can only be deemed committed after it is safely in the log.

Googlewack

This fad started many years ago, and once I achieved it. Well today, I got the google 1 of 1 result. Here are the rules

GoogleWack “Your goal: find that elusive query (two words – no quote marks) with a single, solitary result!”

And my two words were:

ensureClassInitialized xmlbeans

Of course the problem is, by the time you read this, it may no longer be a 1 of 1 result, as my Blog may get referenced. So, I’ve attached a screen print for proof. (yes, it’s an undoctored screen print)

dbus messaging error under CentOS 4.2

The Problem
I’ve been getting the following /var/log/messages errors:


Mar 13 21:38:42 lamda dbus: Can't send to audit system: USER_AVC pid=3606 uid=81 loginuid=-1 message=avc: denied { send_msg } for scontext=user_u:system_r:unconfined_t tcontext=user_u:system_r:initrc_t tclass=dbus
Mar 13 21:39:17 lamda last message repeated 7 times

Based on the command dbus-launch – Utility to start a message bus from a shell script. Investigation found the process running under my userid, not root?


rbradfor 5760 1 0 Mar11 tty1 00:00:00 /usr/bin/dbus-launch --exit-with-session /etc/X11/xinit/Xclients
rbradfor 5761 1 0 Mar11 ? 00:00:00 dbus-daemon-1 --fork --print-pid 8 --print-address 6 --session

The service can be stopped which addresses the immediate problem.

/etc/init.d/messagebus stop

The Fix

$ wget ftp://people.redhat.com/dwalsh/SELinux/RHEL4/u3/noarch/selinux-policy-targeted-1.17.30-2.126.noarch.rpm
$ wget ftp://people.redhat.com/dwalsh/SELinux/RHEL4/u3/i386/policycoreutils-1.18.1-4.9.i386.rpm
$ rpm -Uvh policycoreutils-1.18.1-4.9.i386.rpm selinux-policy-targeted-1.17.30-2.126.noarch.rpm

Reference
CentOS 4 Forum Reference

Beating those annoying telephone menus

Everybody hates having to listen to automated telephone systems, with long menu options, and you just want to speak to a human, even to be redirected to another human. I can’t count the number of times I’ve been in the menu system for 30 mins. I’ve even been lost in the menu system with Telstra, finally hung up in discust, redialed and been almost immediately serviced.

So Apparently if you ring a Telstra number and receive voice prompting do the following to get to an operator quicker:

1. Say a word ie “mobile” or “phone”
2. Press the hash (#) key
3. Wait for the recorded message
4. Press the hash key again

Apparently this will put you at the top of the queue for the next available operator.

We just tested this with the 13 2200 number and it seems to work. After step 4, we were sent to a human operator within 15 seconds. Nice.

Well Emptorium Australian Banking Cheat Sheet will get back at big business with a number of cheats.

Bank Phone Shortcut
AussieHomeloans 13 13 33 0000
American Express 1300 132 639 0#
ANZ Bank 13 13 14 00000
BankWest 131 718 00000#
Bendigo Bank 1300 366 666 0
Citibank 13 24 84 00
Commonwealth Bank 13 22 21 000
Diners Club 1300 360 060 0
Esanda 13 23 13 00
HSBC 1300 308 880 1
ING Bank 1800 639 082 0 wait 0#
ING Direct 1800 500 240 0
National Australia Bank 13 13 12 ###
RAMS Home Loans 13 72 67 000
Suncorp 13 11 34 0000
St. George Bank 13 33 30 say ‘Everyday Banking’
Wizard Home Loans 131 970 0
Westpac Banking Corporation (Mortgage Sales) 13 19 00 0
Westpac Banking Corporation (Phone Banking) 13 20 32 00*0
Woolworths Ezy Banking 13 72 88 0

Testing a new MySQL Transactional Storage Engine

As part of my A call to arms! post about a month ago, I’ve had a number of unofficial comments of support. In addition, I’ve also been approached to assist in the completion of a MySQL Transactional support engine. More information on the PBXT engine will be forthcoming soon by it’s creator.

Anyway, I’ve taken on the responsiblity of assisting in testing this new storage engine. This will also give me the excuse of being able to pursue some other ideas about the performance of differing storage engines for differing tables in business circumstances, such as MyIsam verses InnoDB in a highly OLTP environment. Part of testing will be ensure ACID conformance in varying situations and multi-concurrency use. Of course the ability to also do performance and load testing would be a obvious extension.

Considering how I’m going to benchmark is an interesting approach. I of course want to use Java, my choice of language at present. This presents a problem, in another factor towards performance, however by using Java, I’m simulating a more real world environment of a programming overhead and JDBC Connector rather then just raw performance output.

Laying out a plan would include an ability to have an existing database structure and data, be able to bulk define SQL statements and transactions, and parameterise SQL during transactions. I would need to be able to verify the state of database from the transactions, and clearly identify any invalid data. I would also need the ability for handling threads, and of course adequate reporting of my results.

As of MySQL 5.1.4, there is a supported benchmarking tool called mysqlslap in MySQL. I’ve discounted using this because I figured at this early stage, the documentation and exposure of this is of course limiting, and I’m sure I’d still need to perform other development.

Along comes JMeter. Within Java development I use JUnit quite extensively. This is key in the test-driven agile methodology approach of Extreme Programming. In discussion with this problem with a collegue on a new project, I found that JMeter was used for extensive load testing for web applications, but also performed database testing, and provides the support to integrate JUnit tests.

So yesterday I had a quick look at JMeter. The capabilities for defining, reporting and threading are quite complete. It took litterally minutes to install, configure, run an initial test and view results all in a GUI interface. A little more work gave me scripting handling of my initial tests. I’ve posted my initial investigations of JMeter – Performance Testing Software and JMeter and Ant Integration earlier.

With this behind me, I’ve just got to define the approach for more complete transactional tests, explictly confirming the results (I’m hoping to achieve this in custom JUnit tests). If I can solve this, then I can spend the most of time in the defining of adequate tests. Let’s see what the next few days work provides.

JMeter and Ant Integration

Using Ant withJMeter you can achieve remote running and web based reporting.

I got the ant-jmeter.jar and sample results output .xls from Embedding JMeter with Ant. JMeter Ant Task


cd /tmp
wget http://www.programmerplanet.org/ant-jmeter/ant-jmeter.jar
wget http://www.programmerplanet.org/ant-jmeter/jmeter-results-report.xsl
mv ant-meter.jar $ANT_HOME/lib

Within a new project directory, place your saved JMeter Tests (*.jmx) in a loadtests subdirectory, and the downloaded jmeter-results-report.xsl in the project directory.

build.xml

<project name="dbtest" default="dist" basedir=".">

<property name="base.dir" value="."/>
<property name="report.dir" value="report"/>

<taskdef name="jmeter"
        classname="org.programmerplanet.ant.taskdefs.jmeter.JMeterTask"/>
<target name="dist" depends="runtest,testresults" />

<target name="runtest" description="Run jmeter tests">
        <jmeter jmeterhome="/opt/jmeter"
                resultlog="${base.dir}/loadtests/JMeterResults.jtl">
                <testplans dir="${base.dir}/loadtests" includes="*.jmx"/>
        </jmeter>
</target>

<target name="testresults" description="Report Test Results" depends="runtest">
        <delete dir="${report.dir}" quiet="true"/>
        <mkdir dir="${report.dir}" />
        <xslt in="${base.dir}/loadtests/JMeterResults.jtl"
                out="${report.dir}/JMeterResults.html"
                style="${base.dir}/jmeter-results-report.xsl"/>
</target>
</project>

Report output from running ant can be found at report/JMeterResults.html

JMeter – Performance Testing Software

Apache JMeter is a 100% pure Java desktop application designed to load test functional behavior and measure performance. It was originally designed for testing Web Applications but has since expanded to other test functions. Specifically it provides complete support for database testing via JDBC.

Some References: Homepage http://jakarta.apache.org/jmeter/  ·  Wiki Page  ·  User Manual

Initial Installation Steps

$ su -
$ cd /opt
$ wget http://apache.planetmirror.com.au/dist/jakarta/jmeter/binaries/jakarta-jmeter-2.1.1.tgz
$ wget http://apache.planetmirror.com.au/dist/jakarta/jmeter/source/jakarta-jmeter-2.1.1_src.tgz
$ tar xvfz jakarta-jmeter-2.1.1.tgz
$ tar xvfz jakarta-jmeter-2.1.1_src.tgz
$ ln -s jakarta-jmeter-2.1.1 jmeter
$ echo "PATH=/opt/jmeter/bin:$PATH;export PATH" > /etc/profile.d/jmeter.sh
$ . /etc/profile.d/jmeter.sh
$ jmeter &

Adding MySQL Support

cd /tmp
wget http://dev.mysql.com/get/Downloads/Connector-J/mysql-connector-java-3.1.12.tar.gz/from/http://mysql.planetmirror.com/
tar xvfz mysql-connector-java-3.1.12.tar.gz
cp mysql-connector-java-3.1.12/mysql-connector-java-3.1.12-bin.jar /opt/jakarta-jmeter-2.1.1/lib/

Steps to perform simple MySQL JDBC Test.

1. Launch JMeter
2. Add a new Thread Group (using right click)
3. Define Thread Settings (no messing around 3 threads x 1000 iterations)
4. Add a Sampler JDBC Request
5. Add initial sample SQL query
6. Add a JDBC Connection Configuration
7. Define JDBC Connnection details (I’m using the sakila sample database at this time)
8. Define a Results View
9. Run the sucker

This is just a quick intro to prove it all works, There are quite a lot of reporting output possible, something for my next post.
Click on Image for a larger view.

Using Parrallels as a VM for Windows

$ su –
$ Parallels-config
Configuring Parallels Workstation 2.0 build 1514
Configuring Parallels Workstation 2.0 drivers…
Compiling Parallels Workstation 2.0 drivers…
Drivers have been compiled successfully.
Installing drivers…
Starting drivers…
Load Parallels Workstation 2.0 hypervisor …
Load Parallels Workstation 2.0 vm-main …
Load Parallels Workstation 2.0 vm-bridge …
Load Parallels Workstation 2.0 vmvirtualnic …
Configuration completed successfully
Now you can run Parallels Workstation 2.0
Issue “Parallels” command.
$Parallels

You have an interface now to configure your Virtual Machine settings, including memory and disk very easily.

Some observations.
The install process is more true Windows XP, format drive, reboot, all options etc. With Win4LinPro a lot of this was shielded (which was impressive in itself).

The Parallels VM runs in it’s on window, but you get locked in when you mouse click to focus. Using Ctrl-Alt, your focus is returned to your host environment.

Parallels is clearly a more rounded product, providing many more host environments. The interface provides a lot more virtual feel. You have Disk/CD/Network/Sound icons embedded in the window

In this install sound also worked by default, it did not in Win4LinPro. The playing of audio was actually a good indicator during the Windows activation process (which wasn’t in Win4LinPro) as you could here the delays in extensive CPU processing.

Parallels required you to run as root, while Win4LinPro disallowed root invocation. You were also given the opporunity to configure Windows users, while in Win4LinPro it just masked an administrator behind the scenes.

In defense of Win4Lin Pro, it clearly took away a lot of steps in the normal windows installation which made it clearly easier to install.

For Win4Lin Pro, it would not accepted my laptop Windows XP Pro CD (as it was not SP1 or SP2).
The specs for Parallels stated it would work, however I used anothe Windows XP Pro CD with SP1.
Surprisingly in the activation process, I could not use the Serial Number for my Laptop Windows XP, I had to use the serial Number for my SP1 CD. Not to bother, I own both, and use neither, it was just interesting to see Microsoft reject a valid serial number.

Latest MySQL Versions under VMWare

I made reference previously to Testing/Trialing new MySQL Releases using VMWare.

Well, I’ve just about completed my own Image for the lastest MySQL 5.0 (given I’m now running MySQL 5.1). I’m interested in sharing my experiences, and even providing some images for users if there is any demand out there.

What I’ve decided on is to use the VMWare supplied Browser Appliance which is Ubuntu 5.10. The great thing is the image autoboots into graphical mode, auto logins and loads a browser. My goal now is to get a suitable startup page describing the MySQL environment, links, manual etc.

The only requirements to run would be the Free VMware Player and a latest image.

I’m looking at providing a FTP and RSYNC download. Those savvy people will benefit a lot more from RSYNC when the image is upto 500MB.

I’m interested to know if anybody else would use this with the lastest 5.0, 5.1, 5.2 etc versions. Also, would it be of benefit to include other MySQL products such as Query Browser, Administrator, Workbench.

Check out the Innodb Site?

Have a look at InnoDB. Well, ok your lazy, so here’s a screen print below.
Plastered thoughout the top section is the word MySQL. It’s in the core banner blurb, there’s a logo, and even links to the MySQL Documentation. And right in the middle of all this is “Innobase OY is an Oracle Company”, with the standard Oracle Logo.

So my question would be, is this a good thing or a bad thing from a MySQL advertising perspective?
Does it help or hinder MySQL?
Does it show Oracle as being in partnership with MySQL? Is this good for MySQL to increase it’s exposure into the Oracle world?
Does inclusion of InnoDB now within Oracle traffic and links improve exposure to MySQL within search engines?

Frankly, I’m a little surprised that Oracle Legal hasn’t got onto this, I’m sure somewhere there would be a decree, that no competitor logos should be shown with the official Oracle logo.

I’d suspect that the existing MySQL community know the deal re Oracle, so perhaps this will expose more Oracle specific people to MySQL!

Oracle Comments

Some recent posts regarding Oracle (See Smart moves by MySQL AB and Larry Ellison still doesn’t understand open source) leads me to put in my 2 cents worth.

My background I’m sure like a lot of experienced MySQL people is in Oracle, and indeed in Ingres before that (starting in 1988). I have also worked for a number of years at Oracle Corporation. Ironically I started as their resident Ingres Specialist, in an international research project of DMS (Design & Migration Services) of re-engineering Ingres applications into an Oracle Designer Repository some 10 years ago in 1996. I of course moved into a number of other Oracle roles for clients following that. I still retain some contacts around the place.

It’s obvious Larry’s goal is to become more “Open Source”. This is of course a complex topic, and you can’t just say it like this. I’ll leave that for another day, but I’ve got some opinion on current trends.

It’s clear from recent purchases of JBoss, and SleepCat (Berkley DB) that Oracle has an intention of providing a suitable technology stack in a number of vertical marketspaces that Oracle presently cannot. For example, in the embedded space. Purchasing provides a much quicker solution, and also provides a different way to solve the problem instead of the legacy Oracle Product line. I haven’t seen any recent press, but I know that Xen was also in Oracle’s wallet space.

I would suspect that Oracle will move to providing a Stack solution (akin to SpikeSource for example) in a number of vertical spaces. These stacks will include non-traditional but now owner Oracle products, including Berkeley DB in lower end solutions. This along with the recent Oracle Express Edition (XE) free offering will enable Oracle to target market’s that were previously unavailable.

This is clearly not for a financial intention. There is no way to obtain a return on investment, however it’s all about upselling. By providing these offerings, Oracle now has a large marketplace to promote commercial product offerings.

Assuming, Oracle goes down this path, I’d assume they will also provide clear migration paths between stack offerings, as part of upselling. This will be more complex to achieve. I also suspect that Oracle will move towards a better Web 2.0 model, by providing products are no cost, but provide a service to support and maintain in these new marketspaces.

In closing, why did Oracle purchase InnoBase, the creators of the MySQL InnoDB Storage Engine? This question seems still unanswered. It doesn’t fit easily into the above ideas of differing technology stacks. Ultimately, money buys power, and I suspect it was just that, with no real future intentions or clear plan.

Update
Thanks for the comment about JBoss, yes, it’s not official, nor is Xen, but it took Oracle I think 15 months to get Peoplesoft.

I came across the Oracle Corporation Wikipedia entry in other work, the end of the history page reads a who’s who of acquisitions.

Tux


We all know Tux as the Linux penguin, and those that know me, understand how much I hate Microsoft, and that my core logo, as shown down the right of my blog with Windows Sucks is what I preach. Well I’ve now had this made into a logo on tee-shirts.

As part of searching for images, I’ve come across a few alternative images that I really like, Tux and the BSD demon, Tux and the loosing Windows and MSN logo. You can find more of my collected works at Tux Images

A call to arms!

With Oracle Corporation purchasing InnoBase, the company providing the InnoDB Storage Engine, and now reliable rumors of the acquisition of SleepyCat, the BDB Storage Engine, both key transactional storage engines for MySQL are effectively owned by a competitor.

While the is a strange and probably unchartered territory for both organisations, I’m personally concerned. I use InnoDB extensively, however if there was a comparable alternative within MySQL I’d consider switching out of principle. Is Oracle purchasing these organisations a bad thing? We don’t know. That’s the problem. While MySQL will undoubtly continue to provide these storage engines as part of the MySQL Database I believe a call to arms is needed.

It’s true that Oracle helped more general adoption of Linux when it announced this as it’s primary platform some years back. I’m sure with a middleware suite such as JBoss this will benefit from Oracle’s exposure, but will it benefit in it’s development? Will funding for development skew the product torwards what Oracle wants, not the community? Even things such as BerkleyDB being embedded in Open Office, and Google wanting to spend into the refinement of Open Office for possible web services options just makes you wonder whats happening. I’m on holiday’s trying to relax, and not do any reading, developing or communicating, but the one thing that makes my mind turn is, why is Oracle doing this?

My concerns are: look what happened to the acquired big commercial competitors, the PeopleSoft, Siebel, JD Edwards. Now, it’s a little difficult with the Open Source software, but I’m no licence expert. While it will continue to be available in current licencing options, I’m sure there has to be some concerns. Even something trivial like, all MySQL downloads that include these engines must first be registered on the website, and all these statistics must go to Oracle. Can they do this? I have no idea, but what if they could.

I’m sure internally in MySQL AB there are plans afoot for alternative transactional storage engines. The pluggable nature of these within MySQL makes it easy to move in this direction. I think sometimes, some functionality is kept close to heart, and you only here about it when some actual work is released.

I’m interested to guage reaction to see if a public working group should be setup to specifically tackle the issue of an independent transactional storage engine. Are there others out there that feel the same way I do. Now let me be clear, I’m not anti Oracle, infact rather pro Oracle, but I’m very anti Microsoft. If it was Microsoft buying these companies how would people react?

In my opinion this should be a bold announcement from MySQL now. In stating the development and release of a new Transactional Storage Engine this year, and then not evening mentioning InnoDB and BDB, they are downplaying the Oracle buy in, and emphasising a true Open Source Company option. In no means say they are no longer supporting InnoDB and BDB, but if the media exposure from MySQL continues to mention them, then it’s going to bleed into some reference back to Oracle.

I can’t contribute to the actual development in C++, if it was Java that would be a different matter, but as I move more away from hardcore coding there are plenty of other areas in which I could contribute.

InnoDB, BDB. What is Big Red Doing!

Last year saw a record number of acquisitions by Oracle Corporation. Of note was in October 2005 InnoBase (Read Press Release) which had a direct relationship with MySQL providing the InnoDB Storage Engine. It’s too early to tell what the impact to MySQL will be if any.

I’ve been in Singapore, and have not read any news in the past few days, but all information I’m receiving from those collegues in the know is that Sleepycat Software (the company behind Berkley DB, and the MySQL BDB Storage Engine) is now firmly in the sites of Oracle Acquisition. The rumors of JBoss is also definitely on the go. No official news from any Oracle Press Releases as yet.

So what is Oracle doing, and what impact will this have for MySQL? Both InnoDB and BDB are key transactional storage engines. Given that MySQL has the full capability for ease of plugin for new storage engines is this a prod to MySQL to consider another alternative?

If I wasn’t mistaken, it seems Larry Ellison is looking to be a big name in open source!

MySQL Benchmarking

As of MySQL 5.1.4, there is a supported benchmarking tool called mysqlslap. Not sure where they got the name from, is there going to be a mysqltickle next?

create database mysqlslap
use mysqlslap
use schema.sql

mysqlslap –skip-create-schema

–skip-create-schema
mysqlslap: No user supplied data to insert or –auto-generate-sql specified!

trashes schema

I’ll be using the MySQL Sakila Sample Database.

[arabx@web1 sql]$ mysqlslap -P3307 -hlocalhost.localdomain -uroot –auto-generate-sql Seconds to load data: 0.08929
Number of clients loading data: 1
Number of inserts per client: 0
Seconds to run all queries: 0.23113
Number of clients running queries: 1
Number of queries per client: 1000

mysql -P3307 -hweb1.onegreendog.com -usakila -psakila sakila

mysqlslap -P3307 -hlocalhost.localdomain -uroot –create=schema.sql
mysqlslap: No user supplied data to insert or –auto-generate-sql specified!
[arabx@web1 sql]$ mysql -P3307 -hlocalhost.localdomain -uroot mysqlslap

Syntax

$ mysqlslap -?
mysqlslap  Ver 0.1 Distrib 5.1.4-alpha, for pc-linux-gnu (i686)
Copyright (C) 2005 MySQL AB
This software comes with ABSOLUTELY NO WARRANTY. This is free software,
and you are welcome to modify and redistribute it under the GPL        license

Run a query multiple times against the server

Usage: mysqlslap [OPTIONS]

Default options are read from the following files in the given order:
/etc/my.cnf ~/.my.cnf
The following groups are read: mysqlslap client
The following options may be given as the first argument:
--print-defaults        Print the program argument list and exit
--no-defaults           Don't read default options from any options file
--defaults-file=#       Only read default options from the given file #
--defaults-extra-file=# Read this file after the global files are read
  -a, --auto-generate-sql
                      Generate SQL where not supplied by file or command line.
  -C, --compress      Use compression in server/client protocol.
  -l, --concurrency-load=#
                      Number of clients to use when loading data.
  -c, --concurrency=# Number of clients to simulate for query to run.
  --create=name       File or string to use for create.
  -d, --data=name     File or string with INSERT to use for populating data.
  -#, --debug[=name]  Output debug log. Often this is 'd:t:o,filename'.
  -F, --delimiter=name
                      Delimiter to use in SQL statements supplied in file or
                      command line.
  -D, --drop-schema   Drop schema if it exists prior to running and after
                      running.
  -e, --engine=name   Storage engine to use for creating the table.
  -?, --help          Display this help and exit.
  -h, --host=name     Connect to host.
  -i, --iterations=#  Number of iterations.
  -x, --number-char-cols=#
                      Number of INT columns to create table with if specifying
                      --sql-generate-sql.
  -y, --number-int-cols=#
                      Number of VARCHAR columns to create table with if
                      specifying --sql-generate-sql.
  -n, --number-rows=# Number of rows to insert when loading data.
  -p, --password[=name]
                      Password to use when connecting to server. If password is
                      not given it's asked from the tty.
  -P, --port=#        Port number to use for connection.
  --protocol=name     The protocol of connection (tcp,socket,pipe,memory).
  -A, --skip-create-schema
                      Don't create a schema, use existing schema.
  -L, --skip-data-load
                      Don't load any data, use existing data set.
  -Q, --skip-query    Don't run any queries.
  -s, --silent        Run program in silent mode - no output.
  -q, --query=name    Query to run or file containing query to run.
  -S, --socket=name   Socket file to use for connection.
  -u, --user=name     User for login if not current user.
  -v, --verbose       More verbose output; You can use this multiple times to
                      get even more verbose output.
  -V, --version       Output version information and exit.

Auditing an existing MySQL Installation

Yesterday I ran into an old collegue that now runs quite a successful computer store chain and highly successful web store here in Australia. Long story short he was having some MySQL problems, so I offered to pass my eye over it. Now, given that they had some data corruption in stock levels not being correct (e.g. getting to an inventory count of -1), my first split second thought was inappropiate transaction management.

In thinking last night, what would I do as part of auditing an existing MySQL Installation and application quickly for reference and also to highlight issues etc, assuming I would have no access to any administrators or developers.

So what would you do? I made some preliminary notes, here’s the full account of what I did do.

Audit Steps

OS Specifics

$ mkdir /tmp/arabx
$ cd /tmp/arabx
# keep a quick copy of stuff
$ script
# Linux generals
$ hostname
$ uname -a
$ uptime
$ df
$ which mysql
$ mysql --version

MySQL Specifics

$ mysql -uroot -p mysql
mysql>  show variables;
mysql>  show status;
mysql>  show databases;
mysql>  show processlist;
mysql>  show full processlist;
mysql>  select host,user,passwd from user;
mysql> exit;
$ cat /etc/my.cnf
# error not found?
$ find / -name my.cnf
# Results
$ cat /etc/mysql/my.cnf
$ cp /etc/mysql/my.cnf .
$ cd /usr/local/mysql
$ du
$ cd data
$ ls -al
$ cp *.err /tmp/arabx  # for later review
# What, no database, surely they were not recording in the mysql database
# quick confirm there was another database from earlier list?
$ grep datadir /etc/mysql/my.cnf
# I see off somewhere else
$ cd /var/lib/mysql
$ ls -al
$ du
$ cp *.err /tmp/arabx  # for later review
$ cd /tmp/arabx
$ mysqldump --no-data  -u[user] -p [db] > schema.sql
$ grep TYPE schema.sql
# Observation:  All MyISAM, the first proof of my initial theory
$ mysql -u[user] -p [db]
mysql> show tables;
mysql> show tables status;
mysql>exit;
$ cd /tmp
$ tar cvfz arabx.tar.gz arabx
$ scp arabx.tar.gz ...

Application Specifics
I’m not going to detail the steps here as this is really very implementation dependant. What I did in summary was:

  • Identified website location on filesystem, general du, ls -l commands
  • View working screens showing Stock Count logs, Forfill Order and Product Return
  • Review code of these areas, as well as the data, confirming what was seen on screen via SQL

Recommendations

Immediate

  • Cleanup current directory of html files to remove old files, or old backup copies. This ensures no PC has some old page with bad code bookmarked
  • Cleanup /usr/local/mysql/data as it’s now defined in /var/local/mysql. It threw me with to data directories and error logs. It was only that the database directory was not in the first location, otherwise I may have missed it initially.
  • Stock Adjustment page needs to log an Adjustment history for Audit Trail (Only Sales and Returns were in Audit Trail, so it left a possible gap?)
  • Implementation of Transactions. Given the volume of transactions, and that it would appear that LOCK TABLES had been implemented but removed due to performance, obvious choice is implement InnoDB tables, and transaction management in code. (Quite some work)
  • Change of some columns from DATE to DATETIME to record the time of occurance. (Code was using NOW(), so that part’s already done). Or, implement some TIMESTAMP columns (as none were in use) and leverage MySQL standard functionality.

Medium Term

  • Running MySQL 4.0, which is fine, but the data corruption and lack of clean website code, leads to an easier solution for auditing via triggers.
  • Upgrade to MySQL 5.0 Key reason, triggers. This enables more audit analysis with even less need for or initial understanding of the application
  • Implement a CVS respository. Even for single development, it’s a habit that far outways the impact of a few more commands.
  • Review Backup strategies for HTML code and respository, which was only being mirrored, but not backed up for a disaster recovery situation

I guess if I ever do this again, there is merit in cleaning this all up and providing some level of automation.
Does anybody have any suggestions of obvious other things to consider.

MySQL Workbench 1.0.1 First Impressions

These are my first impressions of MySQL WorkBench 1.0.1. Rant and rave you may say, but a new user, or an experienced modeller would probably observe these points. Also, given that (with a poll?) I suspect a good number of users will be previous DBDesigner users, some level of functionality that may not be considered initially in a new product, should be considered for this migration path of legacy users.

I’ll take the time to review the Forums adding my points, and review Bug System but for now, just blogging is easier.

Conclusion

Note: Generally a conclusion is at the bottom, but I’d suspect most readers will switch off quickly, I wanted to catch the gaze in the first few secs.

In summary, I’ve just scratched the surface, I’d do a more fuller QA review and testing, but I’m not certain yet of the best feedback loops, and whether it’s warranted. A lot of what I’ve said may already be known internally. I don’t want to sound petty, but I would not like to reference this as a 1.0 product, it’s got some way to go to being both stable, consistent, and complete in a basic level of functionality. In addition, the MySQL Website 5.0 page speal lists MySQL Workbench as a 5.0 product, I think this is a little inaccurate.

This product appears to have a sound start, but it’s a long way from me considering moving from DBDesigner, which is a real shame, as I’ve been waiting now probably 8 months to get my hands on this (and loose some annoying bugs in the now unsupported DBDesigner), and I’m desperately wanting to get support for MySQL 5 re-engineering.

Main View

After startup you are presented with the MySQL Gui Window, which consists of a number of elements, the menu line, the toolbars (horizantial and vertical), the Main View, and some tab views (shown on right side).
Main View

  • You can’t double click on a table to get into edit mode. You must choose the pencil (bottom left corner of table). When you have a table with 30+ columns, this involves some more scrolling, particularly depending on your view magnification, if you start by finding the table first in a large 150+ table model.
  • While the display of the different elements within a table is nice (e.g. Columns, Indicies, foreign keys etc), when I’ve got 150+ tables in my diagram I don’t want to see this verbose information. I’d like to see a user option of cut down views, removing this headings, display/hide indicies,foreign keys, triggers.
  • What does the lock icon do, and the other bottom right icon, there seems to be no feedback as to what they do?
  • What does the other icon do (not pencil, not lock), again appears to be no feedback?
  • I don’t see a snap to grid? I also don’t see anyway to adjust the size of the grid.
  • I see in the Schema window, the hopeful ability to reference multiple schemas (unclear of the full benefit here), but for now I see no clear way to create then one. Given this, when you select the Table Tool in the Tool Options you get a drop down box for schema. How do you create multiple schemas? Should you in one diagram? If you only have one defined, the drop box should not be present.
  • Tool Options shows 3 colors, that’s nice, however how do you move to selecting more? The color only highlights the table name in the Main View. I’d like to see a background color for all tables. Again in 150+ tables, color coding tables from modules makes it easier to see them, the heading is not enough.
  • You can color a table when creating, but there is no ability to edit the color at a later time?
  • After creating two tables both with Primary Keys, I tried to create a relationship between both, using all 3 relationship options. While I could select the source table, I couldn’t select the destination table in any way. (click, double click, etc)
  • Creating a view with the View tool, provides the iconic buttons in the top section of layout, different to the table layout. It should be consistent.
  • The View Tool, allows you to enter SQL for the view, that’s nice, but it should be displayed on the Data Model. The Data Model’s responsibility is to show tables, columns and relationships. It should show table names, column names (in the case of ‘*’, I think it should probably show ‘*’, not expanded columns due to the complexity.
  • I created a table with an INT(11), VARCHAR(40) and X (which becomes X(0), se Table Editor points). In the resultant Main View, I get INT,VARCHAR and X((0)) as the column definitions. There is no consistency here.
  • I would like to see the capability of removing data types from the display within tables. In a more structured environment, you would first start with a logical model, then move to a physical model, or in early design, you are just defining the probably attributes of table, before they become columns. The datatype isn’t determined, so just listing names, and icon (key,mandatory) is all that’s required.

Schema Tab

  • With my long list of tables, I would like to be able to quickly go from the table in this view to the table in the Main View. (Previously DBDesigner provided a double click to achieve this).
  • I understand that the ordering of categories within the database is alphabetical, but it should be in priority order (Table,View,Routine…). Two reasons, this is the likely creation process, you create tables first, and second, for any schema management prior to 5, the other 3 aren’t relevent.
  • With the previous point, I don’t see any compatibility management for MySQL versions. While there are two many subtle changes to warrent a great deal of work, a simply compatibility of 4.0, 4.1, 5.0, 5.1 would clearly provide when in a 4.x compatibility, views, routines etc are invalid, and for simplicity should be removed from views (Schema Tab) and even vertical menu.

Editing

Table Editor.

  • Has no access to help. In this case, on first view I thought, what does Flags mean as a column attribute? While they not be any help yet, the infrastructure should be in place.
  • Data Type has no completion text. (a.k.a DBDesigner would autocomplete, say if you started with a D, to get Date)
  • Data Type, if you specify nothing, it defaults to (0) which is invalid. If you specify D it defaults to D(0). Regardless of what is entered, the table structure should be syntaxially valid at all times on exit of the field.
  • Options Tab. There are a lot of MyISAM specific options, yet I’m using the default Engine which was InnoDB. These should probably be hidden from view.
  • I don’t like the fact you have to go Apply, then Close, and it’s so easy just to go Close and lose your changes without warning. I think theres is a clear need just for a ‘Save’ which saves your changes and returns you to the Main View
  • Show Advanced/Hide Advanced, is only relevent for the Columns tab (at this time), so it should not be visible on the other tabs.
  • I see no ability in this version (1.0.1+) to define the set of valid Data Types (in my case I like to remove some, to simply autocompletion (which isn’t present)

Other

User Interface

  • No Tool tips for menu icons
  • Help | About didn’t do anything. Would have expected a popup window.
  • I’d like to see some tool tips on the icons used within the objects placed on the Main View.
  • There is no other placeholders for help. Worse case, defining the screens as to be completed, perhaps with some identifier, and then the ability for users to contribute to the help (a web 2.0 think), it will be better then writing from scratch. Even a wiki to allow users to start on the help would I think be benefical

Infrastructure
The saved files are XML, yet you give an extension of .mwb While that is nobel, and identifying it’s it’s .xml using a .xml shows it’s XML and also it makes it easier for other use. I can think of 2 straight away. First, I may wish to use XPath Explorer to quickly search for something. Second, I may use XSLT to provide a HTML quick view of my schema?

Errors
Go the following error, but was not able to reproduce, created table, added some columns, moved around tabs, added a new column lastUpdateTimestamp, [tab] to goto the data type, and crash.

** CRITICAL **: myx_grt_bridge_dict_item_get_value: assertion `dict != NULL’ failed

Testing/Trialing new MySQL Releases

By now, I’m sure you have all heard about Free VMware Player allowing easy and quick access to see, view and use other OS’s easily. For those Windows users out there, now is your chance to trial MySQL under Linux with no impact to your system, why wait.

See the MySQL Virtual Machine details on the VMware site. On closer inspection this effectively pushes you to the VMware Technology Network (VMTN) page within the MySQL website.

The MySQL guys needs to update their site to reflect new reference to the free player, rather then a trial version of Workstation. Even VMware Server is free (could be mentioned). You can read more about the offerings etc at a previous blog Using VMware Server (free).

Also MySQL is only offering MySQL 4.1.12 (that was released in May last year). Surely this would be a great way to push the newer releases, I’d like to see MySQL offer this for at least the current production GA version 5.0, and it would be a great way to promote new releases, like an alpha release of 5.1. How easy would it be then for people to trial and test the new features without any hint of messing up or changing any existing environments. Perhaps the MySQL marketing department could consider this?

Is is more work? Yes. Will it take resources? Yes. But look at the benefits. Instead of the diehards that are prepared to download bleeding edge releases, you can now reach a newer market of users with an easier, cleaner and throw away installation of newer releases. You would not consider doing it for every dot release, more the current GA 5.0, and alpha and RC’s for newer versions I think.

Using VMware Server (free)

VMware recently released the Free VMware player which allows you to test other OS’s easily in parallel with your current OS. They also provide the Virtual Machine Center so you can even trial easily a number of different pre-packaged solutions.

Of course, my only real need for this is to run Windows apps for limited reasons, and they don’t provide a Windows Virtual Machine, so in order to create one you need another product. VMware provide VMware Workstation which as a 90 day trial, I’ve downloaded a few times, but never actually tried.

Just released is VMware Server which is a free server virtualization for Windows and Linux. Now I haven’t read the differences between these products, but free verses free trial for what appears to be the same thing for what I want, well no brainer.

So in summary, I’ve downloaded the VMware server free edition, installed a Windows XP, and also installed the Browser Appliance from the Virtual Machine Center, and they both work. I’m happy for now.

Release Notes

rpm -ivh VMware-server-e.x.p-20925.i386.rpm

/usr/bin/vmware-config.pl

Making sure services for VMware Server are stopped.

Stopping VMware services:
   Virtual machine monitor                                 [  OK  ]

You must read and accept the End User License Agreement to continue.
....
VMware is a trademark of VMware, Inc.

Do you accept? (yes/no) yes

Thank you.

Configuring fallback GTK+ 2.4 libraries.

In which directory do you want to install the mime type icons?
[/usr/share/icons]

What directory contains your desktop menu entry files? These files have a
.desktop file extension. [/usr/share/applications]

In which directory do you want to install the application's icon?
[/usr/share/pixmaps]

Trying to find a suitable vmmon module for your running kernel.

The module bld-2.6.9-5.EL-i686smp-RHEL4 loads perfectly in the running kernel.

Do you want networking for your virtual machines? (yes/no/help) [yes]

Configuring a bridged network for vmnet0.

Your computer has multiple ethernet network interfaces available: eth0, eth0:0,
wlan0. Which one do you want to bridge to vmnet0? [eth0]

The following bridged networks have been defined:

. vmnet0 is bridged to eth0

Do you wish to configure another bridged network? (yes/no) [no] no

Do you want to be able to use NAT networking in your virtual machines? (yes/no)
[yes]

Configuring a NAT network for vmnet8.

Do you want this program to probe for an unused private subnet? (yes/no/help)
[yes]

Probing for an unused private subnet (this can take some time)...
The subnet 172.16.71.0/255.255.255.0 appears to be unused.

The following NAT networks have been defined:

. vmnet8 is a NAT network on private subnet 172.16.71.0.

Do you wish to configure another NAT network? (yes/no) [no]

Do you want to be able to use host-only networking in your virtual machines?
[yes]

Configuring a host-only network for vmnet1.

Do you want this program to probe for an unused private subnet? (yes/no/help)
[yes]

Probing for an unused private subnet (this can take some time)...
The subnet 172.16.60.0/255.255.255.0 appears to be unused.

The following host-only networks have been defined:

. vmnet1 is a host-only network on private subnet 172.16.60.0.

Do you wish to configure another host-only network? (yes/no) [no]

Trying to find a suitable vmnet module for your running kernel.

The module bld-2.6.9-5.EL-i686smp-RHEL4 loads perfectly in the running kernel.

Please specify a port for remote console connections to use [902]

Stopping xinetd:                                           [  OK  ]
Starting xinetd:                                           [  OK  ]
Configuring the VMware VmPerl Scripting API.

Building the VMware VmPerl Scripting API.

Using compiler "/usr/bin/gcc". Use environment variable CC to override.

Installing the VMware VmPerl Scripting API.

The installation of the VMware VmPerl Scripting API succeeded.

Generating SSL Server Certificate

In which directory do you want to keep your virtual machine files?
[/var/lib/vmware/Virtual Machines]
Please enter your 20-character serial number.

Type XXXXX-XXXXX-XXXXX-XXXXX or 'Enter' to cancel:

You cannot power on any virtual machines until you enter a valid serial number.
To enter the serial number, run this configuration program again, or choose
'Help > Enter Serial Number' in the virtual machine console.

Starting VMware services:
   Virtual machine monitor                                 [  OK  ]
   Virtual ethernet                                        [  OK  ]
   Bridged networking on /dev/vmnet0                       [  OK  ]
   Host-only networking on /dev/vmnet1 (background)        [  OK  ]
   Host-only networking on /dev/vmnet8 (background)        [  OK  ]
   NAT service on /dev/vmnet8                              [  OK  ]

The configuration of VMware Server e.x.p build-20925 for Linux for this running
kernel completed successfully.
$ vmware

When started you can enter the supplied license key that was emailed to you.

Running Internet Exploder (ie) under Linux

It’s really so simple, I’m surprised it doesn’t come bundled in distros. (Well I take that back, I’m as anti-microsoft as you can get, but unfortunately, we have to lower ourselves and our good work to the power of Bill who has it over those uninformed majority being brainwashed with a non-standard and flawed browser, that you have to break your code to get to work for it somethings).

Anyway, enough ranting, it’s all at www.tatanka.com.br/ies4linux/. If you can’t have this all done in 15 mins, well you need a faster internet connection! (it takes 14 mins for the downloads, and 1 min of work)

Pre-Requisites

You need Wine and cabextract as pre-requisites.

$ cd /src/rpm
$ wget http://optusnet.dl.sourceforge.net/sourceforge/wine/wine-0.9.2-1fc1winehq.i386.rpm
$ wget http://optusnet.dl.sourceforge.net/sourceforge/wine/wine-0.9.2-1fc1winehq.src.rpm
$ wget http://www.kyz.uklinux.net/downloads/cabextract-1.1-1.i386.rpm
$ wget http://www.kyz.uklinux.net/downloads/cabextract-1.1-1.src.rpm
$ rpm -ivh wine-0.9.2-1fc1winehq.i386.rpm cabextract-1.1-1.i386.rpm

ies4linux

$ cd /opt
$ wget http://www.tatanka.com.br/ies4linux/downloads/ies4linux-1.3.4.tar.gz
$ tar xvfz ies4linux-1.3.4.tar.gz
$ cd ies4linux-1.3.4
# It pays to just check some config options as documented first
# see http://www.tatanka.com.br/ies4linux/en/instructions/configuration/
$ ./ies4linux
=================  IEs 4 Linux =================
Install IE6, IE5.5 and IE5 on Linux via Wine.
Credits: Sergio Lopes slopes at gmail dot com
Project page: http://tatanka.com.br/ies4linux
See README file for more info

Installation options:
[1] Install IE6, IE5.5 and IE5
[2] Install only IE6
[3] Install only IE5.5
[4] Install only IE5.0
Please choose an option: 1

...  [churning downloads from that site including  DCOM98.EXE,  mfc40.cab,249973USA8.exe, ie60.exe, ie55sp2.exe, ie501sp2.exe
, swflash.cab ] ...
[ OK ]

Creating basic Windows installation ...
 Creating Wine Prefix
 Installing RICHED20
 Installing DCOM98
 Installing ActiveX MFC40
 Finalizing
[ OK ]

Installing IE 6 ...
 Extracting downloaded exe file
 Extracting CAB files
 Installing TTF Fonts
 Configuring ie6
[ OK ]

Installing IE 5.5 ...
 Extracting downloaded exe file
 Extracting CAB files
 Installing TTF Fonts
 Configuring ie55
[ OK ]

Installing IE 5 ...
 Extracting downloaded exe file
 Extracting CAB files
 Installing TTF Fonts
 Configuring ie5
[ OK ]

Installing Flash Player 8 ...
 Preparing installation
 Installing flash on ie6
 Installing flash on ie55
 Installing flash on ie5
[ OK ]

IEs4Linux installations finished! ...

Operation

If you want it, you run ie5, ie55, ie60. If I could see just one improvement, a command that you pass a url, and it just opens 3 windows so you can see them all side by side on one screen (bigger screen needed). Of course if you could script input on one, and have it reflected on all that would be even cooler. I’d suspect you could probably achieve this, have a Firefox driver that records stuff, like TestGen4Web, and then replays across the other 3 exploder windows. Food for thought.

Thanks goes to Tate for telling me about this. Yet again, it’s the referral of a physical person that put you on the path.