Path: utzoo!utgpu!watmath!uunet!cs.utexas.edu!csd4.milw.wisc.edu!srcsip!nic.MR.NET!shamash!nis!sialis!rjg From: rjg@sialis.mn.org (Robert J. Granvin) Newsgroups: unix-pc.general Subject: Re: yet again Re: crontab Daemon-from-Hell Message-ID: <1559@sialis.mn.org> Date: 11 Jun 89 04:18:54 GMT References: <19071@cup.portal.com> <14373@bfmny0.UUCP> <19196@cup.portal.com> <1545@sialis.mn.org> <1212@cbnewsc.ATT.COM> Reply-To: rjg@sialis.mn.org (Robert J. Granvin) Organization: Dr. Ho Laboratory and Day Care Center Lines: 43 >> The solution is VERY simple. Remove the `cd`, and make the find >> reference an explicit path. If the directory dies or goes away, the >> find will fail, and nothing more will happen than your uucp mailfile >> getting a note of the failure. > >Could someone please tell me if my postings on this group are getting out? > >Twice this past week I mentioned that a failed 'cd' (due to, for example, >the directory named as the argument to 'cd' not being present) would ABORT a >script running under /bin/sh, uucpadm's default shell. > >I apologize for sounding exasperated. I assume that my posts just haven't >gotten to Robert's site yet. Are they getting out at all? Yes, they're getting here. However, I should have clarified a point (just like I noted that the original posting didn't clarify the point :-). This made the exact point that I failed to... There are more than a few people who insist upon changing default shells away from /bin/sh to other shells including ksh and others. Prudent or wise? Your decision. (Although a real cron will warn you that the commands will be executed with /bin/sh. What does a stock 3b1 do if you change your default shell and run a cron job?) However, if run as ksh, the failed cd will NOT cancel the execution of the script. So, even if safe under a cron job, it may not be safe under a manually executed job. And since so many people are panicking about it and beating it into the ground (which was a point I _did_ make), then just "solve" it and quit letting it eat your cerebral cortex. Seeing everything from comments about "reprehensible" to lawsuits, it's just not worth discussing it anymore since people are just not thinking rationally about it. Just fix it, and "Don't worry, be happy." -- ________Robert J. Granvin________ INTERNET: rjg@sialis.mn.org ____National Computer Systems____ CONFUSED: rjg%sialis.mn.org@shamash.cdc.com __National Information Services__ UUCP: ...uunet!rosevax!sialis!rjg "Exxon: Our gasoline contains no sea water"