tru64-unix-managers (formerly alpha-osf-managers) (1994-2012)
 help / color / mirror / Atom feed
From: JC Faul <jfaul () mtc ! com ! na>
To: tru64-unix-managers
Subject: UPDATE: SUMMARY: Crontab Entry
Date: Fri, 30 Nov 2001 10:54:40 +0000	[thread overview]
Message-ID: <102653643322006.tru64-unix-managers.marc@archive.invalid> (raw)

For all the Kornshell/scripting newbies like me,  thought you
might be interested in what the doctor prescribed.

|Your script wants to use a parameter of some kind called DATA, and
|you have it defined as an environment variable in your interactive
|command line environment, but the shell that's running your cron
|job does NOT read all of your interactive login startup scripts (it
|may not even be the shell you normally use, so you might not have
|your environment set up right if you changed your shell).  You have
|to have your script establish the right environment.  One way to 
|get all of your stuff out is to use "printenv" to print all of
|your interactive environment variables into a file, then edit the
|file to put them into a "source-able" format for the shell that
|you like to use in your scripts, and then read it at the start of
|your cron job.   Alternatively, you could write a wrapper script
|that establishes the equivalent of your interactive environment
|and then invokes its first argument passing the rest of the args
|to that script.  There are LOTS of ways to do this.  

|Welcome to how "cron" really works.

|Tom

                 reply	other threads:[~2001-11-30 10:54 UTC|newest]

Thread overview: [no followups] expand[flat|nested]  mbox.gz  Atom feed
read-only archive

This is a public inbox, see mirroring instructions
for how to clone and mirror all data and code used for this inbox