Relay-Version: version B 2.10 5/3/83; site utzoo.UUCP Posting-Version: notesfiles Path: utzoo!watmath!clyde!burl!ulysses!mhuxr!mhuxt!houxm!vax135!cornell!uw-beaver!tektronix!hplabs!hp-pcd!orstcs!kmn From: kmn@orstcs.UUCP (kmn) Newsgroups: net.unix-wizards Subject: Running C programs with cron ??? Message-ID: <21900005@orstcs.UUCP> Date: Fri, 20-Sep-85 14:36:00 EDT Article-I.D.: orstcs.21900005 Posted: Fri Sep 20 14:36:00 1985 Date-Received: Thu, 26-Sep-85 07:10:32 EDT Organization: Oregon State University - Corvallis, OR Lines: 37 Nf-ID: #N:orstcs:21900005:000:1155 Nf-From: orstcs!kmn Sep 20 10:36:00 1985 Has anyone experienced problems with the 'system()' call within a C program not being executed properly when the program is executed via cron? I have an Intel 286/310 XENIX system (but have also seen the problem on a VAX running 4.2). The problem is as follows: The C program contains a line such as.. system("/usr/lib/uucp/uucico -r1 -sxxxxxx"); The program executes correctly when executed in the csh, but if the program is executed via cron with 0 * * * * /usr/lib/uucp/program the system command is not executed. All other statements in the C program execute properly. I have had similar problems by doing the following test: create a shell containing: ps > /tmp/junk then execute the shell with cron by * * * * * csh shell The ps command never dumps to the file /tmp/junk. I suspect that the problem is in executing a new shell from within cron, and possibly due to the differences between sh and csh, but I haven't been able to figure it out (although, uucico executes properly from both sh and csh). Any answers would be greatly appreciated. Please respond to: Dave Wills Oregon State University ...hplabs!hp-pcd!osuee!dave Brought to you by Super Global Mega Corp .com