FAQ Search Today's Posts Mark Forums Read
» Video Reviews

» Linux Archive

Linux-archive is a website aiming to archive linux email lists and to make them easily accessible for linux users/developers.


» Sponsor

» Partners

» Sponsor

Go Back   Linux Archive > Debian > Debian User

 
 
LinkBack Thread Tools
 
Old 07-12-2010, 06:24 AM
Sthu Deus
 
Default cron does not launch jobs correctly

Good day.

Why is it so:

when a job is been run by cron then I get:

/etc/cron.weekly/ntping:
run-parts: failed to exec /etc/cron.weekly/ntping: Exec format error
run-parts: /etc/cron.weekly/ntping exited with return code 1

when I lunch at command prompt, then:

/etc/cron.weekly/ntping
12 Jul 13:20:10 ntpdate[10915]: step time server
aaa.bbb.ccc.ddd offset 2.974808 sec


?


Thank You for Your time.


--
To UNSUBSCRIBE, email to debian-user-REQUEST@lists.debian.org
with a subject of "unsubscribe". Trouble? Contact listmaster@lists.debian.org
Archive: 4c3ab532.5991d80a.292f.32ff@mx.google.com">http://lists.debian.org/4c3ab532.5991d80a.292f.32ff@mx.google.com
 
Old 07-12-2010, 06:38 AM
Jordon Bedwell
 
Default cron does not launch jobs correctly

-----BEGIN PGP SIGNED MESSAGE-----
Hash: SHA1

On 7/12/2010 1:24 AM, Sthu Deus wrote:
> Good day.
>
> Why is it so:
>
> when a job is been run by cron then I get:
>
> /etc/cron.weekly/ntping:
> run-parts: failed to exec /etc/cron.weekly/ntping: Exec format error
> run-parts: /etc/cron.weekly/ntping exited with return code 1
>
> when I lunch at command prompt, then:
>
> /etc/cron.weekly/ntping
> 12 Jul 13:20:10 ntpdate[10915]: step time server
> aaa.bbb.ccc.ddd offset 2.974808 sec
>
>
> ?
>
>
> Thank You for Your time.
>
>

Try adding a shebang to the top of your file:
#!/bin/sh

- --
Cheers,

Jordon Bedwell
http://envygeeks.com
-----BEGIN PGP SIGNATURE-----
Version: GnuPG v1.4.10 (MingW32)

iQEcBAEBAgAGBQJMOrhwAAoJEDgik1XAY/+LBbYH/iWHHyc2wCtVE2ABNYsEFOTA
RyGymJNSnK5XdrWknEQ/+1S5OYX05JZWAEtz2gwJWv71tjTGRJpvf3UUNWdVS1wj
yi0irffjA1k5MNRUY3Wh6pBpC2ktUa7If8Fr7j70mGediuBy6w HK5tsRMaBbkJ8J
5evz6vYMG3yMXSN77WSnRd5Zzwk+WisFvGhNvGQzIJwZVkLibH ZnRK56KDVf/9oT
KPhoMnj/J5YrjCOAWWy6preO1jXBVKOvTCfGuN+eZ3HbIg/IOupGjHKKk4qLnnio
OFthe6xIF4UT/E8Smm4+K2ccPzSvILuuR3BZrbrXgESW6GbCzwHOwK4UtEloJu8 =
=itSE
-----END PGP SIGNATURE-----


--
To UNSUBSCRIBE, email to debian-user-REQUEST@lists.debian.org
with a subject of "unsubscribe". Trouble? Contact listmaster@lists.debian.org
Archive: 4C3AB870.9040002@envygeeks.com">http://lists.debian.org/4C3AB870.9040002@envygeeks.com
 

Thread Tools




All times are GMT. The time now is 08:49 AM.

VBulletin, Copyright ©2000 - 2014, Jelsoft Enterprises Ltd.
Content Relevant URLs by vBSEO ©2007, Crawlability, Inc.
Copyright 2007 - 2008, www.linux-archive.org