Take the 2-minute tour ×
Unix & Linux Stack Exchange is a question and answer site for users of Linux, FreeBSD and other Un*x-like operating systems.. It's 100% free, no registration required.

First I installed and ran crontab:

emerge cron
crontab -e

In another console, I ran man cron, but this has no examples of how to use crontab. Where can I get examples, and why are there none in the man page?

share|improve this question
    
gentoo xi # apropos crontab crontab: nothing appropriate –  Xsi Nov 9 '12 at 12:46
add comment

1 Answer

Try reading man 5 crontab (which is probably a different page than you got by reading man crontab). man crontab likely directed you to a page about the crontab executable rather than the crontab file. The number 5 says to use category 5, "files, file formats, and conventions", rather than the default category (likely category 1, "general commands").

You can see all available sections for a command by using apropos like so:

$ apropos crontab
crontab (1)          - maintain crontab files for individual users (Vixie Cron)
crontab (5)          - tables for driving cron

There are also some examples on the relevant Wikipedia article.

share|improve this answer
    
Good explanation, I always forget about aprapos! –  delh Nov 9 '12 at 13:30
add comment

Your Answer

 
discard

By posting your answer, you agree to the privacy policy and terms of service.

Not the answer you're looking for? Browse other questions tagged or ask your own question.