InterBase 4.0 Server
Running on Red Hat Linux 4.2
Contents
Introduction
System requirements
Installing InterBase on Linux
License for InterBase 4.0 on Linux
Documentation
Technical assistance
Compiling applications
Linux platform-specific issues
Converting other InterBase databases to Linux
Introduction
This document describes installation and operation topics related to the port of version 4.0 of InterBase to the Linux operating system.
InterBase is a SQL-compliant, relational database management software product from InterBase Software Corporation. InterBase combines sophisticated database technology with unparalleled ease of use. This free version is fully functional, and certified for Red Hat Linux 4.2. In a client/server configuration, InterBase for Linux is compatible with the commercial versions of InterBase on other platforms.
For a summary of InterBase features, see the web page at the following location:
http://www.interbase.com/products/IB_overview.html
For a thorough description of the InterBase product, see the online documentation. The complete documentation set is available online in PDF format, viewable with Adobe Acrobat Reader.
System requirements
Red Hat Linux version 4.2. Linux kernel version 2.0.30. Red Hat Linux can be found at: http://www.redhat.com/. This release of InterBase is not currently certified on any other earlier or later version of the Linux operating system.
About 10 MB must be free on the filesystem containing the directory /usr/ibase/interbase/i486_V4.0G, where you install the InterBase software. The online documentation for InterBase requires an additional 3.5 MB.
Intel Pentium and Pentium II compatibles. Recommended minimum CPU clock speed: 90MHz.
C and C++ are certified for use when developing applications that run on Linux. The certified compiler vendor and version is GNU gcc 2.7.2.1. Client applications that run on other operating systems and access databases on the Linux platform via a network can be implemented in any language supported by InterBase on the client platform (for example, Borland Delphi on Windows).
Any Intel-compatible hardware that is current as of April, 1998. Incompatibilities introduced by changes in future hardware technology are not predictable. Recommended minimum memory on Linux: 32 MB.
As of the date of this writing, InterBase Software Corporation has not ported InterBase to Linux on any other hardware. However, commercial versions of InterBase do run on Intel, SPARC, MIPS, PA–RISC, RS/6000, PowerPC, and Alpha hardware.
Installing InterBase on Linux
To install InterBase 4.0 on Linux, follow these steps:
1. Download the tar file containing the InterBase 4.0 software. The location of this file is:
http://www.interbase.com/download/linux/IB_4.0_Linux.tar.gz
On some platforms, the web browser tool or the operating system might alter the filename as you download it. This will not affect the contents of the tar file.
It is recommended to put this tar file and the files which you extract from it into a temporary location on your system. They are not needed after you install the software.
2. Extract the tar file in a directory of your choice.
tar xzvf IB_4.0_Linux.tar.gz
Tip:
The .gz extension indicates that this file is compressed with GNU gzip (no relation to PKZIP or WinZip). You can uncompress a gzip-compressed file with the gunzip command (included on Linux). The tar command can also read gzip-compressed files if you include the z option, as in the example above. gzip and tar are included in Linux.The files produced from extracting the tar file are:
3. Run the install script.
sh ./install
The install script expects to find a file called interbase.tar in your current working directory.
Below is a log of the installation script. In bold characters, you see examples of the text you should type in response to prompts. There are a few paragraphs of explanation below that does not appear when you run the install script.
InterBase Installation of V4.0G
Use this script to install InterBase on either the i486 server <node.domain> or one of its clients. You must have superuser privleges.
Answer each prompt with the appropriate information or press Return to use the default values that appear in brackets [ ].
Continue with the installation? [y]:
yThe next output varies, based on your own machine configuration. It is a list of filesystem devices currently mounted. For example:
/dev/sda1 / ext2 rw 1 1
/dev/sda5 /usr ext2 rw 1 2
/dev/sda7 /var ext2 rw 1 2
/dev/scd0 /mount_dir iso9660 ro 0 0
This installation will create the directory tree interbase/i486_V4.0G under the root directory most appropriate for your installation. Enter the root directory you wish to use [/home/node.domain.com]:
/usrYou must enter /usr in response to the above prompt.
InterBase cannot be installed as /usr/interbase, it can however be installed into /usr/ibase/interbase with /usr/interbase linked to it if it must be installed in the /usr partition.
There is no disadvantage to having /usr/interbase be a symbolic link to another directory where the software resides. It is important to be aware of the location that the InterBase software files are installed, in case /usr/ibase/interbase and /usr/interbase are located on different physical filesystems. You should verify that about 10 MB is free on the filesystem containing the former directory.
Do you wish to continue? [Y]:
y
Enter Archive name [./interbase.tar]:
<Enter>Press the Enter key to specify that the install script use the file interbase.tar in the current working directory.
Using ./interbase.tar.
/usr/ibase/interbase does not exist...creating it.
/usr/ibase/interbase/i486_V4.0G does not exist...creating it.
Press Return to continue
Reading files from archive...
Unpacks product files.....
/bin...
. . .
Quite a few files are listed as they are unpacked.
. . .
lib/gds.a
servers.isc
services.isc
Building Interbase sample databases and checking system network files. Depending on your machine configuration, this may take from 1 to 5 minutes.
gds_db 3050/tcp
gds_db stream tcp nowait root /usr/interbase/bin/gds_inet_server gds_inet_server
This completes the InterBase installation script. Please be sure to reboot the node that you have installed on.
Tip:
Despite the last message from install, you do not need to reboot the machine; it is sufficient to restart the inetd daemon process. Issue the command kill -1 pid, where pid is the process id number of the inetd process.License for InterBase 4.0 on Linux
InterBase 4.0 for Linux is a free offering of InterBase Software Corporation. Make sure you read and follow the license terms completely. You can find the text of the license agreement included in the tar file which you download or at the following location:
http://www.interbase.com/download/linux/linux_lic_bef.html
InterBase enables its product functionality through a "key," an array of options which enable individual product features. InterBase 4.0 for Linux comes with a pre-defined key, enabling full product functionality. The software can act as a client to connect to a local or remote InterBase database on Linux or other supported platform. The software can also act as a server, accepting TCP/IP connection requests from and serving data to client applications on remote workstations running Linux or any other supported platform.
Documentation
This document, Running on Red Hat Linux 4.2, is also available in digital format at:
http://www.interbase.com/download/linux/IB_4.0_Linux_readme.pdf
The InterBase 4.0 product documentation is available from the InterBase Software Corporation web site:
http://www.interbase.com/download/linux/IB_4.0_docs.tar.gz
The files in this tar archive are digital versions of the full documentation set that ships in hardcopy with commercial versions of InterBase 4.0.
The files in this compressed tar file are in Portable Document Format (PDF). Use Adobe’s free PDF viewer, Acrobat Reader, to read or print the document files. You can download Acrobat Reader for Linux from the following web site:
http://www.adobe.com/prodindex/acrobat/readstep.html
Printed and bound editions of the InterBase 4.0 manuals are available as a separate commercial purchase from INPRISE Corporation, Borland and Visibroker Products (formerly Borland International).
Technical assistance
This free product is not supported by the Client Services team at InterBase Software Corporation. Questions and requests for assistance should go to the newsgroup at the following location:
Red Hat Linux is available from Red Hat Software, Inc. Their web site is:
Purchase Red Hat Linux 4.2 at the following location (note that InterBase 4.0 is not compatible with Red Hat Linux 5.0):
http://www.redhat.com/products/product-details.phtml?id=rhl-intel4
For problems and assistance with Red Hat Linux 4.2 on Intel, see the following location:
http://www.redhat.com/support/docs/rhl/intel/rh42-errata-intel.html
Updates to Red Hat Linux 4.2 are available at the following location:
Compiling applications
Each operating system has differences that require platform-specific instructions for compiling and linking executables. This section explains the compiling and linking options that are available for creating InterBase applications on Linux. This version of InterBase (LX–V4.0G) is certified with the following compilers:
These compilers are present in the Red Hat Linux 4.2 product.
The following procedure for compiling applications applies whether the code is output from the gpre embedded SQL preprocessor or you're using the InterBase API to code your application:
1. If you are programming in embedded SQL, run the gpre preprocessor first:
gpre -z -m -n filename.e
This automatically creates a C code file with the embedded SQL statements converted to code using the InterBase API.
2. Be sure to include the appropriate header file, provided by InterBase, in your source file. If the source is the product of a gpre precompile, it has already been included for you. The appropriate header file for C and C++ is /usr/interbase/include/ibase.h
3. Compile the source code with the GNU compiler. For C:
cc -w -c filename.c
For C++:
c++ -w -c filename.cc
4. Link the resultant object with the runtime library image:
For shared library:
cc filename.o -o filename -lgdslib -ldl
To link your applications with the InterBase pipe library:
cc filename.o -o filename -lgds -ldl
IMPORTANT:
You must link with the pipe library if your application does its own signal handling or manipulation of the signal mask.The pipe library is used for applications which make use of POSIX signals. The InterBase lock manager uses signals to communicate with application processes. To avoid conflicting with the application’s use of signals, the pipe library isolates the InterBase signal handlers in an auxiliary process called gds_pipe. This process starts automatically and communicates with your application via a POSIX pipe.
Linux platform-specific issues
Converting other InterBase databases to Linux
InterBase databases contain architecture-dependant internal structures. You cannot move a database by simply copying the database file from a server running one operating system to a server running a different operating system.
To move a database from one platform to another, always use the gbak tool with the -transportable option, as follows:
Converting a database from later versions of InterBase might encounter issues related to recent internal database file structure features that are not recognized by the 4.0 software. It might not be possible to use gbak to migrate a database to the version 4.0 software from a more recent version.
In this case, you must use some method to migrate the data by hand. For example, write an application using the InterBase client library which attaches to both databases and copies data table by table. Another technique is to export data from the source database into InterBase external tables (see the documentation), copy the external table files to the Linux host, and import them into a database on Linux.