I was talking with a mysql rep about their commercial license. I don't think it's clear to even them. Basically they say if any app specifically uses mysql, then each mysql server needs a commercial license. So I ask "How do you determine if an app specifically uses mysql? Say it's PHP and it uses PHP's mysql library?" The rep says "Well, we pretty much need to review it on a case-by-case basis." Then I ask "Well, what if I use a generic database library like adodb?" He says "Probably not, but hard to say." The rep told me that since they moved from the LGPL to the GPL, that requires any app that uses mysql's library to be either GPL itself, or buy a commercial license. That's not how I understand the GPL. With LGPL you can distribute the libraries, but with GPL you can't (without GPL'ing your own code). I also asked "Well, who needs to buy the licenses? The developer or the customer?" He said "Well, probably the developer, just to make sure the customer has a license." But only one license per server is required? Many many people use multiple mysql-using apps on a single server. How about PHP? Anybody that has the mysql library enabled needs a mysql commercial license? Last I checked mysql.com, there were conflicting pages concerning their licensing scheme.

I really think mysql is trying some FUD and stretching the GPL to try to sell licenses.

    It was my understanding that if you sold your PHP scripts as an appilcation, and your PHP scripts will work with ONLY MySQL, then you need to have a MySQL license for each user.

    BUT if you're PHP scripts will work with other databases ( you're using PEAR or ADODB for instance ) then you DO NOT need the licenses.

      There are two different issues here. One is what does the GPL say, and the other is what does MySQL say?

      What the GPL says is all that is important. MySQL can try to reinterpret the GPL all they want, but they can't do it. They released MySQL under it, and they are therefore bound by it.

      The GPL basically says that if you LINK to GPL software, and then distribute said software, you must GPL it. In the case of PHP, the linking occurs when you compile PHP against MySQL, not when you write PHP code.

      Since the GPL only kicks in when you distribute, it means that should you distribute the PHP binaries with MySQL you would need to GPL PHP. But PHP has a license that explicitly disallows relicensing, so technically, you cannot distribute the PHP interpreter binaries and MySQL connect libs linked together under the GPL, only the commercially licensed MySQL would allow you to do this.

      What you do with your PHP code is none of their damned business, as it is never linked to anything, it is PHP code. Since the PHP interpreter in binary form cannot be redistributed with GPLd MySQL, it's a non-issue. I.e. you can't create a system that would require you to GPL your PHP code, since PHP cannot be relicensed.

        Good points. The GPL only really applies when you "bundle" something GPL into your app AND distribute it. If end users separately install your PHP app and MySQL, and don't distribute anything that includes MySQL (well, and your app too if you don't want that), then, well, there's no reason your PHP app needs to be GPL'd or anybody needs a mysql license. The mysql rep I talked to really seemed to be tap dancing.

          16 days later

          Hi all,

          I would just like to jump in with a quick request for clarification.....

          If I write PHP code that uses PEAR and MySQL and NEVER distribute it, then I don't have to worry about licensing or opening up the source or whatever, right?

          And, correct me if I'm wrong, I can charge people to use the code that I've written as a service, right?

          Basically, if I write and host an application on my own server and then let people use the applications on my server for a fee, then I'm fine, even if I'm using PHP, PEAR, MySQL, etc....

          Thanks in advance for your help.

            Write a Reply...