Re: Bug#426877: dpkg: Option "--oknodo" should be the default behaviour for "start-stop-daemon" (LSB specs)
(Cc -devel to seek input) On Thu, 31 May 2007, Iñaki Baz Castillo wrote: > Acording to the LSB specifications for init scripts [1]: > > "For all other init-script actions, the init script shall return an exit > status of zero if the action was successful. Otherwise, the exit status > shall be non-zero, as defined below. In addition to straightforward > success, the following situations are also to be considered successful: > - Restarting a service (instead of reloading it) with the force-reload > argument > - Running start on a service already running > - Running stop on a service already stopped or not running > - Running restart on a service already stopped or not running > - Running try-restart on a service already stopped or not running" > > So if I start a service that is already running I should receive 0, but > "start-stop-daemon" returns 1 (error). > > The option "--oknodo" changes the behaviour to the LSB recomendations but many > services in Debian don't use this option and return 1 in the case I've > quotted. This is very problematic for me when I try to use a Debian > service init script with HeartBeat that expects to receive a 0. I'm reluctant to change the default behaviour of start-stop-daemon at this point. What do other people think of making --oknodo the default behaviour and adding a new option to force the current default behaviour (exit with failure if nothing had to be done)? The alternative is to change policy and/or lintian to ensure that packages are using --oknodo unless they have a good reason not to. > [1] LSB specifications about init script actions: > http://www.linux-foundation.org/spec/refspecs/LSB_3.0.0/LSB-Core-generic/LSB-Core-generic/iniscrptact.html Cheers, -- Raphaël Hertzog Le best-seller français mis à jour pour Debian Etch : http://www.ouaza.com/livre/admin-debian/ -- To UNSUBSCRIBE, email to [EMAIL PROTECTED] with a subject of "unsubscribe". Trouble? Contact [EMAIL PROTECTED]
Re: Bug#426877: dpkg: Option "--oknodo" should be the default behaviour for "start-stop-daemon" (LSB specs)
El Jueves, 3 de Julio de 2008, Raphael Hertzog escribió: > I'm reluctant to change the default behaviour of start-stop-daemon at this > point. What do other people think of making --oknodo the default behaviour > and adding a new option to force the current default behaviour (exit with > failure if nothing had to be done)? > > The alternative is to change policy and/or lintian to ensure that packages > are using --oknodo unless they have a good reason not to. > > > [1] LSB specifications about init script actions: > > http://www.linux-foundation.org/spec/refspecs/LSB_3.0.0/LSB-Core-generic/ > >LSB-Core-generic/iniscrptact.html I think being LSB compliant is good for Debian. Also, sincerely I think nobody gives importance to the return code of init scripts ("1" in case of starting an already started service) because most of people start services manually or they are started when the system swithes on, so return code is not so important. But in case of service daemon (as HeartBeat that handles when to start or stop a service) these return code becomes important and being LSB compliant is, IMHO, the best way. Just my opinion. Regards. -- Iñaki Baz Castillo -- To UNSUBSCRIBE, email to [EMAIL PROTECTED] with a subject of "unsubscribe". Trouble? Contact [EMAIL PROTECTED]
Re: Bug#426877: dpkg: Option "--oknodo" should be the default behaviour for "start-stop-daemon" (LSB specs)
On Thu, Jul 03, 2008 at 10:40:53PM +0200, Raphael Hertzog wrote: > > The option "--oknodo" changes the behaviour to the LSB recomendations but > > many services in Debian don't use this option and return 1 in the case > > I've quotted. This is very problematic for me when I try to use a Debian > > service init script with HeartBeat that expects to receive a 0. > I'm reluctant to change the default behaviour of start-stop-daemon at this > point. What do other people think of making --oknodo the default behaviour > and adding a new option to force the current default behaviour (exit with > failure if nothing had to be done)? I think this sounds like there's no real transition plan between the two states; anything that actually relies on the current behavior of s-s-d without --oknodo will suddenly be broken. Changing the semantics of core tools in this way is a bad idea. The right answer is that we should be fixing the wrong init scripts, not trying to coerce all the init scripts with a change in s-s-d semantics. An init script may have a legitimate reason to want to check for the difference between exit statuses 0 and 1, without necessarily using this information a way that breaks the init script's own exit status, and changing s-s-d behavior will break these legitimate use cases. > The alternative is to change policy and/or lintian to ensure that packages > are using --oknodo unless they have a good reason not to. This was already discussed on debian-devel in March of this year. http://lists.debian.org/debian-devel/2008/03/msg00772.html Feel free to propose an amendment to policy that clarifies that "sensible" behavior is equivalent to --oknodo (without implying that init scripts are required to use s-s-d!), and I will happily second it; as I already commented in that thread, I think this is a mere clarification of what the policy has always been, not a change to policy at all. > > [1] LSB specifications about init script actions: > > http://www.linux-foundation.org/spec/refspecs/LSB_3.0.0/LSB-Core-generic/LSB-Core-generic/iniscrptact.html That one's starting to get up there right next to "our priorities are our users and free software" on my list of Facile Arguments That Demonstrate The Poster Has No Clue. :P -- Steve Langasek Give me a lever long enough and a Free OS Debian Developer to set it on, and I can move the world. Ubuntu Developerhttp://www.debian.org/ [EMAIL PROTECTED] [EMAIL PROTECTED] -- To UNSUBSCRIBE, email to [EMAIL PROTECTED] with a subject of "unsubscribe". Trouble? Contact [EMAIL PROTECTED]
Re: Bug#426877: dpkg: Option "--oknodo" should be the default behaviour for "start-stop-daemon" (LSB specs)
Right, expanding on my previous comments: On Thu, Jul 03, 2008 at 11:02:13PM +0200, Iñaki Baz Castillo wrote: > > The alternative is to change policy and/or lintian to ensure that packages > > are using --oknodo unless they have a good reason not to. > > > [1] LSB specifications about init script actions: > > > http://www.linux-foundation.org/spec/refspecs/LSB_3.0.0/LSB-Core-generic/ > > >LSB-Core-generic/iniscrptact.html > I think being LSB compliant is good for Debian. The LSB init script specification *is a specification for the init scripts of LSB packages*. It has NOTHING to do with LSB compliance of LSB implementations. Debian is an LSB *implementation*, NOT a collection of LSB applications. Conforming with the LSB init script specification would NOT make Debian packages conformant LSB applications! The LSB init script spec is a reasonable and internally consistent set of guidelines for init scripts. It's not a bad policy; in fact, 90% of it is word-for-word identical with the Debian init script policy. But the LSB init script spec is *not* the Debian init script policy, and we should not blindly seek conformance to an LSB *application* spec for its own sake. I happen to be in favor of seeing Debian adopt at least one feature of the LSB init script spec that we miss, which is the mandatory 'status' argument. But this needs to be adopted as part of Debian policy itself, through our normal procedures for such changes. Otherwise, we end up with maintainers blindly believing that everything in the LSB init script spec is a good idea, including things like this gem from 20.8: Conforming scripts shall not specify the "exit on error" option (i.e. set -e) when sourcing this file, or calling any of the commands thus made available. Blech. -- Steve Langasek Give me a lever long enough and a Free OS Debian Developer to set it on, and I can move the world. Ubuntu Developerhttp://www.debian.org/ [EMAIL PROTECTED] [EMAIL PROTECTED] -- To UNSUBSCRIBE, email to [EMAIL PROTECTED] with a subject of "unsubscribe". Trouble? Contact [EMAIL PROTECTED]
Re: Bug#426877: dpkg: Option "--oknodo" should be the default behaviour for "start-stop-daemon" (LSB specs)
On Thu, Jul 03, 2008 at 11:02:13PM +0200, Iñaki Baz Castillo wrote: > I think being LSB compliant is good for Debian. That may be so; but changing a long-standing interface with no migration is /not/ good for Debian. -- Home is where you have to wash the dishes. -- #debian-devel, Freenode, 2004-09-22 -- To UNSUBSCRIBE, email to [EMAIL PROTECTED] with a subject of "unsubscribe". Trouble? Contact [EMAIL PROTECTED]
Re: Bug#426877: dpkg: Option "--oknodo" should be the default behaviour for "start-stop-daemon" (LSB specs)
Hi, On Fri, 2008-07-04 at 01:47:39 -0700, Steve Langasek wrote: > > I think being LSB compliant is good for Debian. > > The LSB init script specification *is a specification for the init scripts > of LSB packages*. It has NOTHING to do with LSB compliance of LSB > implementations. Debian is an LSB *implementation*, NOT a collection of LSB > applications. Conforming with the LSB init script specification would NOT > make Debian packages conformant LSB applications! > > The LSB init script spec is a reasonable and internally consistent set of > guidelines for init scripts. It's not a bad policy; in fact, 90% of it is > word-for-word identical with the Debian init script policy. But the LSB > init script spec is *not* the Debian init script policy, and we should not > blindly seek conformance to an LSB *application* spec for its own sake. Agreed. > I happen to be in favor of seeing Debian adopt at least one feature of the > LSB init script spec that we miss, which is the mandatory 'status' argument. > But this needs to be adopted as part of Debian policy itself, through our > normal procedures for such changes. Yeah, this is something I've on my TODO list, most of the needed code is already on s-s-d. Will try to get something working this weekend. regards, guillem -- To UNSUBSCRIBE, email to [EMAIL PROTECTED] with a subject of "unsubscribe". Trouble? Contact [EMAIL PROTECTED]
Re: Bug#426877: dpkg: Option "--oknodo" should be the default behaviour for "start-stop-daemon" (LSB specs)
Steve Langasek wrote: >> I'm reluctant to change the default behaviour of start-stop-daemon at this >> point. What do other people think of making --oknodo the default behaviour >> and adding a new option to force the current default behaviour (exit with >> failure if nothing had to be done)? > > I think this sounds like there's no real transition plan between the two > states; anything that actually relies on the current behavior of s-s-d > without --oknodo will suddenly be broken. Changing the semantics of core > tools in this way is a bad idea. Here a proposal for a transition plan: Before lenny, start-stop-daemon can gain a new option that: - conflict with --oknodo (the new option can be called --no-oknodo for example) - enforce the current behavior with start-stop-daemon In sid, after lenny, start-stop-daemon can be changed to emit a warning if invoked without --oknodo or --no-oknodo. Maintainers must update their scripts. In lenny+1, (ie just before the release of lenny+1) start-stop-daemon revert the previous patch (ie does not show warnings) so that upgrade from lenny (maintainer script without --no-oknodo) to lenny+1 (maintainer scripts with --no-oknodo or --oknodo) does not trigger lots of warnings. In sid, after lenny+1, start-stop-daemon can fail if no option are given (or change its behavior). Another one is: Before lenny, start-stop-daemon can gain a new option that: - conflict with --oknodo (the new option can be called --no-oknodo for example) - enforce the current behavior with start-stop-daemon In sid, after lenny, lintian checks and warns if none of the two options is given. In both case, the goal is to ensure that the maintainer really choose the behavior he wants for start-stop-daemon > The right answer is that we should be fixing the wrong init scripts, not > trying to coerce all the init scripts with a change in s-s-d semantics. An > init script may have a legitimate reason to want to check for the > difference between exit statuses 0 and 1, without necessarily using this > information a way that breaks the init script's own exit status, and > changing s-s-d behavior will break these legitimate use cases. > >> The alternative is to change policy and/or lintian to ensure that packages >> are using --oknodo unless they have a good reason not to. > > This was already discussed on debian-devel in March of this year. > > http://lists.debian.org/debian-devel/2008/03/msg00772.html > > Feel free to propose an amendment to policy that clarifies that "sensible" > behavior is equivalent to --oknodo (without implying that init scripts are > required to use s-s-d!), and I will happily second it; as I already > commented in that thread, I think this is a mere clarification of what the > policy has always been, not a change to policy at all. > >>> [1] LSB specifications about init script actions: >>> http://www.linux-foundation.org/spec/refspecs/LSB_3.0.0/LSB-Core-generic/LSB-Core-generic/iniscrptact.html > > That one's starting to get up there right next to "our priorities are our > users and free software" on my list of Facile Arguments That Demonstrate The > Poster Has No Clue. :P > -- Vincent Danjean GPG key ID 0x9D025E87 [EMAIL PROTECTED] GPG key fingerprint: FC95 08A6 854D DB48 4B9A 8A94 0BF7 7867 9D02 5E87 Unofficial pacakges: http://www-id.imag.fr/~danjean/deb.html#package APT repo: deb http://perso.debian.org/~vdanjean/debian unstable main -- To UNSUBSCRIBE, email to [EMAIL PROTECTED] with a subject of "unsubscribe". Trouble? Contact [EMAIL PROTECTED]
Re: Bug#426877: dpkg: Option "--oknodo" should be the default behaviour for "start-stop-daemon" (LSB specs)
On Fri, 04 Jul 2008, Vincent Danjean wrote: > Steve Langasek wrote: > >> I'm reluctant to change the default behaviour of start-stop-daemon at this > >> point. What do other people think of making --oknodo the default behaviour > >> and adding a new option to force the current default behaviour (exit with > >> failure if nothing had to be done)? > > > > I think this sounds like there's no real transition plan between the two > > states; anything that actually relies on the current behavior of s-s-d > > without --oknodo will suddenly be broken. Changing the semantics of core > > tools in this way is a bad idea. > > Here a proposal for a transition plan: THanks, I could come up with a transition plan myself if needed. But compare your suggestions with: "someone goes over all init scripts, file bugs and in lenny+1 we're done". (No this is not something I intend to pursue, but anyone that cares could do and would probably be granted a release goal for this) The transition would be hugely complicated for little gains since most script already do what's needed. Cheers, -- Raphaël Hertzog Le best-seller français mis à jour pour Debian Etch : http://www.ouaza.com/livre/admin-debian/ -- To UNSUBSCRIBE, email to [EMAIL PROTECTED] with a subject of "unsubscribe". Trouble? Contact [EMAIL PROTECTED]
Re: Bug#426877: dpkg: Option "--oknodo" should be the default behaviour for "start-stop-daemon" (LSB specs)
On Sat, Jul 05, 2008 at 10:58:35AM +0200, Raphael Hertzog wrote: > THanks, I could come up with a transition plan myself if needed. But > compare your suggestions with: "someone goes over all init scripts, file > bugs and in lenny+1 we're done". That'll cause tremendous pain for backporters. I'm opposed. Greetings Marc -- - Marc Haber | "I don't trust Computers. They | Mailadresse im Header Mannheim, Germany | lose things."Winona Ryder | Fon: *49 621 72739834 Nordisch by Nature | How to make an American Quilt | Fax: *49 3221 2323190 -- To UNSUBSCRIBE, email to [EMAIL PROTECTED] with a subject of "unsubscribe". Trouble? Contact [EMAIL PROTECTED]
Re: Bug#426877: dpkg: Option "--oknodo" should be the default behaviour for "start-stop-daemon" (LSB specs)
On Sat, 05 Jul 2008, Marc Haber wrote: > On Sat, Jul 05, 2008 at 10:58:35AM +0200, Raphael Hertzog wrote: > > THanks, I could come up with a transition plan myself if needed. But > > compare your suggestions with: "someone goes over all init scripts, file > > bugs and in lenny+1 we're done". > > That'll cause tremendous pain for backporters. I'm opposed. You're opposed to what? Fixing non-policy compliant init script? I think you misunderstood. I don't want to change the default behaviour of start-stop-daemon and as such, there's no need for any transition. Cheers, -- Raphaël Hertzog Le best-seller français mis à jour pour Debian Etch : http://www.ouaza.com/livre/admin-debian/ -- To UNSUBSCRIBE, email to [EMAIL PROTECTED] with a subject of "unsubscribe". Trouble? Contact [EMAIL PROTECTED]
Re: Bug#426877: dpkg: Option "--oknodo" should be the default behaviour for "start-stop-daemon" (LSB specs)
Raphael Hertzog <[EMAIL PROTECTED]> writes: > On Sat, 05 Jul 2008, Marc Haber wrote: >> On Sat, Jul 05, 2008 at 10:58:35AM +0200, Raphael Hertzog wrote: >> > THanks, I could come up with a transition plan myself if needed. But >> > compare your suggestions with: "someone goes over all init scripts, file >> > bugs and in lenny+1 we're done". >> >> That'll cause tremendous pain for backporters. I'm opposed. > > You're opposed to what? Fixing non-policy compliant init script? > > I think you misunderstood. I don't want to change the default behaviour > of start-stop-daemon and as such, there's no need for any transition. Couldn't the default be changed once all init scripts have been fixed up? -- .''`. Roger Leigh : :' : Debian GNU/Linux http://people.debian.org/~rleigh/ `. `' Printing on GNU/Linux? http://gutenprint.sourceforge.net/ `-GPG Public Key: 0x25BFB848 Please GPG sign your mail. pgpNk0KhbHvof.pgp Description: PGP signature
Re: Bug#426877: dpkg: Option "--oknodo" should be the default behaviour for "start-stop-daemon" (LSB specs)
On Sat, Jul 05, 2008 at 11:58:17AM +0100, Roger Leigh wrote: > Raphael Hertzog <[EMAIL PROTECTED]> writes: > > On Sat, 05 Jul 2008, Marc Haber wrote: > >> On Sat, Jul 05, 2008 at 10:58:35AM +0200, Raphael Hertzog wrote: > >> > THanks, I could come up with a transition plan myself if needed. But > >> > compare your suggestions with: "someone goes over all init scripts, file > >> > bugs and in lenny+1 we're done". > >> That'll cause tremendous pain for backporters. I'm opposed. > > You're opposed to what? Fixing non-policy compliant init script? > > I think you misunderstood. I don't want to change the default behaviour > > of start-stop-daemon and as such, there's no need for any transition. > Couldn't the default be changed once all init scripts have been fixed > up? No, because "fixed up" does not imply "switched to use --oknodo". It only means *checking* the return value of s-s-d and handling it in a policy-compliant manner; this is done for you if you use --oknodo, but you don't have to use --oknodo and it's not appropriate for dpkg to break scripts that don't use --oknodo but are policy compliant. -- Steve Langasek Give me a lever long enough and a Free OS Debian Developer to set it on, and I can move the world. Ubuntu Developerhttp://www.debian.org/ [EMAIL PROTECTED] [EMAIL PROTECTED] -- To UNSUBSCRIBE, email to [EMAIL PROTECTED] with a subject of "unsubscribe". Trouble? Contact [EMAIL PROTECTED]
Re: Bug#426877: dpkg: Option "--oknodo" should be the default behaviour for "start-stop-daemon" (LSB specs)
On Sat, 5 Jul 2008 12:13:27 +0200, Raphael Hertzog <[EMAIL PROTECTED]> wrote: >On Sat, 05 Jul 2008, Marc Haber wrote: >> On Sat, Jul 05, 2008 at 10:58:35AM +0200, Raphael Hertzog wrote: >> > THanks, I could come up with a transition plan myself if needed. But >> > compare your suggestions with: "someone goes over all init scripts, file >> > bugs and in lenny+1 we're done". >> >> That'll cause tremendous pain for backporters. I'm opposed. > >You're opposed to what? Reversing s-s-d's behavior from lenny to lenny+1. >I think you misunderstood. I don't want to change the default behaviour >of start-stop-daemon and as such, there's no need for any transition. I see... Greetings Marc -- -- !! No courtesy copies, please !! - Marc Haber | " Questions are the | Mailadresse im Header Mannheim, Germany | Beginning of Wisdom " | http://www.zugschlus.de/ Nordisch by Nature | Lt. Worf, TNG "Rightful Heir" | Fon: *49 621 72739834 -- To UNSUBSCRIBE, email to [EMAIL PROTECTED] with a subject of "unsubscribe". Trouble? Contact [EMAIL PROTECTED]
Re: Bug#426877: dpkg: Option "--oknodo" should be the default behaviour for "start-stop-daemon" (LSB specs)
Marc Haber wrote: > On Sat, Jul 05, 2008 at 10:58:35AM +0200, Raphael Hertzog wrote: >> THanks, I could come up with a transition plan myself if needed. But >> compare your suggestions with: "someone goes over all init scripts, file >> bugs and in lenny+1 we're done". > > That'll cause tremendous pain for backporters. I'm opposed. My main idea (with or without trasition plan) is to have an option (for example --no-oknodo) in lenny allowing maintainer to tell he wants the current behavior of start-stop-deamon. Whether warning are generated or not, bugs filled or not, lintian complains or not, default behavior changed or not, ... is not really important for my point of view (and can be decided after lenny) *iff* the option already exists in lenny (else, we will have to wait for lenny+1) Regards, Vincent -- Vincent Danjean GPG key ID 0x9D025E87 [EMAIL PROTECTED] GPG key fingerprint: FC95 08A6 854D DB48 4B9A 8A94 0BF7 7867 9D02 5E87 Unofficial pacakges: http://www-id.imag.fr/~danjean/deb.html#package APT repo: deb http://perso.debian.org/~vdanjean/debian unstable main -- To UNSUBSCRIBE, email to [EMAIL PROTECTED] with a subject of "unsubscribe". Trouble? Contact [EMAIL PROTECTED]