<?xml version="1.0" encoding="UTF-8"?>
<rss xmlns:content="http://purl.org/rss/1.0/modules/content/" xmlns:dc="http://purl.org/dc/elements/1.1/" xmlns:rdf="http://www.w3.org/1999/02/22-rdf-syntax-ns#" xmlns:taxo="http://purl.org/rss/1.0/modules/taxonomy/" version="2.0">
  <channel>
    <title>topic Re: Cron job problem in Operating System - HP-UX</title>
    <link>https://community.hpe.com/t5/operating-system-hp-ux/cron-job-problem/m-p/3065582#M139618</link>
    <description>Unexpected end of line ? Seems like a 'typo' in your crontab..&lt;BR /&gt;&lt;BR /&gt;Try to delete the line completely and type it in again (don't paste it from your clipboard).&lt;BR /&gt;&lt;BR /&gt;greets&lt;BR /&gt;Wout</description>
    <pubDate>Tue, 09 Sep 2003 11:16:17 GMT</pubDate>
    <dc:creator>Wouter Jagers</dc:creator>
    <dc:date>2003-09-09T11:16:17Z</dc:date>
    <item>
      <title>Cron job problem</title>
      <link>https://community.hpe.com/t5/operating-system-hp-ux/cron-job-problem/m-p/3065571#M139607</link>
      <description>Hi,&lt;BR /&gt;&lt;BR /&gt;I have an entry in the cron job as follows:&lt;BR /&gt;0 13 * * 1 rsync -arvz /afs/sie.intel.com/cad/sun4x_57/xscale/windriver/2.2.1/docs/usb/ /pgfs2/sws1/CSR/users/cloh6/usb/ &amp;gt; /pgfs2/eng/cloh6/syncout0&lt;BR /&gt;&lt;BR /&gt;It somehow fails to execute the rsync command above at the specified time. Hence the job did not get executed at all. &lt;BR /&gt;&lt;BR /&gt;The rsync command did get run when it was invoked from the command line. &lt;BR /&gt;&lt;BR /&gt;I was wondering if anyone does have any ideas on the cause of this problem &amp;amp; the method of solving it? &lt;BR /&gt;&lt;BR /&gt;Thanks&lt;BR /&gt;</description>
      <pubDate>Mon, 08 Sep 2003 09:27:40 GMT</pubDate>
      <guid>https://community.hpe.com/t5/operating-system-hp-ux/cron-job-problem/m-p/3065571#M139607</guid>
      <dc:creator>Peter Remirez</dc:creator>
      <dc:date>2003-09-08T09:27:40Z</dc:date>
    </item>
    <item>
      <title>Re: Cron job problem</title>
      <link>https://community.hpe.com/t5/operating-system-hp-ux/cron-job-problem/m-p/3065572#M139608</link>
      <description>Peter,&lt;BR /&gt;&lt;BR /&gt;Cron jobs have minimal environements (i.e. not PATH, few variables set, etc.).  Try the full path name for the rsync command.&lt;BR /&gt;&lt;BR /&gt;&lt;BR /&gt;Pete&lt;BR /&gt;&lt;BR /&gt;</description>
      <pubDate>Mon, 08 Sep 2003 09:37:17 GMT</pubDate>
      <guid>https://community.hpe.com/t5/operating-system-hp-ux/cron-job-problem/m-p/3065572#M139608</guid>
      <dc:creator>Pete Randall</dc:creator>
      <dc:date>2003-09-08T09:37:17Z</dc:date>
    </item>
    <item>
      <title>Re: Cron job problem</title>
      <link>https://community.hpe.com/t5/operating-system-hp-ux/cron-job-problem/m-p/3065573#M139609</link>
      <description>Peter,&lt;BR /&gt;&lt;BR /&gt;Edited version:&lt;BR /&gt;&lt;BR /&gt;Cron jobs have minimal environments (i.e. not much of a PATH, few variables set, etc.).  Try the full path name for the rsync command.&lt;BR /&gt;&lt;BR /&gt;&lt;BR /&gt;Pete&lt;BR /&gt;&lt;BR /&gt;</description>
      <pubDate>Mon, 08 Sep 2003 09:37:53 GMT</pubDate>
      <guid>https://community.hpe.com/t5/operating-system-hp-ux/cron-job-problem/m-p/3065573#M139609</guid>
      <dc:creator>Pete Randall</dc:creator>
      <dc:date>2003-09-08T09:37:53Z</dc:date>
    </item>
    <item>
      <title>Re: Cron job problem</title>
      <link>https://community.hpe.com/t5/operating-system-hp-ux/cron-job-problem/m-p/3065574#M139610</link>
      <description>In the file you redirected the cronjob's stdout to, does there appear something like:&lt;BR /&gt;&lt;BR /&gt;sh: rsync:  not found.&lt;BR /&gt;&lt;BR /&gt;I guess rsync, as Pete wrote, isn't in one of the standard paths cronjobs are furnished with like /usr/bin.&lt;BR /&gt;&lt;BR /&gt;In the shell where you successfully issued the rsync command what does your PATH look like, or what is a "which rsync" responding?</description>
      <pubDate>Mon, 08 Sep 2003 10:08:54 GMT</pubDate>
      <guid>https://community.hpe.com/t5/operating-system-hp-ux/cron-job-problem/m-p/3065574#M139610</guid>
      <dc:creator>Ralph Grothe</dc:creator>
      <dc:date>2003-09-08T10:08:54Z</dc:date>
    </item>
    <item>
      <title>Re: Cron job problem</title>
      <link>https://community.hpe.com/t5/operating-system-hp-ux/cron-job-problem/m-p/3065575#M139611</link>
      <description>The best thing to check if your cron was running is to add something into the script like touch /tmp/cron.tmp&lt;BR /&gt;after the script supposed to run you can check it under /tmp if the file has been created.&lt;BR /&gt;the others a right as well. For cron you should think of the enviroment.&lt;BR /&gt;Maybe don't trigger the sync via cron, trigger a other script which triggers the sync. Within this script you can parse the env.&lt;BR /&gt;But don't forgett to use a absolute path for it.</description>
      <pubDate>Mon, 08 Sep 2003 10:14:17 GMT</pubDate>
      <guid>https://community.hpe.com/t5/operating-system-hp-ux/cron-job-problem/m-p/3065575#M139611</guid>
      <dc:creator>Andi Rigauer</dc:creator>
      <dc:date>2003-09-08T10:14:17Z</dc:date>
    </item>
    <item>
      <title>Re: Cron job problem</title>
      <link>https://community.hpe.com/t5/operating-system-hp-ux/cron-job-problem/m-p/3065576#M139612</link>
      <description>Hi,&lt;BR /&gt;&lt;BR /&gt;As Pete wrote it's common problem when you start scripts from crontab. In addition , from my experience if you use some variables in your script, put in the beginning line &lt;BR /&gt;&lt;BR /&gt;. /home/user/profile&lt;BR /&gt;&lt;BR /&gt;or special cron-profile (file where you can specify PATH, variables, ORACLE_HOME .....)&lt;BR /&gt;&lt;BR /&gt;. /home/user/cronprofile&lt;BR /&gt;&lt;BR /&gt;&lt;BR /&gt;HTH&lt;BR /&gt;&lt;BR /&gt;Radim</description>
      <pubDate>Mon, 08 Sep 2003 10:27:10 GMT</pubDate>
      <guid>https://community.hpe.com/t5/operating-system-hp-ux/cron-job-problem/m-p/3065576#M139612</guid>
      <dc:creator>Radim Jarosek</dc:creator>
      <dc:date>2003-09-08T10:27:10Z</dc:date>
    </item>
    <item>
      <title>Re: Cron job problem</title>
      <link>https://community.hpe.com/t5/operating-system-hp-ux/cron-job-problem/m-p/3065577#M139613</link>
      <description>Here is how I write cron scripts to avoid the problem.&lt;BR /&gt;&lt;BR /&gt;I have two sessions open as the user.&lt;BR /&gt;&lt;BR /&gt;One session edits the script, the other issues the whence command for every command I plan to use.&lt;BR /&gt;&lt;BR /&gt;All commands are done with the full path of the command.  It would be easier to set the PATH variable, but that leaves open the possbility that the PATH variable can be changed by the cron script itself.&lt;BR /&gt;&lt;BR /&gt;An OS upgrade can mess up scripts by moving the commands themselves, but I get warning on that and can either use sed to change all user contributed scripts, or softlink to the new command area when that happens.&lt;BR /&gt;&lt;BR /&gt;SEP</description>
      <pubDate>Mon, 08 Sep 2003 10:33:15 GMT</pubDate>
      <guid>https://community.hpe.com/t5/operating-system-hp-ux/cron-job-problem/m-p/3065577#M139613</guid>
      <dc:creator>Steven E. Protter</dc:creator>
      <dc:date>2003-09-08T10:33:15Z</dc:date>
    </item>
    <item>
      <title>Re: Cron job problem</title>
      <link>https://community.hpe.com/t5/operating-system-hp-ux/cron-job-problem/m-p/3065578#M139614</link>
      <description>Also, check email for root (or whatever user this is) as cron will usually email you output from commands if things dont go well.&lt;BR /&gt;&lt;BR /&gt;I mention this because we tend to not check "root"'s email on our system and then every once in a while we do and usually find old cron job errors :-)&lt;BR /&gt;&lt;BR /&gt;Best regards,&lt;BR /&gt;&lt;BR /&gt;Kent M. Ostby&lt;BR /&gt;</description>
      <pubDate>Mon, 08 Sep 2003 11:37:03 GMT</pubDate>
      <guid>https://community.hpe.com/t5/operating-system-hp-ux/cron-job-problem/m-p/3065578#M139614</guid>
      <dc:creator>Kent Ostby</dc:creator>
      <dc:date>2003-09-08T11:37:03Z</dc:date>
    </item>
    <item>
      <title>Re: Cron job problem</title>
      <link>https://community.hpe.com/t5/operating-system-hp-ux/cron-job-problem/m-p/3065579#M139615</link>
      <description>Kent,&lt;BR /&gt;The email which I obtained did not indicate the which command in the crontab produced the error. &lt;BR /&gt;&lt;BR /&gt;The error which message obtained from the e-mail is: &lt;BR /&gt;Subject: Your crontab file has an error in it&lt;BR /&gt;Your "crontab" on pgsc2603         &lt;BR /&gt;unexpected end of line&lt;BR /&gt;This entry has been ignored.&lt;BR /&gt;&lt;BR /&gt;Is there a way which to run the crontab in a verbose mode i.e. displaying the error message occuring at a specific command? &lt;BR /&gt;&lt;BR /&gt;Thanks&lt;BR /&gt;&lt;BR /&gt;</description>
      <pubDate>Tue, 09 Sep 2003 03:02:08 GMT</pubDate>
      <guid>https://community.hpe.com/t5/operating-system-hp-ux/cron-job-problem/m-p/3065579#M139615</guid>
      <dc:creator>Peter Remirez</dc:creator>
      <dc:date>2003-09-09T03:02:08Z</dc:date>
    </item>
    <item>
      <title>Re: Cron job problem</title>
      <link>https://community.hpe.com/t5/operating-system-hp-ux/cron-job-problem/m-p/3065580#M139616</link>
      <description>Besides PATH to commands, people here are telling you to check on all of the environmental variables.&lt;BR /&gt;&lt;BR /&gt;Try this.  Put this on the bottom of your crontab file for a second&lt;BR /&gt;* * * *  /usr/bin/env &amp;gt; /tmp/crontab.env&lt;BR /&gt;&lt;BR /&gt;Wait until /tmp/crontab.env gets created. &lt;BR /&gt;Run /usr/bin/env &amp;gt; /tmp/my.env&lt;BR /&gt;&lt;BR /&gt;(remove the /usr/bin/env from the crontab file now).&lt;BR /&gt;&lt;BR /&gt;Then look at both files.  If it runs by hand, and not by cron, the differences here could be why rsync fails to run. &lt;BR /&gt;&lt;BR /&gt;IF it's not the environment, maybe there's something different on the system at 1300 hours?  &lt;BR /&gt;&lt;BR /&gt;steve</description>
      <pubDate>Tue, 09 Sep 2003 11:10:35 GMT</pubDate>
      <guid>https://community.hpe.com/t5/operating-system-hp-ux/cron-job-problem/m-p/3065580#M139616</guid>
      <dc:creator>Steve Post</dc:creator>
      <dc:date>2003-09-09T11:10:35Z</dc:date>
    </item>
    <item>
      <title>Re: Cron job problem</title>
      <link>https://community.hpe.com/t5/operating-system-hp-ux/cron-job-problem/m-p/3065581#M139617</link>
      <description>Peter,&lt;BR /&gt;&lt;BR /&gt;It's complaining about an unexpected end of line.  Unfortunately, the forums formatting makes your crontab entry difficult to read in your original post.  Could you attache the actual crontab entry so we can better see it?&lt;BR /&gt;&lt;BR /&gt;&lt;BR /&gt;Pete&lt;BR /&gt;&lt;BR /&gt;</description>
      <pubDate>Tue, 09 Sep 2003 11:14:28 GMT</pubDate>
      <guid>https://community.hpe.com/t5/operating-system-hp-ux/cron-job-problem/m-p/3065581#M139617</guid>
      <dc:creator>Pete Randall</dc:creator>
      <dc:date>2003-09-09T11:14:28Z</dc:date>
    </item>
    <item>
      <title>Re: Cron job problem</title>
      <link>https://community.hpe.com/t5/operating-system-hp-ux/cron-job-problem/m-p/3065582#M139618</link>
      <description>Unexpected end of line ? Seems like a 'typo' in your crontab..&lt;BR /&gt;&lt;BR /&gt;Try to delete the line completely and type it in again (don't paste it from your clipboard).&lt;BR /&gt;&lt;BR /&gt;greets&lt;BR /&gt;Wout</description>
      <pubDate>Tue, 09 Sep 2003 11:16:17 GMT</pubDate>
      <guid>https://community.hpe.com/t5/operating-system-hp-ux/cron-job-problem/m-p/3065582#M139618</guid>
      <dc:creator>Wouter Jagers</dc:creator>
      <dc:date>2003-09-09T11:16:17Z</dc:date>
    </item>
  </channel>
</rss>

