« AWIPS2 Home

Developer's Guide to AWIPS II on 64-bit Fedora

This guide is a walkthrough for deploying EDEX and CAVE on x86_64 Fedora Core 12 Linux. This guide follows the Unidata AWIPS II beta release built on the NCEP 14.2.1 branch of source code.

Source Code

It is assumed that you have already cloned the awips2-builds Git repository from the NWS. If not, you can use the source code included with the 14.1.1 ADE download available from collaborate2.

Shared Memory Prerequisite

Because the shared buffer definition in /awips2/data/postgresql.conf is set so high:

shared_buffers = 1536MB

the awips2-database RPM will not install correctly on fc12 x86_64 systems. To re-set the shared buffer maximum:

  1. on the command line:

    /sbin/sysctl -w kernel.shmmax=1690000000
    
  2. Edit /etc/sysctl.conf and add the line:

    kernel.shmmax=1690000000
    

    and issue the command:

    /sbin/sysctl -p /etc/sysctl.conf
    

Check the value to confirm:

cat /proc/sys/kernel/shmmax
1690000000

Install EDEX Standalone Services

Download the package awips2-14.1.1-PRELIM-NBL.tgz from collaborate2 and install the awips2-standalone group.

Ss root:

yum groupinstall awips2-standalone -y

The alternative is to deploy EDEX through the ADE, but I encountered Python errors that were too obfuscated to efficiently track, so I installed the 14.1.1 RPMs instead.

Using a 13.x Server (or Client)

The JMS connection between client and server was changed for 14.x versions, making new servers incompatible with 13.x clients (the converse of 13.x servers with 14.x clients is incompatable as well).

Start EDEX services

I use the startup program edex included in the Unidata AIWPS II beta release to make edits to service files:

edex setup
[edex] EDEX IP and Hostname Setup
 Checking /awips2/data/pg_hba.conf
      ** Missing 
 Checking /awips2/edex/bin/setup.env
      ** Missing /data_store
 Checking /awips2/httpd_pypies/etc/httpd/conf/httpd.conf
      ** Missing Group fxalpha
 Checking /etc/init.d/edex_camel
    ** ingestDat to be removed

[edit] IP address added to
       File backed up to /awips2/data/pg_hba.conf.setup_
       DATA_ARCHIVE_ROOT set to /data_store in /awips2/edex/bin/setup.env
       File backed up to /awips2/edex/bin/setup.env.setup_
[edit] Group fxalpha added to /awips2/httpd_pypies/etc/httpd/conf/httpd.conf
       File backed up to /awips2/httpd_pypies/etc/httpd/conf/httpd.conf.setup_
[edit] Removed ingestDat from /etc/init.d/edex_camel
[done]

Start EDEX:

edex start
Starting EDEX PostgreSQL:
Starting logging service:                                  [  OK  ]
Starting httpd:                                            [  OK  ]
Starting Qpid AMQP daemon:                                 [  OK  ]
Starting EDEX Camel (request): OK

I usually edit /etc/init.d/edex_camel so that only the request JVM is started, the minimum that is needed to debug CAVE in Eclipse.

ADE Setup

Do not bother using the 14.1.1 jar file for source code if you have already cloned the awips2-build repository.

Start Eclipse with a bash shell:

/bin/bash /awips2/eclipse/eclipse.sh &

Then set the following in Windows -> Preferences:

  1. PyDeV -> Python Interpreter - Do not select auto-config!

    Doing so will discover the /awips2/python libraries, but may set the default to /usr/bin/python if it exists.

  2. Java -> Installed JRE

    Make sure java (java1.6) is selected

  3. Ant -> Runtime

    Select Ant Home and set to /awips2/ant

    Select OK to close.

  4. File -> Import

    to import code, and select General -> Existing Project for each of the following directories (you'll have to do this multiple times):

    cave
    cots
    edexOsgi
    ncep
    Radarserver
    

    If you want to deploy EDEX from the ADE, also add the contents of

    ots
    
  5. Project -> Clean and confirm there are no errors. Then re-enable Build Automatically

  6. Open com.raytheon.viz.product.awips and right-click on developer.product and select Run As -> Run As Eclipse Application

  7. Enter OAX as site and click OK to launch CAVE.

Runtime Error: Check compat-libf2c

On CAVE startup the following errors occurs without the 64-bit library package compat-libf2c-34, but fc12 yum will install the 32-bit version. Therefore a RHEL6 RPM must be downloaded and installed.

The error:

An Error occured loading nsharp libraries, nsharp will not work.java.lang.UnsatisfiedLinkError: 
/awips2/repo/awips2-builds/ncep/gov.noaa.nws.ncep.ui.nsharp.linux64/libbignsharp.so: 
libg2c.so.0: cannot open shared object file: No such file or directory
at java.lang.ClassLoader$NativeLibrary.load(Native Method)
at java.lang.ClassLoader.loadLibrary0(ClassLoader.java:1807)
at java.lang.ClassLoader.loadLibrary(ClassLoader.java:1703)
at java.lang.Runtime.load0(Runtime.java:770)
at java.lang.System.load(System.java:1003)
at gov.noaa.nws.ncep.ui.nsharp.Activator.start(Activator.java:71)
...

ldd /awips2/repo/awips2-builds/ncep/gov.noaa.nws.ncep.ui.nsharp.linux64/libbignsharp.so
linux-vdso.so.1 =>  (0x00007fffee689000)
libg2c.so.0 => not found
libc.so.6 => /lib64/libc.so.6 (0x00007f7af4ed8000)
libXm.so.4 => /usr/lib64/libXm.so.4 (0x00007f7af4a0a000)
libXt.so.6 => /usr/lib64/libXt.so.6 (0x00007f7af47a5000)
libX11.so.6 => /usr/lib64/libX11.so.6 (0x00007f7af4465000)
...

as root:

yum provides libg2c.so.0

to check the package, and for Fedora 12 you will see only the i686 32-bit library to be installed in /usr/lib (you may see a 64 bit version available for other Linux distributions, if so, go with it).

The 64-bit version for RHEL6 can be downloaded from:

wget ftp://ftp.muug.mb.ca/mirror/centos/6.5/os/x86_64/Packages/compat-libf2c-34-3.4.6-19.el6.x86_64.rpm

and installed:

rpm -ivh compat-libf2c-34-3.4.6-19.el6.x86_64.rpm

Re-deploy CAVE in Eclipse and the Nsharp errors disappear.