Preface
The basic stages for installing jBASE 3.4 are :
1. Create an administrator account.
2. Load jBASE from the media into the administrator account.
3. Create other directories and install license required by jBASE.
4. Modify a few files.
5. Initialize the daemons.
6. Initialize the spooler.
7. Modify an existing jBASE account.
8. Test the installation.
Pre-requisites
To load jBASE on
Linux*
the following requirements must be met:
- CPU architecture: IBM PC 80386/80486/Pentium or compatible machine. A
floating point co-processor is recommended for CPUs other than Pentium or
80486DX.
- Operating system: Caldera 2.2.14, Mandrake 8.1, Red Hat Linux 7.2 &
6.2.
Including the Development system (note you have to load the kernel source
code to compile programs so you get the /usr/include headers). The installer
needs a working knowledge of Linux.
RAM: Each active jBASE user will need additional memory to run:
- approx. 0.25 Mb per active user running small applications, to approx.
0.5Mb per active user running large applications.
- For jBASE program development users, approx. 2Mb per active
user is required.
Disk space: Required disk space for the set
of jBASE programs varies depending on the platform selected. For each jBASE user, the amount of disk space
required is only about 10k per user. However, you should bear in mind that
you will need extra disk space for Spooler files and save-list's, the size
of which depends entirely upon your application.
You must have the korn shell (ksh) installed
before you install jBASE for Linux, or the installation will fail. In
addition, many of the shell scripts included in jBASE require ksh.
Unless you have purchased the AT&T version of ksh, you must download
pdksh, a korn shell clone that is in the public domain.
If you have RedHat or Mandrake, you can download the Intel
version of pdksh from this site.
For other Linux distributions and platforms, try searching for "pdksh"
on http://www.rpmfind.net
or http://rpmfind.net/linux/rpm2html/search.php?query=pdksh
Or try the pdksh home page .
Installation
Installation Advisory for jBASE 3.4 for LINUX
*This document
describes how to load jBASE 3.4 onto a system running REDHAT LINUX
release 7.2.
This advisory should serve as a suitable guideline for installation of other
Linux operating systems. However, installation to other Linux operating systems
may vary slightly. We encourage you to try jBASE for Linux on other Linux
operating systems and report your success or any problems to tech@jbase.com
.
For the purposes
of clarity, it is assumed the media is shipped on a CD. You should substitute
alternative device names if the shipped media is to be loaded from a different
device.
For information: info@jbase.com
For support: devsup@jbase.com
NOTE
Commands are written in bold, as are
commands to be written into scripts. The command line is shown as either a
#’
for the ‘root’ user or ‘
%’
for the administrative user. For the installation of the jBASE3.4 rpm
to work successfully, it is important that you take note of the differences when
entering commands.
To gain full root privileges, type
% su
– root
and then the password.
1. Create an administrator account.
There needs to
be an administrator account created to hold the jBASE files. This is set up by
the jBASE rpm file automatically. Using the tar file you must create
administrator account. The details of the account are :
Any name, but the rpm sets up 'jbaseadm'
HOME Directory:
Can be any directory but the
rpm sets up /home/jbaseadm . For the purposes of the installation advisory we
will assume it was /home/jbaseadm. If you choose a directory other than
/home/jbaseadm, simply replace the occurrences of /home/jbaseadm in this
installation advisory with the home directory you created this account
with.
Links:
The rpm will create a symbolic link from /usr/jbc to point to /home/jbaseadm.
Shell
PROGRAM: This will be set to /bin/ksh by
the rpm and is a prerequisite for jBASE. See stage 2.2 for instructions on how
to install the ksh rpm which is supplied with jBASE.
The space required in directory
/home/jbaseadm is approximately 50Mb, plus all the space required by
SAVE-LIST's, COMMON variables, etc.
2. Load jBASE from the media into the administrator
account.
The following
instructions assume that jBASE is delivered on a CD. If another form has been
supplied then you will need to replace the references to /dev/cdrom to the
device driver applicable.
2.1. Mount CD ROM drive on Unix machine (Please see your Unix
Documentation for specific instructions), generally the instructions are, as '
root' user :
#
mount /mnt/cdrom
2.2. Make sure that you have the rpm
version of ksh installed. This is on the CD or can be ftp’ed from:
ftp://ftp.jbase.com/jBASE3.4/linux/pdksh-5.2.14-2.i386.rpm
and can be installed using the
command:
#
rpm {path to CD root}/unix/linux/redhat6.2/pdksh.rpm
e.g.
#
rpm –i /mnt/cdrom/unix/linux/redhat6.2/pdksh.rpm.
2.3
Install
jBASE :
# rpm -i
{path to CD root}/unix/linux/redhat6.2/jbase34.rpm
e.g.
#
rpm -i /mnt/cdrom/unix/linux/redhat6.2/jbase34.rpm
This will create an account ‘
jbaseadm’ in the home directory with
the jbc3.4 directory in it.
2.4. You will now need to modify the
password of the ‘jbaseadm’
user.
#
passwd jbaseadm
2.4. Log in as ‘ jbaseadm’ user.
3. Create
other directories and install the license required by jBASE.
The following directory
needs to be created for jBASE.
The spooler directory.
This directory
is optional, and only required if you want to use the jBASE spooler (which is
used by all jBASE programs that output to the printer).
3.1 Create a directory called /usr/jspooler as ‘
root’. You can choose alternative names
as described in the systems administrators manual, but for now we assume you
will keep with the default. There are two ways of doing this.
A) As there is usually not enough room in
/usr/jspooler, then it is recommended that you create the directory elsewhere
and create a symbolic link to it, for example :
# mkdir /home2/jbase_spooler
# ln -s /home2/jbase_spooler /usr/jspooler
B) If you are sure that you have space then
create a real directory, for example:
# mkdir /usr/jspooler
To enable the jPML daemon to allocate the
required number of concurrent user licenses, the license key installation
procedure must be invoked. The license key installation procedure will prompt
for information provided on the jBASE license key document, which should have
been supplied with the software media. If this document is missing please
contact your jBASE supplier. A developers licence for a trial period,
can be obtained from:
http://www.jbase.com/
following the ‘linux’ links to the
‘developers licence’ page.
3.2 To install the license key perform the
following steps as ‘root’
:
# JBCRELEASEDIR=/usr/jbc
# export
JBCRELEASEDIR
# JBCGLOBALDIR=$JBCRELEASEDIR
# export
JBCGLOBALDIR
# PATH=$PATH:$JBCRELEASEDIR/bin
# export
PATH
# LD_LIBRARY_PATH=$JBCRELEASEDIR/lib:/usr/lib
# export LD_LIBRARY_PATH.
#
jInstallKey
And then type/paste in the licence code.
4. Modify a few files.
This stage
involves changing the permissions of some files and configuring the tape
drive.
4.1 As '
root' user, change the permissions of
some binaries by:
# PATH=$PATH:/usr/jbc/bin
# export
PATH
#
jsetperms
Ignore any error
messages which may appear due to the absence of the jBASEWORK and jutil_ctrl
file. These will be created when the initial jBASE process is run.
4.2 To configure the appropriate 'tape devices' for your system, the
files in the directory $HOME/jbc3.4/dev may need modification. The notes on the
layout of these files are given in $HOME/jbc3.4/dev/DEVICE_NOTES. Typically, you
will want to create a default device '0' to be referenced by the T-ATT command.
For example as ‘jbaseadm’ user:
% cd
$HOME/jbc3.4/dev
% cp SCT0
0
% vi 0
(to edit the file)
NOTE
In the above
example, you are creating a device '0' which is the default tape device. By
modifying the file, you can change the device file names to suit your
installation. A typical change may be to edit "/dev/rmt0" to "/dev/rmt0.4" and
to change "/dev/rmt0.1" to "/dev/rmt0.5". Thus, when you execute either of the
following commands after following all this Installation Advisory :
% T-ATT
0
%
T-ATT
the tape will be
attached according to the options specified in file in '/usr/jbc/dev/0'.
Similarly, you may wish to copy file '/usr/jbc/dev/SCT0' to file
'/usr/jbc/dev/1', and change references "/dev/rmt0" to "/dev/rmt1" and
"/dev/rmt0.1" to "/dev/rmt1.1". This will enable use of the second tape drive on
your Linux system with the following command :
% T-ATT
1
The directory '/usr/jbc/dev' can contain ANY
number of device descriptors, each one being referenced during the T-ATT command
with the name of the file in the '/usr/jbc/dev' directory.
5. Initialize the spooler
5.1 The spooler directories can be created by the user ‘
root’. We shall assume the directory
'/usr/jspooler' was created as per step 3.1 ignoring any errors due to
'/usr/jspooler' already existing.
# PATH=$PATH:/usr/jbc/bin
# export
PATH
#
export LD_LIBRARY_PATH=/usr/jbc/lib:$LD_LIBRARY_PATH
# :SP-NEWTAB
Follow the on
screen instructions. The options allow selection of the permissions given to
Spool jobs created by jBASE programs. In almost all cases, you can safely accept
the defaults by entering 'C' ( to 'Continue' ).
6. Initialize the printer daemon.
The printer daemon command :
REST-SPOOLER can be added to the
jDEMON.init.d script, if required, in order to automatically restart the spooler
queue after reboot. As ‘root’:
6.1. Change to the src directory:
# cd /usr/jbc/src
6.2. Edit the jDEMON.init.d file adding the
following to the start of the script:
echo
Starting jBASE spooler jobs
( PATH=/usr/jbc/bin:$PATH
; :REST-SPOOLER ) >/dev/console 2>&1
NOTE
The program
:REST-SPOOLER is an optional startup program, and will start the print spooler
daemons for EACH form queue that is defined as an active queue.
An alternative
mechanism is to create an entirely new script with the commands in and add the
script to the /etc/inittab file.
In all cases you
should direct stdout and stderr to /dev/console to ensure the program output is
directed to the console.
7. Modify a New/Existing user for jBASE.
To automatically set up a jBASE account
To make a jBASE account, the 'IJU'
utility is provided to incorporate essential environment variables into the
existing '.profile' in the home directory.
7.1. First you
should create a new user. As ‘root’
# useradd –m –s
/bin/ksh jbaseuser
7.2 modify the
password of ‘jbaseuser’
#
passwd jbaseuser
7.3. login as
‘jbaseuser’ and execute 'IJU'
:
% export PATH=$PATH:/usr/jbc/bin
.
%
IJU
and follow the
prompts. IJU appends a ‘.profile’ script to the existing ‘.profile’ script in
your home directory.
7.4 Ammend the
‘.profile’ script in the ‘jbaseuser’ home directory by deleting the following
line:
stty quit ^- dsusp ^- susp ^-
7.4 If you are using the BASH shell however, you should add the
following code to the ‘.bash_profile’
script in your home directory.
if [ -f ~/.profile ]; then
. ~/.profile
fi
This will
execute the jBASE ‘.profile’ script. You should then log off and back on again to make
the changes effective.
To manually set up a jBASE account.
You can manually
make an existing Linux account into a jBASE user. Basically, all that is needed
to run a jBASE program is to set up the PATH environment variable, for example
:
% PATH=$PATH:/usr/jbc/bin
% export
PATH
When a jBASE
program is first run on an account, it "connects" to the jPML daemon and when
finished it disconnects, giving the disconnection message. Your login process
can be left permanently connected to jBASE using the following commands
:
% JBCCONNECT=`/usr/jbc/bin/jbcconnect`
% export
JBCCONNECT
These actions
would normally be performed in the .profile file associated with the
account.
Further
Environment variables can be set in the .profile to control your jBASE
environment. These additional Environment variables include:
Environment variables
JBCEMULATE
: Set this to ROS if coming from an MDIS Reality environment, for example:
% JBCEMULATE=ROS
% export
JBCEMULATE
JBCPORTNO
: Set this to an absolute port number to prevent
jBASE
dynamically allocating a port
number.
JBCLOGNAME
: Set this to the jBASE account name user, otherwise jBASE will use the
Linux login name as the account name.
Further examples can be found in the '/usr/jbc/src/profile.ksh' file.
NOTE
The use of an MD
(or VOC) file is optional in jBASE. The 'MD' file is required for implementing
'Q pointers' and PQ/PQN 'Procs'. To create a 'MD' ( or 'VOC' ) file
perform the following stages :
To set up the
MD:
% CREATE-FILE DICT MD
23,1
% JEDIFILENAME_MD=./MD
% export
JEDIFILENAME_MD
%
UpdateMD
8. Test the installation.
The installation
of jBASE is now complete. To test the installation, you can try the following
from the account updated in stage 7).
8.1 Try the jBASE shell.
(You
need to be in the bash or ksh do execute this command)
% jsh -s jsh -c"LIST .
EQ ‘.]’"
8.2 Try to create a simple source and compile
it.
% CREATE-FILE TESTBP 1
1
% ED TESTBP
MYPROG
New
Record
MYPROG
TOP
.I
<rtn>
000+PRINT "Hello,
world"
000+
<rtn>
.FI
<rtn>
Record 'MYPROG' written
to file 'TESTBP'
% BASIC TESTBP
MYPROG
% CATALOG TESTBP
MYPROG
%
MYPROG
Hello,
world
8.3 Try the jQL language.
% COUNT
.
% LIST
.
% SORT
.
% SELECT
.
8.1 Try the spooler.
%
SP-JOBS
The installation
of jBASE is now complete.