[Bug 619246] Re: invoke-rc.d don't return same anwswer when the variable RUNLEVEL is setup at boot time

2011-06-06 Thread Launchpad Bug Tracker
This bug was fixed in the package sysvinit - 2.87dsf-4ubuntu17.3

---
sysvinit (2.87dsf-4ubuntu17.3) lucid-proposed; urgency=low

  * debian/sysv-rc/sbin/invoke-rc.d: replace RUNLEVEL with RUNLEVELHELPER.
Using RUNLEVEL causes spurious failures when invoke-rc.d is invoked
with RUNLEVEL already defined in the environment (as it is e.g. during
bootup) since invoke-rc.d's RUNLEVEL will become an exported variable
at that point and cause /sbin/runlevel to return bad data. (LP: #619246)
 -- James Troup james.tr...@canonical.com   Tue, 24 May 2011 11:41:45 +

** Changed in: sysvinit (Ubuntu Lucid)
   Status: Fix Committed = Fix Released

-- 
You received this bug notification because you are a member of Ubuntu
Bugs, which is subscribed to Ubuntu.
https://bugs.launchpad.net/bugs/619246

Title:
  invoke-rc.d don't return same anwswer when the variable RUNLEVEL is
  setup at boot time

-- 
ubuntu-bugs mailing list
ubuntu-bugs@lists.ubuntu.com
https://lists.ubuntu.com/mailman/listinfo/ubuntu-bugs


[Bug 619246] Re: invoke-rc.d don't return same anwswer when the variable RUNLEVEL is setup at boot time

2011-05-31 Thread LaMont Jones
2.87dsf-4ubuntu17.3 behaves as expected for us.

-- 
You received this bug notification because you are a member of Ubuntu
Bugs, which is subscribed to Ubuntu.
https://bugs.launchpad.net/bugs/619246

Title:
  invoke-rc.d don't return same anwswer when the variable RUNLEVEL is
  setup at boot time

-- 
ubuntu-bugs mailing list
ubuntu-bugs@lists.ubuntu.com
https://lists.ubuntu.com/mailman/listinfo/ubuntu-bugs


[Bug 619246] Re: invoke-rc.d don't return same anwswer when the variable RUNLEVEL is setup at boot time

2011-05-31 Thread Jean-Baptiste Lallement
thanks for testing. marking as verification-done

** Tags added: verification-done
** Tags removed: verification-needed

-- 
You received this bug notification because you are a member of Ubuntu
Bugs, which is subscribed to Ubuntu.
https://bugs.launchpad.net/bugs/619246

Title:
  invoke-rc.d don't return same anwswer when the variable RUNLEVEL is
  setup at boot time

-- 
ubuntu-bugs mailing list
ubuntu-bugs@lists.ubuntu.com
https://lists.ubuntu.com/mailman/listinfo/ubuntu-bugs


[Bug 619246] Re: invoke-rc.d don't return same anwswer when the variable RUNLEVEL is setup at boot time

2011-05-29 Thread Martin Pitt
Accepted sysvinit into lucid-proposed, the package will build now and be
available in a few hours. Please test and give feedback here. See
https://wiki.ubuntu.com/Testing/EnableProposed for documentation how to
enable and use -proposed. Thank you in advance!

** Changed in: sysvinit (Ubuntu Lucid)
   Status: Confirmed = Fix Committed

** Tags added: verification-needed

-- 
You received this bug notification because you are a member of Ubuntu
Bugs, which is subscribed to Ubuntu.
https://bugs.launchpad.net/bugs/619246

Title:
  invoke-rc.d don't return same anwswer when the variable RUNLEVEL is
  setup at boot time

-- 
ubuntu-bugs mailing list
ubuntu-bugs@lists.ubuntu.com
https://lists.ubuntu.com/mailman/listinfo/ubuntu-bugs


[Bug 619246] Re: invoke-rc.d don't return same anwswer when the variable RUNLEVEL is setup at boot time

2011-05-26 Thread Launchpad Bug Tracker
This bug was fixed in the package sysvinit - 2.87dsf-4ubuntu24

---
sysvinit (2.87dsf-4ubuntu24) oneiric; urgency=low

  * debian/sysv-rc/sbin/invoke-rc.d: replace RUNLEVEL with RUNLEVELHELPER.
Using RUNLEVEL causes spurious failures when invoke-rc.d is invoked
with RUNLEVEL already defined in the environment (as it is e.g. during
bootup) since invoke-rc.d's RUNLEVEL will become an exported variable
at that point and cause /sbin/runlevel to return bad data. (LP: #619246)
 -- James Troup james.tr...@canonical.com   Tue, 24 May 2011 11:41:45 +

** Changed in: sysvinit (Ubuntu)
   Status: Confirmed = Fix Released

-- 
You received this bug notification because you are a member of Ubuntu
Bugs, which is subscribed to Ubuntu.
https://bugs.launchpad.net/bugs/619246

Title:
  invoke-rc.d don't return same anwswer when the variable RUNLEVEL is
  setup at boot time

-- 
ubuntu-bugs mailing list
ubuntu-bugs@lists.ubuntu.com
https://lists.ubuntu.com/mailman/listinfo/ubuntu-bugs


[Bug 619246] Re: invoke-rc.d don't return same anwswer when the variable RUNLEVEL is setup at boot time

2011-05-26 Thread Dave Walker
** Also affects: sysvinit (Ubuntu Lucid)
   Importance: Undecided
   Status: New

** Changed in: sysvinit (Ubuntu Lucid)
   Status: New = Confirmed

** Changed in: sysvinit (Ubuntu Lucid)
 Assignee: (unassigned) = Dave Walker (davewalker)

-- 
You received this bug notification because you are a member of Ubuntu
Bugs, which is subscribed to Ubuntu.
https://bugs.launchpad.net/bugs/619246

Title:
  invoke-rc.d don't return same anwswer when the variable RUNLEVEL is
  setup at boot time

-- 
ubuntu-bugs mailing list
ubuntu-bugs@lists.ubuntu.com
https://lists.ubuntu.com/mailman/listinfo/ubuntu-bugs


[Bug 619246] Re: invoke-rc.d don't return same anwswer when the variable RUNLEVEL is setup at boot time

2011-05-26 Thread Dave Walker
** Description changed:

  Binary package hint: sysvinit
  
- puppet tool uses invoke-rc.d to determine if a service is launched at boot 
time. But at boot time, a variable RUNLEVEL is setup and invoke-rc.d doesn't 
work after that :
- We can try :
+ IMPACT: puppet tool uses invoke-rc.d to determine if a service is
+ launched at boot time. But at boot time, a variable RUNLEVEL is setup
+ and invoke-rc.d doesn't work after that.
+ 
+ FIX: have invoke-rc.d to use 'RUNLEVELHELPER' as the variable name for
+ the full path to the runlevel(8) binary instead of 'RUNLEVEL'.
+ 
+ PATCH: See comment #3, or diff for (2.87dsf-4ubuntu24) oneiric.
+ 
+ REPRODUCE: 
  RUNLEVEL=2 bash -x /usr/sbin/invoke-rc.d --quiet --query ssh start
  - we can see an exit 105
  but :
  bash -x /usr/sbin/invoke-rc.d --quiet --query ssh start
  - we can see an exit 104 (the good answer)
  
  With debian lenny :
  RUNLEVEL=2 bash -x /usr/sbin/invoke-rc.d --quiet --query ssh start
  - we can see an exit 104
+ 
+ DISCUSSION: Regression potential is low, it is a back-ported fix from
+ oneiric.  This fix is currently in production use on some Canonical
+ Lucid servers.

-- 
You received this bug notification because you are a member of Ubuntu
Bugs, which is subscribed to Ubuntu.
https://bugs.launchpad.net/bugs/619246

Title:
  invoke-rc.d don't return same anwswer when the variable RUNLEVEL is
  setup at boot time

-- 
ubuntu-bugs mailing list
ubuntu-bugs@lists.ubuntu.com
https://lists.ubuntu.com/mailman/listinfo/ubuntu-bugs


[Bug 619246] Re: invoke-rc.d don't return same anwswer when the variable RUNLEVEL is setup at boot time

2011-05-24 Thread James Troup
** Attachment added: Patch to switch invoke-rc.d to RUNLEVELHELPER
   
https://bugs.launchpad.net/ubuntu/+source/sysvinit/+bug/619246/+attachment/2140788/+files/debdiff

-- 
You received this bug notification because you are a member of Ubuntu
Bugs, which is subscribed to Ubuntu.
https://bugs.launchpad.net/bugs/619246

Title:
  invoke-rc.d don't return same anwswer when the variable RUNLEVEL is
  setup at boot time

-- 
ubuntu-bugs mailing list
ubuntu-bugs@lists.ubuntu.com
https://lists.ubuntu.com/mailman/listinfo/ubuntu-bugs


[Bug 619246] Re: invoke-rc.d don't return same anwswer when the variable RUNLEVEL is setup at boot time

2011-05-24 Thread James Troup
This bug is still present in Oneiric.

The root cause is that invoke-rc.d misuses 'RUNLEVEL' as a local
variable for the full path to the runlevel(8) binary.  As long as
'RUNLEVEL' isn't defined in the environment this doesn't have any
particular ill effects.  However, if 'RUNLEVEL' is defined in the
environment (as it is during bootup), the local variable gets marked
for export[1] and thus when runlevel(8) is invoked it sees RUNLEVEL as
'/sbin/runlevel' which causes it to give bad output ('/ N').

One easy/obvious way to avoid this is to have invoke-rc.d to use
'RUNLEVELHELPER' as the variable name for the full path to the
runlevel(8) binary instead of 'RUNLEVEL'.

I've attached a debdiff which does this and I've tested patched
packages on both lucid (server) and natty (desktop), including a full
reboot cycle.  It both fixes the originally reported problem and
doesn't seem to introduce any other problems.  It'd be nice if we
could get this into Oneiric and then SRU it into Lucid (as the current
and affected LTS).

[1] 
http://pubs.opengroup.org/onlinepubs/9699919799/utilities/V3_chap02.html#tag_18_05_03
[With thanks to Colin Watson and Robert Collins.]


** Changed in: sysvinit (Ubuntu)
   Status: New = Confirmed

-- 
You received this bug notification because you are a member of Ubuntu
Bugs, which is subscribed to Ubuntu.
https://bugs.launchpad.net/bugs/619246

Title:
  invoke-rc.d don't return same anwswer when the variable RUNLEVEL is
  setup at boot time

-- 
ubuntu-bugs mailing list
ubuntu-bugs@lists.ubuntu.com
https://lists.ubuntu.com/mailman/listinfo/ubuntu-bugs


[Bug 619246] Re: invoke-rc.d don't return same anwswer when the variable RUNLEVEL is setup at boot time

2010-10-20 Thread Dan Urist
I can confirm this bug. I've also confirmed that the bug doesn't exist
in jaunty, so is definitely new (since switch to upstart?). This
probably affects other services besides puppet, since invoke-rc.d is
supposed to be the interface to sysv init. From the debian policy
manual:

 9.3.3 Interfacing with the initscript system

 Maintainers should use the abstraction layer provided by the update-rc.d and 
 invoke-rc.d programs to deal 
 with initscripts in their packages' scripts such as postinst, prerm and 
 postrm.

 Directly managing the /etc/rc?.d links and directly invoking the /etc/init.d/ 
 initscripts should be done only 
 by packages providing the initscript subsystem (such as sysv-rc and file-rc).

-- 
invoke-rc.d don't return same anwswer when the variable RUNLEVEL is setup at 
boot time
https://bugs.launchpad.net/bugs/619246
You received this bug notification because you are a member of Ubuntu
Bugs, which is subscribed to Ubuntu.

-- 
ubuntu-bugs mailing list
ubuntu-bugs@lists.ubuntu.com
https://lists.ubuntu.com/mailman/listinfo/ubuntu-bugs


[Bug 619246] Re: invoke-rc.d don't return same anwswer when the variable RUNLEVEL is setup at boot time

2010-08-24 Thread Christophe GUILLOUX
** Description changed:

  Binary package hint: sysvinit
  
  puppet tool uses invoke-rc.d to determine if a service is launched at boot 
time. But at boot time, a variable RUNLEVEL is setup and invoke-rc.d doesn't 
work after that :
- We can test :
+ We can try :
  RUNLEVEL=2 bash -x /usr/sbin/invoke-rc.d --quiet --query ssh start
  - we can see an exit 105
  but :
  bash -x /usr/sbin/invoke-rc.d --quiet --query ssh start
  - we can see an exit 104 (the good answer)
  
  With debian lenny :
  RUNLEVEL=2 bash -x /usr/sbin/invoke-rc.d --quiet --query ssh start
  - we can see an exit 104

-- 
invoke-rc.d don't return same anwswer when the variable RUNLEVEL is setup at 
boot time
https://bugs.launchpad.net/bugs/619246
You received this bug notification because you are a member of Ubuntu
Bugs, which is subscribed to Ubuntu.

-- 
ubuntu-bugs mailing list
ubuntu-bugs@lists.ubuntu.com
https://lists.ubuntu.com/mailman/listinfo/ubuntu-bugs