The following assumes that you are familiar with both the LDM system and with autoconf-based package-installation. If you're not, then follow the long installation instructions in the next section.
First, enable a 64-bit environment if possible. Then, do the following:
su - ldm wget https://downloads.unidata.ucar.edu/ldm/6.13.14/ldm-6.13.14.tar.gz gunzip -c ldm-6.13.14.tar.gz | pax -r '-s:/:/src/:' rm ldm-6.13.14.tar.gz # optional cd ldm-6.13.14/src export PATH=... # if necessary ./configure [--enable-logging=localn] [--localstatedir=volatile_dir] [--disable-max-size] [--with-noaaport] [--with-gribinsert] [CC=...] [CFLAGS=...] >configure.log 2>&1 make install >install.log 2>&1 sudo make root-actions make clean # optional
NOTE: If you don't have the pax(1) utility, then replace the gunzip(1) command-line with the following:
gunzip -c ldm-6.13.14.tar.gz | (mkdir -p ldm-6.13.14 && cd ldm-6.13.14 && tar -xf - && mv ldm-6.13.14 src)
The root of the installation tree will be $HOME/ldm-6.13.14
for the version-dependent
files.
If you encounter problems, then follow the long installation instructions in the next section.
Follow this advice on becoming the LDM user.
Workshop-specific instructions.
The LDM source-distribution can be obtained by clicking on the appropriate link in the LDM download page. Download the file into the LDM user's home directory.
The remaining instructions assume that the distribution was downloaded into the LDM user's home-directory.
Unpack the distribution in the LDM user's home directory into the directory
ldm-6.13.14/src
using the gunzip(1)
and pax(1)
utilities. For
example:
cd # go to the LDM user's home-directory gunzip -c ldm-6.13.14.tar.gz | pax -r '-s:/:/src/:' # unpack the distribution
NOTE: If you don't have the pax(1) utility, then replace the gunzip(1) command-line with the following:
gunzip -c ldm-6.13.14.tar.gz | (mkdir -p ldm-6.13.14 && cd ldm-6.13.14 && tar -xf - && mv ldm-6.13.14 src)
The reason for creating the additional src/
subdirectory is to allow for reversible upgrading of the
LDM. The section on activating the LDM installation provides an example.
cd $HOME/ldm-6.13.14/src
make(1)
utility
to return the distribution to a pristine state:make distcleanDon't worry if this command fails or even fails to execute.
How to set an environment variable depends on your user-shell. For example:
User Shell | Example |
---|---|
Standard UNIX (e.g. sh, ksh, bash ) |
export PATH=/usr/gnu/bin:/usr/bin:/bin |
csh -like (e.g. csh, tcsh ) |
setenv PATH /usr/gnu/bin:/usr/bin:/bin |
configure
script to customize the installation process for your
particular system. You may use the following options and arguments, when and if appropriate: --with-ulog
ulog
logging module that was standard prior to LDM version 6.12.15. When appropriate,
the ulog
module writes log messages to the
system logging daemon. Because enabling such use was the single greatest
impediment to correctly using the LDM (and for other reasons), the ulog
module has been
replaced by one that writes directly into the LDM log file when appropriate, yet still supports
LDM log file rotation.--enable-logging=localn
local0
. Note that, by default, log messages will be written directly into the LDM log
file, when appropriate, unless the previous option is specified.--localstatedir=volatile_dir
/var/ldm
) as the root directory
for highly volatile files such as the LDM product-queue,
LDM logfile, and LDM metrics files.
In general, such files should not be backed-up because of their volatility, so having the root-directory for
such files reside in a disk partition that's not backed-up is a good idea. Be aware, however, that this
directory must be on a locally mounted disk because the LDM product-queue is memory-mapped,
file-locked, and is accessed more often than free beer at a frat party. The default is
$HOME/var
.--disable-max-size
--disable-setpgid-exec
--with-noaaport
--with-gribinsert
CC=path
CC=/usr/gnu/bin/gcc
).
CPPFLAGS=
...CPPFLAGS=-UNDEBUG
).CFLAGS=
...CFLAGS=-g
).LIBS=
...LIBS="-L/opt/lib -lrpcsoc"
).Use of the above can be necessary due to the vagaries of build environments. Note that some of the computer systems can build both a 32-bit and a 64-bit LDM system. We strongly recommend that you choose a 64-bit build environment whenever possible so that the product-queue isn't unnecessarily restricted to small sizes only. Note that, by default, the configure(1) script will attempt to support a large product-queue if the C compiler is c89(1) or c99(1)).
When executing the configure
script, redirect both the standard output and standard error
streams to the file configure.log
. The relevant command depends on your user-shell.
For example:
User Shell | Example |
---|---|
Standard UNIX (e.g. sh, ksh, bash ) |
./configure ... >configure.log 2>&1 |
csh -like (e.g. csh, tcsh ) |
./configure ... >&! configure.log |
Where "...
" represents installation-specific arguments and should not be entered literally.
Inspect the file configure.log
to verify the configuration process. If an error occurred, then
the reason for the error can often be found in the file config.log
(note the slightly different
name).
If you email the UPC because of a problem with this step, be sure
to enclose the files configure.log
and config.log
.
make(1)
utility appropriate for your system to build and install the package, redirecting
both standard output and standard error to the file install.log
. The relevant command
depends on your user shell. For example:User Shell | Command |
---|---|
Standard UNIX (e.g. sh, ksh, bash ) |
make install >install.log 2>&1 |
csh -like (e.g. csh, tcsh ) |
make install >&! install.log |
Inspect the file install.log
to verify the build and installation process. If something went
wrong that you think might be fixed by setting the PATH environment variable or by
invoking the configure script differently (such as by using the cc
compiler rather than the c89
compiler) then return to the clean-up step
above.
If you email the UPC because of a problem with this step, be sure to enclose
the files configure.log
, config.log
, and install.log
.
../bin/pqcheck
. If this indicates that the product-queue
is invalid, then you must either reinstall this package -- starting with the
clean-up step above -- and specify a different programming environment via the
CC
environment variable (e.g. cc -m32
instead of cc -m64
) before
re-executing the configure
script, or you will have to remove the previous
product-queue and create a new, empty one using the programs of this
package before starting the new LDM.make root-actions
to finish the installation. For
example: sudo make root-actions
or su root -c 'make root-actions'
. Note that the last
example requires the superuser's password. If you can't execute one of these commands, then contact your systems
administrator to have them perform it.Among other things, this step is necessary for the LDM server to listen on port
388 (which is a restricted port) and for the LDM's hupsyslog(1)
utility to notify the system
logging daemon when a new log-file has been created, if appropriate.
make(1)
utility to clean-up after yourself.make clean
Click here to see what gets installed where in a canonical installation process.