Edit 2020-01-02: corrected limit for free Db2 on Cloud to the correct 200 MB. Original text is still in the document, in strikeout.
This is one of the few blog entries where I include the Db2 version number right in the title. This is because packaging has been one of the most in-flux areas recently. There were statements made at IDUG EMEA publicly that I won’t even repeat because I don’t believe they’ll prove to be true in 6 months. On the positive side, Db2 has very much moved towards being simpler and easier to figure out, especially with 11.5.
The information in this blog entry is based entirely on documents for North America, and the discussions I’ve had with IBM Product Offering Management. They are my opinions and interpretations of that data only. Anything here should be explicitly verified with IBM before relying on it – I may be wrong. There may also be different rules in different geographies.
It used to be that figuring out which edition a client needed was a somewhat complex matrix of what features they expected to use and how big their hardware was. Added on to that was the calculation of PVUs, which was particularly difficult in a cloud environment, where things like the type of processor a VM was running on might not hold still.
To start, Db2 has what I think is the best free offering among RDBMS vendors. I’m constantly surprised IBM doesn’t trumpet this more.
First of all, IBM offers a completely free cloud instance of Db2 that includes most Db2 features available. It is called the Lite Plan, and anyone can create an IBM ID (also free) and sign up for it. This is in a shared multi-tenant environment, and has no limits on data transfer in and out or how much work you make it do.
There is a 200 GB limit on the data size (compressed) that you load into the database, but this actually surprised me because not long ago, it was 100 GB – they’ve increased it and even I didn’t hear about it! The limit is 200 MB of data. You can use this in a production environment if you want, but keep in mind that there’s no HA here – read the SLAs carefully to understand what the uptime commitments are. One of the good things about Db2 cloud environments is that patches (fix packs and mod packs) land there first, so you can sometimes play with features that won’t be available in the on-prem versions for 6 months.
This is the quickest and easiest way to get a database up where you can play with Db2 or Db2 SQL, without having to know much at all about Db2.
Developer Community Edition
Also entirely free for use in both production and non-production environments is Db2 Community Edition. This is what Express-C and Developer-C have morphed into. Db2 Community edition includes all of the fancy features of Db2, with certain hardware restrictions, and no support. In this case, the limitations are currently 4 cores, 16 GB of memory, and 100 GB of storage per database. Note that is per database and not per partition, so you cannot use partitioning to get around the data limit. The data limit is again compressed data, and with Db2’s excellent compression technologies, you could potentially fit a TB of data into that limit. The community edition comes both as regular install packages, and also as a pre-formed docker image. The docker image is the second fastest way to get something up to play with.
Unlike Express-C, you can apply fix packs without problems.
IBM has stumbled a few times in trying to enforce the data limit, so there may be some odd problems trying to restore other databases in to community edition. There are workarounds – ask on reddit or twitter or stack overflow if you need help with such issues.
Try and Buy
If you need to really install Db2 on some beefier hardware for a proof of concept, you can download any fix pack image (requires a free IBM ID), and install from that code. By default, it will be licensed with a “Try and Buy” license. That license is good for 90 days. When that 90 days expires, Db2 will stop working, so be sure you apply some longer-term license before it does.
Db2 Standard edition is basically what they used to call Db2 Workgroup Server Edition (WSE) and what they used to call Db2 Advanced Workgroup Server Edition (AWSE). Like AWSE, it is a fully-featured version of Db2 – you’re not restricted in what features and options you can use. The restriction again comes in hardware. The restrictions are 16 virtual processor cores and 128 GB of instance memory. These limits apply per server, but are also maximums for an entire pureScale or DPF cluster. This is great because at a similar cost to the old WSE, we can now use compression, WLM and all the other nifty advanced features. This is a fully supported edition of Db2 – you can call in and get support when you run into a serious issue.
You pay on a per-core basis, but instead of PVU calculations that depend on what processors are in use, they are Virtual Processor Cores. This is a much more cloud-friendly metric. Db2 is quite easy to run in a cloud environment with no silly restrictions on licensing any core the database server could run on like some other vendors out there. I believe both monthly and perpetual licensing models are available.
This is now the unlimited hardware version of Db2. You get every feature of Db2, on whatever hardware you want to run it on, assuming you’ve paid for the right number of cores. This edition is stated to only be available as a part of the full HDMP licenses, which has an odd flex-points system I haven’t had much exposure to yet. You buy the points, and then the points buy the Db2 edition. If you want to change your mind and use the points for IBM’s support of PostgreSQL or MongoDB, or some other data technology, then you can do that. I believe both monthly and perpetual licensing models are available.
The old feature matrix that so many of us got to know so well is nearly obsolete, but if you want proof of inclusion of a specific feature, it is still available in the IBM Db2 Knowledge Center. There are a whole lot of “Yes”es in that grid. Note specifically that heterogenous federation is now included. However, Q-replication and CDC replication are now excluded across the board. Heterogenous SQL replication remains included with every Db2 product.