#! /bin/bash
cyflexlogevent -t generic -m 1 -m "script" -m "$0" 

# This script starts the external data manager for weather data loading.
#
# The main feature is that this insures that only one instance at a time
# is running.  If an instance is already running, it will be killed and
# a new instance started.
#
# Usage: /cyflex/cmds/start_weather_loading
#
# Author: Rob Janes
# 
# History
#   01/16/14 - Rob Janes - Initial release.

# If this is already running, terminate it.
stop_weather_loading

# Start the weather loading application up.
DATE=`date +"%y%m%d"`
exec extdatman.cummins.weather >> /data/errors/extdatman.weather.$DATE 2>&1 &
