I suggest
for understanding why it doesn't work with cron.
You other question is very confusing; perhaps
might help, or maybe this from
Why can't I run this program?
You can see it right there in your directory, but it keeps saying "Not found" when you try to run it. If you are "root", it's because root does not, by default and by design, have "." (the current directory) in its PATH, and unlike DOS, Unix shells don't assume that the current directory should be searched. Actually, ordinary users get "." in their PATH, but "root" does not, and the reason is security- to keep you from accidentally executing the wrong program. Type "./program" to get around this, or if you want to live dangerously, modify root's .profile and add ":." to the end of the PATH.
If it does the same thing when you do "./program", it's because the very first line of the script tells it to use some other program: for example, the script might have "#!/usr/bin/perl5" as its first line- if you don't have /usr/bin/perl5, you'll get that "not found" error (look at the line carefully- you might have /usr/local/bin/perl5 or /usr/bin/perl, for example, but close doesn't count here!).
If the error is "cannot execute", try "chmod +x program". Unix programs have to be marked as "executable". DOS does that by the program's extension (.BAT, .EXE, .COM), which is, as usual, dumb. All together now: DOS IS DUMB. Thanks.
It's also possible that your problem is related to LD_LIBRARY_PATH - This won't be the case for a script you make, but it could be for someone else's program. What that controls is where to search for shared libraries. Unix/Linux systems always have standard places to search, but sometimes need some help. See Why do I get "dynamic linker" errors or load failures? in the FAQ here.
Tony Lawrence
SCO Unix/Linux Resources
tony@pcunix.com