The tool e-db2 is a utility program around IBM's DB/2 database.
e-db2 is basically a command-line program to access DB/2, a-la the client
programs isql, mysql and others. e-db2 lets you run SQL
statements, but also provides the following:
e-db2 has a line-editing function, letting you
retrieve previously entered commands with the up-arrow key, and so
on.
e-db2 "knows" a few special
commands, to unload and reload table contents, to describe tables,
to show the tables of a database, and so on.
An overview of the command-line options is obtained by starting e-db2
without arguments. Once e-db2 is started and connected to a database, use
the command help; to obtain an overview of the built-in special commands.
The installation of e-db2 supports two modes:
Note that e-tunity's public site http://public.e-tunity.com only distributes the binaries.
To install e-db2 using the binary distribution, the following steps are
necessary:
e-db2.tar.gz) is
obtained and placed in a temporary directory, say, /tmp.
bin/ and lib/ are
present. We strongly suggest to use the base directory /usr/e, the
home of the e user which is part of the standard e-tunity setup.
The archive is unpacked using
su - e cd /usr/e tar xvzf /tmp/e-db2.tar.gz
bin/e-db2-X.YY, where X.YY is a version ID, such
as 1.19;
bin/e-db2, a symbolic link pointing to the above
stated binary program;
lib/e-db2.bnd-X.YY, a DB/2 "bindfile" for this
version;
lib/e-db2.bnd, a symlink pointing to this bindfile.
ldd /usr/e/bin/e-db2.
If ldd reports missing libraries, then this binary distribution is
not suited for the target system. In that case e-db2 won't run. If
this occurs, please contact us via
info@e-tunity.com and we'll try to make
a new distribution.
e-db2 must be make known to DB/2 using the bindfile.
This is done with the command db2 bind /usr/e/lib/e-db2.bnd.
To successfully build and install e-db2, the following prerequisites must
be met:
e-lib must be installed.
Makefile may need adaptations to set the DB/2 base
directory, and so on.
| Variable | Meaning | Example |
DB2INSTANCE and DB2USER |
User instance to use for DB/2 access. | db2inst1 |
DB2DATABASE |
Database against which e-db2 will be built. |
sample |
EBASE |
Home directory of the e user. |
/usr/e |
EBINDIR |
Directory to install to. | /usr/e/bin |
To install e-db2, please obtain the archive (available via e-tunity) and
unpack it. It spills into a directory e-db2/. Then chdir into this
directory, and run make install. This should be run as the user e.