oracle cron script failing.


 
Thread Tools Search this Thread
Operating Systems Solaris oracle cron script failing.
# 1  
Old 06-22-2011
oracle cron script failing.

I have this oracle script which my dba is trying to run as a cron job that fails. attached is the script. It seems to run when executed by itself but just not when scheduled.
# 2  
Old 06-22-2011
For starters, take a look at this FAQ.
Secondly, make sure that #!/bin/bash appears as the FIRST line in your script.
This User Gave Thanks to vgersh99 For This Post:
# 3  
Old 06-22-2011
bash in solaris is in /usr/bin not /bin.. and as vgersh99 mentioned should be shabang should be the first line.
Code:
#!/usr/bin/bash

# 4  
Old 06-22-2011
Quote:
Originally Posted by tamitot
bash in solaris is in /usr/bin not /bin.. and as vgersh99 mentioned should be shabang should be the first line.
Code:
#!/usr/bin/bash

Actually, it's either/or - it's in both places on Sol9.
Login or Register to Ask a Question

Previous Thread | Next Thread

10 More Discussions You Might Find Interesting

1. UNIX for Dummies Questions & Answers

Crontab script failing

Hello, A crontab script is failiing everyday but when we execute manually it runs fine Below is the script scheduled: 00 23 * * * sh /db2backup/scripts/db2_hot_backup.ksh TRAVFF > /dev/null 2>&1 Error: cat TRAVFF_online_04022014_2300.log Started : Wed Apr 2 23:00:00 EDT 2014... (2 Replies)
Discussion started by: Vishal_dba
2 Replies

2. UNIX for Dummies Questions & Answers

Script test failing

Testing some old script developed by different user. #!/usr/bin/sh case "$0" in */*) cmd="$0";; *) cmd=`which "$0"`;; esac dir=`dirname "$cmd"` node="$dir/." echo $node below two simple tests are failing, I am not seeing any Control+M characters in the script file and I am not able... (4 Replies)
Discussion started by: srimitta
4 Replies

3. Shell Programming and Scripting

Expect script help needed- script failing if router unavailable

Hey all. Sometimes I'm tasked to change some router configs for the entire network (over 3,000 Cisco routers). Most of the time its a global config parameter so its done with a loop and an IP list as its the same configuration change for all routers. This is working OK. However, sometimes an... (3 Replies)
Discussion started by: mrkz1974
3 Replies

4. Shell Programming and Scripting

calling expect script in ksh is failing via cron

I'm calling an expect script via a ksh script in cron and it is failing. The script runs fine if i run it manually. Does anyone know if it is an issue with compatibilty and if there is a way around it? (2 Replies)
Discussion started by: bhatia
2 Replies

5. UNIX for Dummies Questions & Answers

Notification of cron failing

I have just found out that a cron i set up to run everyday has not been running. It turns out there was a problem with the box??? How can i get a notification if it does absolutely nothing i.e. an email to say cron not working today?? any help I'm using KSH Solaris (3 Replies)
Discussion started by: Pablo_beezo
3 Replies

6. UNIX for Dummies Questions & Answers

failing a unix script

i am basically DWH professional. I want to write a script such that whenver the file size is greather than 0 the script fails plz help me in this (1 Reply)
Discussion started by: er_zeeshan05
1 Replies

7. UNIX for Dummies Questions & Answers

Oracle Apps Cron Job

Hi, I have created a shell script which will ftp a file from my Oracle DB server to a remote server - I've named this ftp_test.sh. I have set up a cron job to fire off the shell script and when I set the job I get a message returned that the job has been installed and everything seems o.k.... (1 Reply)
Discussion started by: cjhall01
1 Replies

8. Shell Programming and Scripting

using Oracle with Cron

Greetings, I am doing some work on using Oracle with Cron and was wondering if you could help. I am relatively new both to Oracle and Unix. Please be patient :-) Here is what I am trying to do: I wish to know the contents of employees table in scott account everyday at 11 am, save a copy... (4 Replies)
Discussion started by: alikun
4 Replies

9. UNIX for Dummies Questions & Answers

Having A Problem Connecting to Oracle Using Cron

Can someone tell me how to prevent this? stty: standard input: Invalid argument ERROR: ORA-12154: TNS:could not resolve the connect identifier specified SP2-0306: Invalid option. Usage: CONN where <logon> ::= <username> | / ERROR: ORA-12162: TNS:net service name is incorrectly... (1 Reply)
Discussion started by: goodmis
1 Replies

10. UNIX for Advanced & Expert Users

UNIX script failing ....

Hi folks, I have written down a UNIX script which actually FTP the file to other server. What is happening now , this script is not working only for 1 server , as it is working for 32 different FTP server . In this particular server , we are getting message “FTp:550 access denied”... (1 Reply)
Discussion started by: khan1978
1 Replies
Login or Register to Ask a Question