The manpage of logwatch says:

The format of the range option is: --range "date_range [period]"

Parameter date_range (and optional period) must be enclosed in quotes if it is ...


--range today --range yesterday --range '4 hours ago for that hour' --range '-3 days' --range 'since 2 hours ago for those hours' --range 'between -10 days and -2 days' --range 'Apr 15, 2005' --range 'first Monday in May' --range 'between 4/23/2005 and 4/30/2005' --range '2005/05/03 10:24:17 for that second'

but none of those options work on my Debian Squeeze machine.

How do you use the --range option correctly?

  • The examples are already given by you. What exactly do you want?
    – devnull
    Commented Apr 9, 2013 at 8:02

1 Answer 1


I found out myself:

if you scroll up the output after you try to call logwatch with --range, you see at the start:

ERROR: Range '4 hours ago for that hour' not understood

This system does not have Date::Manip module loaded, and therefore the only valid --range parameters are 'yesterday', 'today', or 'all'. The Date::Manip module can be installed by using either of:

apt-get install libdate-manip-perl
cpan -i 'Date::Manip'
perl -MCPAN -e 'install Date::Manip'

this takes quite a while to install, but then it works

You must log in to answer this question.

Not the answer you're looking for? Browse other questions tagged .