Oracle FAQ Your Portal to the Oracle Knowledge Grid
HOME | ASK QUESTION | ADD INFO | SEARCH | E-MAIL US
 

Home -> Community -> Mailing Lists -> Oracle-L -> Re: Crontabs and Oracle

Re: Crontabs and Oracle

From: <Jared.Still_at_radisys.com>
Date: Fri, 30 Nov 2001 09:53:34 -0800
Message-ID: <F001.003D216A.20011130094019@fatcity.com>

Tim,

Sourcing .profile may be the 'right' thing to do technically, but I suppose it really hinges on the environment.

If it works as is, then fine. If not, changing .profile and/or .kshrc may not be an option.

In a medium to large shop, changing the .profile or .kshrc can be rather dangerous, even with proper change control procedures in place.

It might be a few weeks before it bites you when that report that runs once a quarter suddenly hangs or quits working.

Jared

                                                                                       
                             
                    Tim Bunce                                                          
                             
                    <Tim.Bunce_at_pob       To:     Multiple recipients of list ORACLE-L 
<ORACLE-L_at_fatcity.com>        
                    ox.com>              cc:                                           
                             
                    Sent by:             Subject:     Re: Crontabs and Oracle          
                             
                    root_at_fatcity.c                                                     
                             
                    om                                                                 
                             
                                                                                       
                             
                                                                                       
                             
                    11/30/01 02:35                                                     
                             
                    AM                                                                 
                             
                    Please respond                                                     
                             
                    to ORACLE-L                                                        
                             
                                                                                       
                             
                                                                                       
                             




On Thu, Nov 29, 2001 at 11:15:43AM -0800, Jared.Still_at_radisys.com wrote:
>
> I've seen a number of suggestions for sourcing .profile
> in the cron jobs, but this is not always a good idea, as
> .profile often contains script that will not execute when
> not attached to a tty.

I think sourcing .profile is the 'right' thing to do.

If that breaks then the .profile needs fixing as it'll probably also break things like rsh/rcp etc.

I've seen both these code sytles used (for sh/ksh/bash etc):

    if [ "$PS1" ]
    then

               ... interactive stuff here ...     fi

or

    case $- in
    *i*)

               ... commands for an interactive shell here ...
               ;;
    *)      ;;

    esac

Tim.

--
Please see the official ORACLE-L FAQ: http://www.orafaq.com
--
Author: Tim Bunce
  INET: Tim.Bunce_at_pobox.com

Fat City Network Services    -- (858) 538-5051  FAX: (858) 538-5051
San Diego, California        -- Public Internet access / Mailing Lists
--------------------------------------------------------------------
To REMOVE yourself from this mailing list, send an E-Mail message
to: ListGuru_at_fatcity.com (note EXACT spelling of 'ListGuru') and in
the message BODY, include a line containing: UNSUB ORACLE-L
(or the name of mailing list you want to be removed from).  You may
also send the HELP command for other information (like subscribing).




-- 
Please see the official ORACLE-L FAQ: http://www.orafaq.com
-- 
Author: 
  INET: Jared.Still_at_radisys.com

Fat City Network Services    -- (858) 538-5051  FAX: (858) 538-5051
San Diego, California        -- Public Internet access / Mailing Lists
--------------------------------------------------------------------
To REMOVE yourself from this mailing list, send an E-Mail message
to: ListGuru_at_fatcity.com (note EXACT spelling of 'ListGuru') and in
the message BODY, include a line containing: UNSUB ORACLE-L
(or the name of mailing list you want to be removed from).  You may
also send the HELP command for other information (like subscribing).
Received on Fri Nov 30 2001 - 11:53:34 CST

Original text of this message

HOME | ASK QUESTION | ADD INFO | SEARCH | E-MAIL US