(content link) weather.gov    
NOAA link
National Weather Service
  NWS link
National Operational Hydrologic
Remote Sensing Center

NOHRSC Technology > NOHRSC GIS Applications

NOHRSC Software with PostgreSQL -
System Requirements and Installation

The following is documentation for the installation of NOHRSC's Integrated Hydrologic Automated Basin Boundary System (IHABBS) and Unit Hydrograph (UHG) on a system with no prior version present.

System Requirements

  • PostgreSQL 7?+ with Linux
  • Postgres runtime libraries located in /opt/postgres
    If the Postgres runtime libraries are located elsewhere such as /usr/postgres, creating a /opt/postgres symbolic link to the appropriate location will alleviate this.
  • The Linux kernel should have the most recent system patches.
  • Standard Motif 1.2 runtime libraries
  • Space needed for installation: ..... (size of Depression-filled DEM) * 20
    This space reflects the space needed for the executables and the larger raster data files.
  • Total space needed: .................(size of Depression-filled DEM) * 40
    This assumes that the user will be altering and creating multiple new flow direction layers and multiple basin layers. The total is usually around 1 GB for a moderate-sized River Forecasting Center region.


In a 24-bit read-only color setting, as is often in Linux, the DISPLAY environment variable should be set to the workstation.

IHABBS Version 3.18+ Complete Install for Postgres

February 21, 2006

The following documentation is an aid for the installation of NOHRSC's Integrated Hydrologic Automated Basin Boundary System (IHABBS) and Unit Hydrograph (UHG). Below are step-by-step instructions for creating the database and IHABBS environment. When these steps are complete, data layers can be loaded into IHABBS using the NOHRSC Database Administration utility. Please contact Anders Nilsson at NOHRSC, (952) 368-2517 or email , after implementing this step-by-step process.

  1. Download the following four files and put them into the same directory:

    1. nohrsc_docs.tar.gz
    2. nohrsc_executables.tar.gz
    3. nohrsc_static_layers.tar.gz
    4. and layers specific to your region from:

  2. Uncompress the files by using the following:

       tar xvzf nohrsc_pg_docs.tar.gz
       tar xvzf nohrsc_pg_executables.tar.gz
       tar xvzf nohrsc_static_layers.tar.gz
       tar xvzf XXrfc_layers.tar.gz

    These will create an "install" directory, and fill it with files.

  3. Next, some environment variables have to be set for the rest of the installation process. These variables will also need to be set in the shell before a NOHRSC application can be run. Some RFCs define these variables in the user's profiles (files such as .profile, .appsdefaults, or .bashrc), while others place these in a script which then calls the nohrsc launcher. The general PATH environment variable will also need to have the directory containing the executables in it (described below).

    File path info:

    export GISRS_HOME=
    a parent master directory into which IHABBS-related subdirectories will be placed.
    a parent directory into which static "common" data (State outlines, county boundaries, etc...) will be placed. (This is often the same as $GISRS_HOME)
    export GISRS_BASIN_DATA=
    a parent directory into which IHABBS static data (flow accumulation grids) and more dynamic data (basin vectors) will be placed. (This is often the same as $GISRS_COMMON_DATA)
    export GISRS_ARCHIVE=
    a directory to contain archived and shared layers (and often installation packages) (This is often $GISRS_HOME/archive)
    an already-created directory to contain scratch files. Preferably located on a local disk (akin to /tmp). This directory should have 1 GB free. If there are no available local disks, leave this environment variable undefined.
    export IHABBS=
    a directory to contain all the binary executables (This is often $GISRS_HOME/bin)
    export PATH=$PATH:$IHABBS

    Database info:

    export PGHOST=
    ( the name of the database machine)
    export PGUSER=ihabbs
    export GISRS_DATABASE=
    ( the name of the database that you wish to use ) (This can be gisrs)
    export GISRS_SCHEMA=
    ( the name of the database schema/search_path that you wish to use ) ( This can be the default schema name, like "public", ( or a name of a schema which can be created below, like "gisrs". )

    Misc. Preferences:

    (duration in seconds for an overly long database transaction)
    (duration after which, if a file size has not changed, it is assumedly finished copying)
    (Maximum percentage size of a compressed raster. A value of 100 means that the programs will compress a raster file if the compressed file is smaller than the original file)
  4. Database Setup

    Once these variables are set, the database and the database use $PGUSER can be created using an database administrator account. The database creation step is shown below. More in-depth discussion on Postgres database setup can be found here.

    If you have PostgreSQL version 8+, you can specify a tablespace in which to put the database using the following:

       psql template1 << NOHRSC
       create database $GISRS_DATABASE tablespace tablespace ;
       grant temporary on database $GISRS_DATABASE to $PGUSER ;

    However, AWIPS machinery currently is installed with a version less than 8 (7.4.7). So, in those circumstances, you can create the database (and place it in an already created area PGDATA_LOCAL) using the following:

       psql template1 << NOHRSC
       create database $GISRS_DATABASE with location = 'PGDATA_LOCAL' ;
       grant temporary on database $GISRS_DATABASE to $PGUSER ;

    For either version, if a schema other than the default (most likely "public") is to be used by IHABBS, it can be created by the following:

       create schema $GISRS_SCHEMA ;
       grant usage on schema $GISRS_SCHEMA to $PGUSER ;
       grant create on schema $GISRS_SCHEMA to $PGUSER ;
  5. Once the database and schema has been created, run the following three scripts:


    (This will create the directories specified by the environment variables.)


    (This will move the executables and the documentation to their places. This will also update the nohrsc.cfg configuration file with the values specified in the environment variables.)


    (This will create tables within the newly created database, and then populate it with restored layers.)

Documents and Programs

This is a minimum listing of what should be in the <BIN> directory.

Export.hlp - Help file for the "Export" application
ihabbs.hlp - Help file for the IHABBS application
nohrsc.cfg - Generic configuration file used by all apps: nohrsc, Export, uhg and ihabbs. This file can either be located in the <BIN> directory, or in a local directory from which the user runs the nohrsc launcher. This file will probably need to be edited to reflect different GIS data layers.
nohrsc.hlp - Help file for the nohrsc toolbar application
uhg.hlp - Help file for the unit hydrograph application

nohrsc - Command toolbar which launches other applications and manages X color allocation on 8-bit displays
Export - GIS layer exporting program called by the nohrsc toolbar
NOHRSC_systems - Database administration program called by the nohrsc toolbar
uhg - Unit Hydrograph application, called by the nohrsc toolbar
ihabbs - IHABBS, or Integrated Hydrologic Automated Basin Boundary System, called by the nohrsc toolbar

Obsolete executables for HP-UX can be foud in this directory.

Mission Statement  |  Contact

National Weather Service
National Operational Hydrologic Remote Sensing Center
Office of Water Prediction
1735 Lake Drive W.
Chanhassen, MN 55317

NOHRSC homepage
Contact NOHRSC
Information Quality
Page last modified: Apr 24, 2023 - cloud
About Us
Privacy Policy
Career Opportunities