How to get crontab and crond running properly?

Sean Richards richardss at lvl.co.nz
Sat Jul 15 04:25:52 UTC 2006


Sean Richards wrote:

> Hi,
>
> Have built a system using Busybox 1.2. Have used 'make 'defconfig' so 
> everything is included. System boots and runs fine but I can't seem to 
> get 'crontab' and 'crond' working properly. To start using cron I have 
> made the crontab directories with
>
> $ mkdir -p /var/spool/cron/crontabs
>
> Then tried to edit a crontab with
>
> $ crontab -e
>
> This fails with `exec: No such file or directory`. Looking in 
> `/var/spool/cron/crontabs` I can see an empty file 'root' and a file 
> 'cron.update' with the single entry 'root'. Creating an entry by hand 
> such as `*/1 * * * * /bin/date > /var/tmp/crontest` does nothing. 
> Checking with ps shows crond to be running. I have set a default 
> profile in `/etc/profile` with
>
> export SHELL=/bin/ash
> export VISUAL=/bin/vi
> export EDITOR=/bin/vi
> export HOME=/root
>
> Any help getting this setup would be appreciated.
>
Ok have solved the problem. I had the default shell set to 'None' in 
menuconfig. I did not notice this at first but looking in '.config' I 
see that this means
'CONFIG_FEATURE_SH_IS_NONE=y' which is probably not that desirable! 
Unsetting this and setting 'CONFIG_FEATURE_SH_IS_ASH=y' means that the 
'/bin/sh' link is created and crond and crontab now work as expected. 
Sorry about the noise!

Cheers




More information about the busybox mailing list