The script did not run from the crontab-HP-UX.31 - sh: /home/oracle/dba/scripts/COLD_BACKUP_streams.sh: not found.

The script did not run from the crontab-HP-UX.31 -
This is the message:      sh: /home/oracle/dba/scripts/COLD_BACKUP_streams.sh:  not found.

This is the entry from the crontab:

15 23 * * 6 /home/oracle/dba/scripts/COLD_BACKUP_streams.sh PROD

Permissions:

-rwxr-xr-x   1 oracle     dba           2828 Jul 20 15:21 COLD_BACKUP_streams.sh

This is what the var/mail/oracle contains:

From root@host Sat Jul 25 23:15:02 AST 2015
Received: (from root@localhost)
        by host (@(#)Sendmail version 8.13.3 - Revision 1.003:: HP-UX11.31 - 8th December,2008/8.13.3) id t6Q3F2HS024356
        for oracle; Sat, 25 Jul 2015 23:15:02 -0400 (AST)
Date: Sat, 25 Jul 2015 23:15:02 -0400 (AST)
From: root@host
Message-Id: <201507260315.t6Q3F2HS024356@host>
Subject: cron

sh: /home/oracle/dba/scripts/COLD_BACKUP_streams.sh:  not found.
Solara_14TechAsked:
Who is Participating?
I wear a lot of hats...

"The solutions and answers provided on Experts Exchange have been extremely helpful to me over the last few years. I wear a lot of hats - Developer, Database Administrator, Help Desk, etc., so I know a lot of things but not a lot about one thing. Experts Exchange gives me answers from people who do know a lot about one thing, in a easy to use platform." -Todd S.

serialbandCommented:
Does the script exist?  It's complaining that it can't find it, so it can't run it.
0
Solara_14TechAuthor Commented:
Yes the script exist.
 
ls -tlr /home/oracle/dba/scripts/COLD_BACKUP_streams.sh
-rwxr-xr-x   1 oracle     dba           2828 Jul 20 15:21 /home/oracle/dba/scripts/COLD_BACKUP_streams.sh
0
MikeOM_DBACommented:
Does the first line in the script contain a valid shebang?
0
Cloud Class® Course: CompTIA Healthcare IT Tech

This course will help prep you to earn the CompTIA Healthcare IT Technician certification showing that you have the knowledge and skills needed to succeed in installing, managing, and troubleshooting IT systems in medical and clinical settings.

Solara_14TechAuthor Commented:
It has the following:

ebsprdb:/home/oracle/dba/scripts> echo $0
-sh
ebsprdb:/home/oracle/dba/scripts> more COLD_BACKUP_streams.sh
#! /bin/bash
0
simon3270Commented:
What happens if you run the script manually, exactly as it is in the crontab? i.e. same user (presumably root), and with the full path rather than a cd followed by a "./" - best to cut and paste from a crontab listing.

[Edit] Also, is this directory local, or is it an automounted remote one?  It may be that the cron job doesn't force the automount.
0

Experts Exchange Solution brought to you by

Your issues matter to us.

Facing a tech roadblock? Get the help and guidance you need from experienced professionals who care. Ask your question anytime, anywhere, with no hassle.

Start your 7-day free trial
Solara_14TechAuthor Commented:
Checking
0
Solara_14TechAuthor Commented:
interpreter "/bin/bash" not found
file link resolves to "/usr/bin/bash"
0
Solara_14TechAuthor Commented:
Thank you for pointing out the solution.
I change to ksh in the script and now it run successfully.
0
It's more than this solution.Get answers and train to solve all your tech problems - anytime, anywhere.Try it for free Edge Out The Competitionfor your dream job with proven skills and certifications.Get started today Stand Outas the employee with proven skills.Start learning today for free Move Your Career Forwardwith certification training in the latest technologies.Start your trial today
Unix OS

From novice to tech pro — start learning today.

Question has a verified solution.

Are you are experiencing a similar issue? Get a personalized answer when you ask a related question.

Have a better answer? Share it in a comment.