Re: 20030505: Multiple PIPEs in pqact.conf entry?

Tim,

On second thought, my contrived example is probably not what you want if you are
catching a stream of products rather than a single product to act on. Instead,
Use the PIPE command to the script example below (without the -close option)
and set the "-t timeout" flag on dcgrib2 to something appropriate for the
period of time that dcgrib2 will wait for additional products before closeing
down (default is 600 seconds). Pqact will eventually close the PIPE as well
after a period of inactivity....but the -t option on the decoder is
generally useful if you don't want to wait for pqact to close the pipe down.

Steve Chiswell


On Mon, 5 May 2003, Steve Chiswell wrote:

>
>
> Tim,
>
> If you are PIPE'ing a specific data set to dcgrib2, then,
> you could instead use "PIPE   -close" to a shell script
> which sequentially runs dcgrib2 accepting the input from
> stdin, followed by the execution of your postprocessing commands
>
> For example, in pqact.conf:
>
> CMC   CMC_GEM_reg
>       PIPE    -close  util/cmcgribproc.csh
>
> And, in ~ldm/util/ a shell script cmcgribproc.csh can look like:
>
> #!/bin/csh -f
> source ~ldm/.cshrc
> source ~gempak/Gemenviron
>
> dcgrib2 -d $GEMDATA/logs/cmcgrib.log YYYYMMDDHH_cmc.gem && \
>    ~ldm/util/cmcpostproc.csh
>
> exit 0
>
> ##########################################################
>
>
> The script should set up the appropriate environment, including
> sourcing Gemenviron. Dcgrib2 will read from standard in. You can
> either chain together your postprocessing commands as above using "&&",
> or, follow up the dcgrib2 command with your appropriate script commands.
>
>
> Steve Chiswell
>
>
>
>
> On Mon, 5 May 2003, Tim Alberta wrote:
>
> > Hi,
> >
> > I need to execute a second script after my dcgrib2 decoder is finished.
> > The script adds some precip products to the gempak file dcgrib2
> > produced.  Is there a way to add an additional PIPE or EXEC statement to
> > my pqact.conf entry?  What is the best way to go about getting the
> > second script to run immediately after dcgrib2 has finished?
> >
> > It seems like I'm missing something really simple here, but I'm not sure
> > how to proceed.
> >
> > Thanks in advance,
> >
> > Tim Alberta
> >
>
>

  • 2003 messages navigation, sorted by:
    1. Thread
    2. Subject
    3. Author
    4. Date
    5. ↑ Table Of Contents
  • Search the ldm-users archives: