Bonjour Mélodie,
Merci pour les liens, je connaissais déjà le premier du coup je me suis servi de l'
outil en ligne pour créer ma tache cron (crontab)
j'ai choisis qu'elle s'exécute toutes les 20mn, mais j'ai tout de même un doute dans sa rédaction :
Voila mon fichier crontab :
Code : Tout sélectionner
[email protected]:~$ crontab -l
# Edit this file to introduce tasks to be run by cron.
#
# Each task to run has to be defined through a single line
# indicating with different fields when the task will be run
# and what command to run for the task
#
# To define the time you can provide concrete values for
# minute (m), hour (h), day of month (dom), month (mon),
# and day of week (dow) or use '*' in these fields (for 'any').#
# Notice that tasks will be started based on the cron's system
# daemon's notion of time and timezones.
#
# Output of the crontab jobs (including errors) is sent through
# email to the user the crontab file belongs to (unless redirected).
#
# For example, you can run a backup of all your user accounts
# at 5 a.m every week with:
# 0 5 * * 1 tar -zcf /var/backups/home.tgz /home/
#
# For more information see the manual pages of crontab(5) and cron(8)
#
# m h dom mon dow command
20 * * * * find /tmp -type f -mmin +1440 -delete > /dev/null
La question, c'est est ce que je dois laisser un espace en début de ligne, et aussi des espaces entre les différents paramètres (minute, heure, jour du mois, mois, jour de semaine) car dans l'exemple au dessus il n'y a pas d'espace