$ vi collect.sh
# collect.sh 내용
python3 [collect.py의 절대경로]
$ chmod +x [collect.sh의 절대경로]
$ service cron start
# password 를 설정해주면 된다.
# crontab 파일 수정 명령어
$ crontab -e
# 파일에 아래 내용 추가
* * * * * [collect.sh의 절대경로] 2>&1 | tee logfile.txt
* * * * * sleep 10;[collect.sh의 절대경로] 2>&1 | tee logfile.txt
* * * * * sleep 20;[collect.sh의 절대경로] 2>&1 | tee logfile.txt
* * * * * sleep 30;[collect.sh의 절대경로] 2>&1 | tee logfile.txt
* * * * * sleep 40;[collect.sh의 절대경로] 2>&1 | tee logfile.txt
* * * * * sleep 50;[collect.sh의 절대경로] 2>&1 | tee logfile.txt
service cron restart
crontab은 백그라운드로 실행되므로 명령어 > result.txt로 log를 기록하는 것이 좋음