[Date Prev][Date Next] [Thread Prev][Thread Next] [Date Index] [Thread Index]

Re: exim da inetd...



Il mar, 2004-05-18 alle 16:03, Marco Gaiarin ha scritto:

> GPC> if [ -x /usr/sbin/update-inetd ]; then
> GPC> update-inetd --group MAIL --comment-chars \#disabled\# --add \
> GPC> "smtp          stream  tcp     nowait  mail    /usr/sbin/exim exim -bs"
> GPC> fi
> 
> Questo l'avevo visto, ma questo dovrebbe (da man update-inetd):

[...]
If you are trying to add  an  entry  which  already exists update-inetd
won't add the entry. For uncommented entries it will do nothing and 
for  entries that  are  commented  out by the comment-chars (see option
--comment-chars ) it will enable the  existing  entry.
[...]

> + aggiungere la riga in questione, commentata, se non esiste, o

_non_ commentata

> + abilitarla se è presente e commentata con #disabled#

si'

> il problema è che la riga in questione o non c'è, o è commentata con lo
> standard #off#.

Esattamente. Il comportamento che definivo "forastico" di update-inetd
e' quello di aggiungere la riga anche se gia' presente ma commentata da
una diversa stringa, il che puo' essere opinabile.

> GPC> Ad ogni modo update-inetd --comment-chars \# --disable smtp *deve*
> GPC> funzionare. Se cosi' non e', probabilmente hai altre istanze di smtp in
> GPC> inetd.conf.
> 
> ...non ho problemi a disabilitare smtpd, non è questo il punto:

il "deve funzionare" era riferito appunto al fatto che la riga non
venisse modificata durante un upgrade.

>  il
> punto è che in certe macchine la reinstallazione di exim (per un
> security update ad esempio) funziona perfetamente, in altre funziona ma
> abilita exim in inetd.

[...]
Using a single '#' character as  a  comment-char prevents update-inetd
to reenable the services on package upgrades.
[...]

Che puoi anche verificare da /usr/share/perl5/DebianNet.pm:

56   } elsif (grep(m/^#\s*$sservice\s+/, @inetd) >= 1 or
57     (($service =~ s/^#//) and grep(m/^$service\s+/, @inetd)>=1)) {
58       &printv("Processing service \`$service' ... not changed\n");


Ripeto, se non funziona e' perche' non ricadi nella situazione tipo in
cui vi e' una sola linea facente riferimento a smtp, nel gruppo MAIL e
commentata con #\s*.

Ciao,
Gian Piero.



Reply to: