Find the answer to your Linux question:
Results 1 to 5 of 5
I'm having trouble with crontab. I have a cshell script, which runs fine on its own, but can not execute any of the commands in the crontab. It seems like ...
Enjoy an ad free experience by logging in. Not a member yet? Register.
  1. #1
    Just Joined!
    Join Date
    Aug 2005
    Posts
    3

    problem with crontab


    I'm having trouble with crontab. I have a cshell script, which runs fine on its own, but can not execute any of the commands in the crontab. It seems like this is an issue with my environment vars, but I"m not sure of the solution. I have tried to include my .bash_profile in several different ways in order to set up the correct environment. Here is an example of one of my attempts

    30 0,6,12,18 * * * $HOME/.bash_profile $HOME/wwatch/scripts/run_wwatch.tcsh

    One error, says "bin/sh: ncl command cannot be found" ncl is a program i need to run
    Another error can not find shared library files.

    Any help is appreciated. Thank you.

  2. #2
    Linux Guru dylunio's Avatar
    Join Date
    Aug 2004
    Location
    Cymru
    Posts
    4,157
    have you tried with the full path instead of using $HOME ?
    Registered Linux User #371543!
    Get force-get May The Source Be With You
    /dev/null
    /dev/null2

  3. #3
    Just Joined!
    Join Date
    Aug 2005
    Posts
    3

    crontab

    Yes, I tried that, but same results. Any other suggestions... Thanks

  4. $spacer_open
    $spacer_close
  5. #4
    Linux Guru Cabhan's Avatar
    Join Date
    Jan 2005
    Location
    Seattle, WA, USA
    Posts
    3,252
    I dunno if this would work, but have you tried:

    Code:
    /bin/csh /home/user/wwatch/scripts/run_wwatch.tcsh
    ?

  6. #5
    Just Joined!
    Join Date
    Aug 2005
    Posts
    3

    I got it to work

    Thanks for the suggestions. I got it to work by setting all the environmental vars inside the tcsh script which i'm calling with crontab.

Posting Permissions

  • You may not post new threads
  • You may not post replies
  • You may not post attachments
  • You may not edit your posts
  •