Why did you add the 'root' part in front of the script? AFAIK, that
shouldn't be there. Just make sure you chmod 755 the script, and you don't
even need to sh <script>, as you already have the #!/bin/sh line there,
which tell whatever shell you're in that they should use sh to run your
script.

2009/7/30 Vassilis <bigracc...@gmx.net>

> Hello all!
>
> Since my ISP is disconnecting my connection every 24 hours I would like
> to make sure that happens in the early morning hours rather than at noon.
>
> After a bit of searching I found the .sh script that works but I havent
> managed to get it to work properly.
>
> This is the .sh script:
>
> #!/bin/sh
> # Reconnect and update DynDNS
>
> /etc/rc.d/uplinks stop main
> sleep 90
> /usr/local/bin/setddns.pl
> sleep 30
> /usr/local/bin/setddns.pl
>
> I made a folder called /customscripts and moved the .sh file in there.
> Running it manually via "sh <scriptname.sh> works perfectly, getting it
> to run at a specific time is where I am stuck.
>
> I edited the /etc/crontab file and added at the end:
>
> 30 3 * * * root /customscripts/reconnect.sh
>
> This should run the script at 03:30 in the morning but unfortunately it
> doest work. Since this is my first cronjob ever I am almost certain I
> have missed something trivial but important :-)
>
> Thank you!
>
>
> ------------------------------------------------------------------------------
> Let Crystal Reports handle the reporting - Free Crystal Reports 2008 30-Day
> trial. Simplify your report design, integration and deployment - and focus
> on
> what you do best, core application coding. Discover what's new with
> Crystal Reports now.  http://p.sf.net/sfu/bobj-july
> _______________________________________________
> Efw-user mailing list
> Efw-user@lists.sourceforge.net
> https://lists.sourceforge.net/lists/listinfo/efw-user
>
------------------------------------------------------------------------------
Let Crystal Reports handle the reporting - Free Crystal Reports 2008 30-Day 
trial. Simplify your report design, integration and deployment - and focus on 
what you do best, core application coding. Discover what's new with 
Crystal Reports now.  http://p.sf.net/sfu/bobj-july
_______________________________________________
Efw-user mailing list
Efw-user@lists.sourceforge.net
https://lists.sourceforge.net/lists/listinfo/efw-user

Reply via email to