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

init script output



Dear Mentors,

Discussing a bug 398740 [1] I could not reach a settlement with the bug
reported due to the fact that I could not find a clear statement in
debian policy (although I think that I saw it somewhere and that is why
init script now performs this way) or LSB about init script that
" if daemon found running - don't report that to the screen but simply
"  report LSB compliant message saying "Ok"

So I consider that it is a normal/desired behavior (under various vague
policy statements [2,3]) to have smth like

lapse:~# /etc/init.d/fail2ban start || echo failure
Starting authentication failure monitor: fail2ban.
lapse:~# /etc/init.d/fail2ban start || echo failure
Starting authentication failure monitor: fail2ban.
lapse:~# /etc/init.d/fail2ban stop || echo failure
Stopping authentication failure monitor: fail2ban.
lapse:~# /etc/init.d/fail2ban stop || echo failure
Stopping authentication failure monitor: fail2ban.

Martin wants it to look similar to apache2

piper:~# /etc/init.d/apache2 start || echo failure                       #[345]
Starting web server (apache2)... .
piper:~# /etc/init.d/apache2 start || echo failure                       #[346]
Starting web server (apache2)... httpd (pid 4175) already running.
piper:~# /etc/init.d/apache2 stop || echo failure                        #[346]
Stopping web server (apache2)... .
piper:~# /etc/init.d/apache2 stop || echo failure                        #[347]
Stopping web server (apache2)... httpd (no pid file) not running.

which I actually consider a bad practice at least since it just
spits out stderr output from apache2ctl without wrapping it with
lsb_*_msg functions

So what should we do? 
* keep it the way and close the bug with wontfix
* keep it the way I want to leave this bug a wishlist?? 
* fix it asap since it is in violation of policy (please reference)

References
[1] http://bugs.debian.org/cgi-bin/bugreport.cgi?bug=398740
[2] http://refspecs.freestandards.org/LSB_3.1.0/LSB-Core-generic/LSB-Core-generic/iniscrptact.html
[3] http://www.debian.org/doc/debian-policy/ch-opersys.html#s9.4


----- Forwarded message from martin f krafft <madduck@debian.org> -----

Date: Wed, 15 Nov 2006 17:02:08 +0100
From: martin f krafft <madduck@debian.org>
To: Yaroslav Halchenko <debian@onerussian.com>
Cc: 398740@bugs.debian.org
Subject: Re: Re: Bug#398740: Re: Bug#398740: init.d script does not appear idempotent

severity 398740 wishlist
retitle 398740 please make init.d script state if it didn't do anything
thanks.

also sprach Yaroslav Halchenko <debian@onerussian.com> [2006.11.15.1647 +0100]:
> Please argue not by an example on possibly broken scripts but
> references to policy/dev-ref -- that would make it easier to
> properly resolve the issue

I accept your reasoning wrt apache2. However, I don't want to argue
using policy. I would like to know whether start started the daemon
(and set up the jails), or whether it didn't do anything because
fail2ban was already running. And the same goes for stops. This is
purely visual or haptic feedback. It's minor. In fact, it's
wishlist.

-- 
 .''`.   martin f. krafft <madduck@debian.org>
: :'  :  proud Debian developer, author, administrator, and user
`. `'`   http://people.debian.org/~madduck - http://debiansystem.info
  `-  Debian - when you have better things to do than fixing systems



----- End forwarded message -----

-- 
                                  .-.
=------------------------------   /v\  ----------------------------=
Keep in touch                    // \\     (yoh@|www.)onerussian.com
Yaroslav Halchenko              /(   )\               ICQ#: 60653192
                   Linux User    ^^-^^    [175555]


Attachment: pgpXLRUpOJVOl.pgp
Description: PGP signature


Reply to: