FairCom Corporation
 
FairCom Start PageFairCom ProductsDownloadsDeveloper SupportSales InformationFairCom CustomersFairCom Company InformationContact FairCom

Homebulletgrey.gifeNewsletterbulletgrey.gifVolume 30 bulletgrey.gifTech Tip: SIGNAL_DOWN


Let c-treeACE Phone Home for Help

A frequent request we hear from administrators is an ability to be notified upon certain events from the server. One of the most important events is to know when the c-treeACE process has halted. Consider the case when a disk volume runs out of space and the server must come down to protect data integrity. For continuous operations, it is important for an administrator to be actively notified and take action.

c-treeACE has two configuration options available to execute specified actions upon server startup and shutdown:

SIGNAL_READY <executable script>
SIGNAL_DOWN  <executable script>

Consider using these keywords for tasks that need to be completed once c-treeACE is up and running, or after c-treeACE shuts down.

A useful application of the SIGNAL_DOWN keyword is to send a notification, for example via email or SMS message to a text pager, should you want to know if your server is no longer active. As the SIGNAL_DOWN keyword is called even in the event of an abnormal server termination, it is a great way for c-treeACE to attempt to call out for assistance.

The following example is a simple script to notify a c-treeACE Administrator of a server shutdown event. It also attempts to restart the server, and to avoid an infinite retry loop, configured to only try three restart attempts before aborting. The SIGNAL_READY keyword is used to clear the restarts file on a successful restart.

This is only a brief example of what can be done. Other uses could include kicking off application scripts on server startup, and system maintenance routines on server shutdown.

Example Configuration

You will need to add the configuration keywords as in the following server configuration example.

ctsrvr_signals.cfg

Example Scripts

The following Linux Bash scripts assume a properly configured sendmail process on your environment. These can be readily tailored for nearly any platform, however. Always be mindful of appropriate security measures when taking actions such as these with proper permissions and such.

Note: The executable scripts must be located in the same directory as the server executable.

signal_down.sh

signal_ready.sh

Microsiga Software is a Brazilian Company specializing in technology and systems development for enterprise management, with its sole focus on the corporate sector. With over 20 years of proven technology and services, Microsiga is the undisputed market leader in Brazil and a key player in other Latin American countries. One of the main factors that contribute to Microsiga's ongoing success is that they offer products and solutions to companies of all sizes in all market segments. Microsiga integrates FairCom as one of the database partners. Microsiga has chosen FairCom due to its flexibility, portability, reliability, and performance..

FairCom is the only database available for use on Unix platforms (including Linux) for the control of the data dictionary, and it is now the default database for Windows as well. Microsiga and FairCom worked closely for over a year on a number of aspects related to the Advanced Protheus project, including the integration of Microsiga's application server and the c-tree Server into a single executable, allowing for unprecedented scalability.

Read More... (860KB PDF)

FairCom Start PageSite MapContact FairComThe FairCom Privacy Policy Your Location: USA | Europe | Brazil | Japan
Copyright 2012 FairCom Corporation. All rights reserved.