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: DENNIS WILLIAMS <DWILLIAMS_at_LIFETOUCH.COM>
Date: Thu, 29 Nov 2001 14:25:20 -0800
Message-ID: <F001.003D131C.20011129141031@fatcity.com>

Kevin

        One thing you mentioned concerned me, the "CSH and not for KSH". I assume you are referring to Unix C shell and Korn shell script languages. I don't know if this is your problem, but I wanted to make the following points:
1. The #! /bin/ksh mentioned earlier will make sure the script is running in Korn shell, rather than whatever it inherits from the parent. 2. C shell and Korn shell are unfortunately very similar but differ in insidious ways. I recently spent an uncomfortable Sunday evening debugging a script and the error hinged on a subtle difference. It wasn't even my script! Arrg!
3. I would avoid using C shell scripts. Borne shell was the original scripting language, and C shell was developed to add better interactive features. Then Korn shell was created, which is basically Borne shell with those interactive features.
Dennis Williams
DBA
Lifetouch, Inc.
dwilliams_at_lifetouch.com

-----Original Message-----
Sent: Thursday, November 29, 2001 3:00 AM To: Multiple recipients of list ORACLE-L

Thanks David, and everyone else for all your help.

Unfortunately, I've done all this, specifying the variables etc and it still doesn't appear to like it much! I don't know whether it's because it's written in the CSH and not for KSH...I'll keep looking.

Thanks again,
Kev.

"Some mornings it just doesn't seem worth it to gnaw through the leather straps."


Kevin Thomas
Technical Analyst
Deregulation Services
Calanais Ltd.
(2nd Floor East - Weirs Building)

Tel: 0141 568 2377
Fax: 0141 568 2366
http://www.calanais.com

-----Original Message-----
[mailto:DBarbour_at_austin.isd.tenet.edu]
Sent: 28 November 2001 21:21
To: Multiple recipients of list ORACLE-L

Thomas,

I got called to task before on this, but I didn't save the note, so whoever corrected me, please do so again. In any case, cron jobs in UNIX are (and this is where I was corrected - although what follows should solve your problem) executed by root. This is why Mike suggested running the .profile to properly set up the environment to find and execute sqlplus. The user who "owns" the cron job is invoked by root without all the proper environmental variables set. As an alternative you can explicitly set your variables at the beginning of the shell script as follows (for ksh):

#!/bin/ksh

export ORACLE_SID=ifas
export ORACLE_HOME=/u001/app/oracle/product/8.1.7 export PATH=$PATH:/u001/app/oracle/product/8.1.7/bin export ORACLE_BASE=/u001/app/oracle
export HOME=$ORACLE_HOME
cd $HOME

Hope this helps.

David A. Barbour
Oracle DBA, OCP
AISD
512-414-1002  

                    "Thomas, Kevin"

                    <Kevin.Thomas_at_cal       To:     Multiple recipients of
list ORACLE-L <ORACLE-L_at_fatcity.com>  
                    anais.com>              cc:

                    Sent by:                Subject:     Crontabs and Oracle

                    root_at_fatcity.com

 

 

                    11/28/2001 05:00

                    AM

                    Please respond to

                    ORACLE-L

 

 





Guys,

I have a Unix shell script that runs and does some things with sqlplus. The script runs fine when I start it up manually just using the command

$ host_startup.sh

However, If I try to start this host_startup.sh from the Crontab I get this error logged in my mail.

>From apt2 Wed Nov 28 08:15:01 2001
Date: Wed, 28 Nov 2001 08:15:01 GMT
Message-Id: <200111280815.IAA24337_at_phys-ki-sun4k2.scottishpower.plc.uk> To: apt2
Content-Length: 143

Your "cron" job on phys-ki-sun4k2
/ki-sun4k2/export/home/apt2/ta_web/host/host_startup.sh

produced the following output:

sqlplus: Command not found

Any ideas? I've specifically said in the shell script where to find the sqlplus binaries, so I'm not sure?! Any help would be much appreciated.

Cheers,
Kev.

"I put instant coffee in a microwave oven and almost went back in time. "


Kevin Thomas
Technical Analyst
Deregulation Services
Calanais Ltd.
(2nd Floor East - Weirs Building)

Tel: 0141 568 2377
Fax: 0141 568 2366
http://www.calanais.com

-----Original Message-----
Sent: 21 November 2001 12:20
To: Multiple recipients of list ORACLE-L

Have a look at Categoric Xalerts.

It is a general purpose Alerting system, not just for DBA and SYSADMs.

Their new Java based system is just out.

www.categoric.com

Steve Parker
Technical Consultant
LIS



Logistics & Internet Systems Ltd.
E Mail: steve.parker_at_lis.co.uk
                    Kumanan Balasundaram

                    <kumanan.balasundara       To:     Multiple recipients
of list ORACLE-L <ORACLE-L_at_fatcity.com>
                    m_at_qxl.com>                 cc:

                    Sent by:                   Subject:     Reliable
alerting system that is not so costly??
                    root_at_fatcity.com





                    21/11/2001 11:50

                    Please respond to

                    ORACLE-L









Hi there,

Any of you using or have come across a reliable alert system that can also escalate
to different persons based on criteria such as how important that system is?

We are looking to invest in such a software.

Kumanan Balasundaram
Database Administrator, IT
QXL ricardo plc
www.qxl.com
P: +44 (0)208 962 7409

> QXL ricardo plc Registered Office Landmark House, Hammersmith Bridge Road,

> London W6 9EJ
> Registered in England No 3430894 VAT number - GB 701 8915 43
>
> The information transmitted is intended only for the person or entity to
> which it is addressed and may contain confidential and/or privileged
> material.  Any review, retransmission, dissemination or other use of, or
> taking of any action in reliance upon, this information by persons or
> entities other than the intended recipient is prohibited.   If you
> received  this in error, please contact the sender and delete the
material
> from any computer
>

This email and any files transmitted with it are confidential and intended solely for the use of the individual or entity to whom they are addressed. If you have received this email in error please notify postmaster_at_qxl.com

This footnote also confirms that this email message has been swept by MIMEsweeper, Sophos and Nortons Anti-Virus, for the presence of computer viruses.


--
Please see the official ORACLE-L FAQ: http://www.orafaq.com
--
Author: Kumanan Balasundaram
  INET: kumanan.balasundaram_at_qxl.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: Steve.Parker_at_lis.co.uk 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: Thomas, Kevin INET: Kevin.Thomas_at_calanais.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: DBarbour_at_austin.isd.tenet.edu 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: Thomas, Kevin INET: Kevin.Thomas_at_calanais.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: DENNIS WILLIAMS INET: DWILLIAMS_at_LIFETOUCH.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 Thu Nov 29 2001 - 16:25:20 CST

Original text of this message

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