GNC-A Blog Content – March 2020

Blog Content

Hi GEONETCasters,

As requested by the Blog Readers, please find bellow a summary of the Blog content:

==== WHAT IS GEONETCAST-AMERICAS ====

“What is GEONETCast-Americas?” Series:

==== GNC-A STATION INSTALLATION AND MAINTENANCE ====

GNC-A Station Hardware and Software Tutorial Series:

==== GEONETCAST-AMERICAS CONTENT ====

GEONETCast-Americas Product Additions and Announcements:

“GEONETCast-Americas Imagery of the Day” Series:

==== GEONETCAST-AMERICAS PRODUCT MANIPULATION ====

SHOWCast Series:

GOES-16 and Python Tutorial Series:

Using Basemap:

Using Cartopy:

GNC-A and Python Tutorials and Scripting Examples:

Miscellaneous Tutorials and Scripting examples:

==== THE GEONETCAST-AMERICAS GREAT COMMUNITY ====

“GNC-A User Study Cases”:

“GNC-A Community Map” Series:

“New Operational GNC-A Station” Series:

“Products Generated by the Community” Series:

==== GNC-A BLOG / OUTREACH / SUPPORT ====

GNC-A User Group Webinars:

GNC-A Blog Community Reach:

GEONETCast-Americas Related Events:

GEONETCast-Americas Notifications:

==== NICE THINGS! ====

Updated at March 12, 2020 13:30 UTC

Cleaning the FAZZT “kdt” directory

Hi GNC-A’ers,

The FAZZT Client stores temporary data on an specific directory called “kdt”. While the data is being received, it is stored there, and when the reception is finished, it is moved to the permanent storage directory (e.g.: “GOES-R-CMI-Imagery/Band13”).

However, when, for some reason, there is an error on the reception and the data is incomplete, the temporary file stays there forever. It is a good practice to automatically erase this folder, so your directory does not become full (also, check why incomplete files are happening! Check here).

Let’s see how to clean the kdt directory automatically with cron.

1-) Check where your FAZZT temporary directory is:

On the FAZZT interface, go to “Configuration” -> “Storage Settings” and check the “Temp Directory” and the “Temporat Storage Directory”, like o the image below:

Screenshot-Fazzt Administration (paraiba.cptec.inpe.br) - Mozilla Firefox

On the example above, the kdt directory is found at: /var/tmp/fazzt/kdt

2-) Create a script called “clean_kdt.sh” (for example) with the following code:

#!/bin/csh -x
echo "****Cleaning FAZZT KDT - Started****"
echo `date`
find /var/tmp/fazzt/kdt -mtime +1 -exec rm -f {} \;
echo `date`
echo "****Cleaning FAZZT KDT - Finished****"

Save the clean_kdt.sh script whenever you want (on this example “/data/scripts”)

3-) Change your script permissions:

chmod +x *

4-) Add the script to your cron, to be executed daily:

To edit your crontab (using vi on this example):

crontab -e

To switch to input mode, in order to add and edit text:

i

You should see — INSERT — on the lower part of the window.

Add a new line to your cron, to execute the “clean_kdt.sh” daily, at midnight:

0 0 * * * /data/scripts/clean_kdt.sh > /data/scripts/clean_kdt.log 2>&1

Pres ESC to quit the crontab edition mode (the — INSERT — text will disappear) and save the edition you made with:

:wq

You will see the following:

crontab: installing new crontab

Your KDT directory will be cleaned daily, at midnight, and the instruction to clear the directory will be looged on /data/scripts/clean_kdt.log