fetchmail-friends
[Top] [All Lists]

Re: [fetchmail][RFC] --daemon taking an optional (instead of required) argument

2001-03-28 20:54:07
On Thu, 29 Mar 2001, hmh(_at_)debian(_dot_)org wrote:
On Wed, 28 Mar 2001, ESR wrote:
Henrique de Moraes Holschuh <hmh(_at_)debian(_dot_)org>:
The current behaviour of --daemon (the command-line option) makes
it somewhat awkward to have fetchmail go into daemon mode by
default. This happens because since command line globals
overwrite those defined in the config file, the value of
poll_interval set by "set daemon" in the config file will be
ignored.

You haven't justified it sufficiently.  I don't understand why it's
useful to support --daemon with no argument.

--daemon with an required argument makes it impossible to request
that, by default, fetchmail should behave in daemon mode... AND to
override the poll interval at the .fetchmailrc file.

Why? I use that option and all I had to do is to pass the time
interval I want... I don't see any problem or inconvenient in doing
so. 

You said that it makes it necessary for the user to edit the file to
change the interval... Having a default value will also make it
necessary to edit the same file to change the interval if he doesn't
want it. 

--daemon with an optional arquiment, makes it possible to request
that fetchmail's default behaviour be that of daemon mode... AND to
set the poll interval in the .fetchmailrc file.

Hmmmm... I don't see much sense about defining a poll interval in
.fetchmailrc if it will be run as a daemon. You can call it with the
interval in several places where it will be started "automatically"
(e.g. ~/.bash_login or any of the files executed automatically when
the system starts...)

This would be useful in setups where fetchmail is started in a
system initscript (as root), such as the one we have in Debian right
now: Currently, one is forced to edit the initscript proper to
select the daemon poll interval. This means one must configure
fetchmail in two places, the .fetchmailrc (maybe through
fetchmailconf), and by editing a system initscript config file.

And how would it be if he doesn't want the defaul 300s interval? He
would have to edit the same file. In what manner does it differ from
editing the file and changing from 300 to something else?

It is my experience that users are confused by that need to edit two
configuration files. I had fetchmail without the --daemon N option,
but users would fill bugs complaining that fetchmail would not start
in daemon mode (never mind the documentation clearly stating that
one should configure it for daemon mode).  So, I had to force daemon
mode using --daemon 300...  now I have users complaining that
fetchmail ignores the set daemon N directive in fetchmailrc (never
mind the documentation now clearly stating that one should edit the
initscript to change deamon poll interval). This is the reason why I
think a way to enable daemon mode by default would be useful.

I think that we should remove the daemon option from the .fetchmailrc
file... It makes more sense to me... Or make it obligatory to have the
poll interval either at command line (higher priority) or at the
.fetchmailrc... But it must be obligatory to say the poll interval. I
don't like hard coded stuff like this...


There are other possible solutions -- such as adding a fetchmailrc
parser capable of searching for a set daemon statement to the
initscript; Or changing fetchmail's default behavior when exectued
as root to be daemon mode; Or telling the users to go RTFM when they
fill a bug about the issue.

:-) RTFM seems OK to me... ;-)

Here in Brazil we have a saying that can be translated to something
like "teach him how to fish and he'll be able to feed everyday; give
him the fish and he'll eat only once". 

I think of RTFM as teaching how to fish. :-)))



Be seeing you,
-- 
Godoy. <godoy(_at_)conectiva(_dot_)com>

Departamento de Publicações       Conectiva S.A.
Publishing Department             Conectiva Inc.

"Ser poeta não é minha ambição, é minha maneira de estar sozinho"
                                - Fernando Pessoa