Seu arquivo pessoal do crontab deve ser parecido com este
45 18 * * * /bkp_db.sh
Existem vários arquivos crontab, cada um com um layout ligeiramente diferente. arquivos crontab pessoais, editados via crontab -e
, não contêm o nome de usuário.
man crontab
diz,
There is one file for each user's crontab under the
/var/spool/cron/crontabs directory. Users are not allowed to edit the
files under that directory directly to ensure that only users allowed by
the system to run periodic tasks can add them, and only syntactically cor‐
rect crontabs will be written there. This is enforced by having the
directory writable only by the crontab group and configuring crontab com‐
mand with the setgid bid set for that specific group.
Mas se você ler man cron
, também lerá
Additionally, in Debian, cron reads the files in the /etc/cron.d direc‐
tory. cron treats the files in /etc/cron.d as in the same way as the
/etc/crontab file (they follow the special format of that file, i.e. they
include the user field). However, they are independent of /etc/crontab:
they do not, for example, inherit environment variable settings from it.
This change is specific to Debian see the note under DEBIAN SPECIFIC
below.