Skip Navigation Links www.nws.noaa.gov 
NOAA logo - Click to go to the NOAA home page National Weather Service   NWS logo - Click to go to the NWS home page
Climate Prediction Center
 
 

 
About Us
   Our Mission
   Who We Are

Contact Us
   CPC Information
   CPC Web Team

 
HOME > Monitoring_and_Data > Oceanic and Atmospheric Data > Reanalysis: Atmospheric Data > wgrib2-flush
 

wgrib2: -flush

Introduction

In the normal scheme, output is buffered. That means the output is saved a memory buffer and only flushed (written out) when the buffer is full or the program ends. This normal scheme saves time when wgrib2 is writtng to disk files. This scheme fails when wgrib2 is writing to a pipe and another program is reading from that pipe. When wgrib2 is writting to a pipe, the output should flushed so that the process does not stall.

The -flush option causes wgrib2 to flush the output buffers after every write. This option is now rarely used because wgrib2 internally sets the flush option on when detects a write to a pipe. The only current need for the -flush option is when another program is reading the disk file that is being written by wgrib2. In this case, you would use this option to ensure that the disk file is written as soon as possible.

Usage

-flush

NOAA/ National Weather Service
National Centers for Environmental Prediction
Climate Prediction Center
5830 University Research Court
College Park, Maryland 20740
Climate Prediction Center Web Team
Page last modified: Oct 6, 2017
Disclaimer Privacy Policy