Re: [Logwatch] Fwd: Some consideration about 7.3.5

"Bjorn L." <[email protected]>
Newsgroups gmane.comp.log.logwatch.devel,gmane.comp.log.logwatch.general
Message-ID <[email protected]>
[Copying logwatch-devel list, because it seemed more appropriate.
  Replies should go to the logwatch-devel list only.]

Indeed, I hadn't considered the inter-dependence of the different
options.  I see three solutions:

A. We could revert to the old behaviour, and just test for the
   existence of the cron/anacron variable MAILTO.  This is the
   solution that was originally proposed for Fedora.

B. We can check if the runtime option --mailto is specified,
   and force mail.

C. We can consolidate the different options.  Specifically,
   --print, --mailto, --output, and --encode explicitly or
   implictly specify conflicting behaviour.

Option A fixes the issue that started the change to print by
default.  It means that the default is once again to mail,
not print.

Option B fixes the issue mentioned in the email shown below.
Default remains to print, and let cron email.

Option C could yield a cleaner interface, but it requires
specifying and coding it (I'm not available for it), and
is no longer backwards-compatible.

Any of the above probably needs better documentation as
well.

[As an aside, I think we have the same issue with the
  inter-dependence of options --multiemail, --hostname,
  --splithosts, and the new mailto_{host} variable.
  So if option C is undertaken, then these should be
  fixed as well.]

Opinions requested and welcome.  We can also do a mix of
the above (short-term solution, and then option C if
someone wants to undertake it).


Kirk Bauer wrote:
> Any suggestions on how to clean this up?
> 
> ---------- Forwarded message ----------
> From: *Paolo Basenghi* <[email protected] 
> <mailto:[email protected]>>
> Date: May 18, 2007 3:04 AM
> Subject: Some consideration about 7.3.5
> To: [email protected] <mailto:[email protected]>
> 
> Hello Kirk,
> I tested logwatch 7.3.5 an I found the new defaults a bit confusing (and 
> a bit functionally buggy), so I submit to you some considerations along 
> with my compliments for your great tool:
> 
> - I agree that cron sends an email to the user if a cron script produce 
> some output, so the default of printing the report on standard output 
> could make sense but, as in my case, when logwatch produces HTML output, 
> cron cannot insert MIME headers, so the mail client show the HTML source 
> code;
> - I resolved that by adding "Print = No" in logwatch.conf, but it is 
> undocumented: I found it in the developer mailing list;
> - the "--mailto" command line option does not work anymore when in 
> "print by default" mode; it work only when "Print = No" is present in 
> logwatch.conf. Pheraphs  the correct behaviour in this case should be to 
> send email *and* print to stdout, it shouldn't?
> - if the default behaviour is to print to stdout, then it should exist a 
> "--noprint" option instead of "--print".
> 
> Hoping this can help.
> Sorry for my poor english and best regards.
> -- 
> 
> Paolo Basenghi - Centro elaborazione dati
> Az.Spec.Farmacie Comunali Riunite
> Via Doberdo' 9 - 42100 Reggio Emilia
> Tel +39(0522)543312
> email: [email protected] <mailto:[email protected]>
> www.fcr.re.it <http://www.fcr.re.it> - www.informazionisuifarmaci.it 
> <http://www.informazionisuifarmaci.it>
> www.saninforma.it <http://www.saninforma.it> - www.futurfarma.it 
> <http://www.futurfarma.it>
> 
> Le informazioni contenute in questa comunicazione sono riservate e 
> destinate esclusivamente alla/e persona/e o all'ente sopra indicati.
> E' vietato ai soggetti diversi dai destinatari qualsiasi uso, copia, 
> diffusione di quanto in esso contenuto sia ai sensi dell'art. 616 c.p., 
> sia ai sensi della legge 196/2003.
> Se questa comunicazione vi e' pervenuta per errore, vi preghiamo di 
> rispondere a questa mail e successivamente cancellarla dal vostro sistema.
> 
> 
> 
> -- 
> Kirk Bauer <[email protected] <mailto:[email protected]>>
> http://linux.kaybee.org | www.autorpm.org <http://www.autorpm.org> | 
> www.logwatch.org <http://www.logwatch.org>
> 
> 
> ------------------------------------------------------------------------
> 
> _______________________________________________
> Logwatch mailing list
> [email protected]
> http://www2.list.logwatch.org:81/mailman/listinfo/logwatch
lmpx.com only provides a reader for public news (NNTP) servers. It is not affiliated with the servers or forums shown here and is not responsible for the content of articles, which is written by their respective authors.