crontab|Cause and Solution for the Error "bad minute errors in crontab file, can't install"
When editing cron settings with crontab -e and saving with :wq, you may encounter the following error message:
"/tmp/crontab.XXXXfQbyGc" 36L, 1956C written
crontab: installing new crontab
"/tmp/crontab.XXXXfQbyGc":1: bad minute
errors in crontab file, can't install.
Do you want to retry the same edit?
("Do you want to retry the same edit?" means "Do you want to reopen the editor and try again?".
Enter "y" and press [Enter] to reopen the crontab editor.)
Cause of the error
The message "bad minute errors in crontab file, can't install" indicates that the "minute" field in the crontab file contains an invalid value. You should check the minute field.
In crontab, the minute field is always the leftmost column when editing with crontab -e.
Check that part carefully.
Example that causes the error
Example: Opening the following screen with crontab -e
nobuneko test.sh
20 0 * * * /home/nobuneko/test.sh 1>/dev/null
Running /home/nobuneko/test.sh at 00:20 is written correctly in the second line.
However, the first line "nobuneko test.sh" does not begin with "#".
Because of this, the letter "n" is treated as the minute field, causing the error
"bad minute errors in crontab file, can't install."
Solution
In crontab, comment lines must begin with "#". Fixing the entry as shown below resolves the issue:
#nobuneko test.sh
20 0 * * * /home/nobuneko/test.sh 1>/dev/null