25configure_init uses /dev/ttyN.conf instead of /dev/ttyN for /etc/init/tty*.conf mangling

Bug #438678 reported by Oliver Grawert on 2009-09-29
16
This bug affects 2 people
Affects Status Importance Assigned to Milestone
casper (Ubuntu)
Medium
Colin Watson
Karmic
Medium
Colin Watson

Bug Description

Binary package hint: casper

the change in http://bazaar.launchpad.net/~ubuntu-core-dev/casper/trunk/revision/696 is inclomplete.
due to adding a .conf suffix to the upstart job files, /etc/init/tty*.conf ends up with a line like:

exec /bin/login -f ubuntu </dev/tty1.conf > /dev/tty1.conf 2>&1

this results in dying tty processes on live images.
the suffix needs to be dropped in the sed command of the above mentioned code

Oliver Grawert (ogra) on 2009-09-29
Changed in casper (Ubuntu Karmic):
milestone: none → ubuntu-9.10
importance: Undecided → Medium
Evan (ev) on 2009-09-29
Changed in casper (Ubuntu Karmic):
status: New → Confirmed
Colin Watson (cjwatson) on 2009-09-29
Changed in casper (Ubuntu Karmic):
assignee: nobody → Colin Watson (cjwatson)
status: Confirmed → Fix Committed
description: updated
Launchpad Janitor (janitor) wrote :

This bug was fixed in the package casper - 1.197

---------------
casper (1.197) karmic; urgency=low

  [ Colin Watson ]
  * Fix tty device name construction to work with new upstart (LP: #438678).

  [ Loïc Minier ]
  * scripts/casper-bottom/22serialtty: pass -L to getty and set term to vt100.
  * scripts/casper-bottom/22serialtty: set +x...

 -- Colin Watson <email address hidden> Thu, 01 Oct 2009 23:27:45 +0100

Changed in casper (Ubuntu Karmic):
status: Fix Committed → Fix Released
Michael Lazarev (milaz) wrote :

If fix was released 2009-10-02, how come that I did partial upgrade on my live USB yesterday, 2009-10-09, and my manually changed file /etc/init/tty2.conf was restored to the previous state?

After clan install the file contents were:
----------------------------------------------------------------------------------------
# tty2 - getty
#
# This service maintains a getty on tty2 from the point the system is
# started until it is shut down again.

start on runlevel [23]
stop on runlevel [!23]

respawn
exec /bin/login -f ubuntu </dev/tty2.conf > /dev/tty2.conf 2>&1
----------------------------------------------------------------------------------------

I manually changed the last line so that there was:
----------------------------------------------------------------------------------------
# tty2 - getty
#
# This service maintains a getty on tty2 from the point the system is
# started until it is shut down again.

start on runlevel [23]
stop on runlevel [!23]

respawn
exec /sbin/getty 115200 tty2
#exec /bin/login -f ubuntu </dev/tty2.conf > /dev/tty2.conf 2>&1
----------------------------------------------------------------------------------------

Then I ran partial upgrade, and finally the file was
----------------------------------------------------------------------------------------
# tty2 - getty
#
# This service maintains a getty on tty2 from the point the system is
# started until it is shut down again.

start on runlevel [23]
stop on runlevel [!23]

respawn
exec /bin/login -f ubuntu </dev/tty2.conf > /dev/tty2.conf 2>&1

#exec /bin/login -f ubuntu </dev/tty2.conf > /dev/tty2.conf 2>&1
----------------------------------------------------------------------------------------

On Sat, Oct 10, 2009 at 11:58:26AM -0000, Michael Lazarev wrote:
> If fix was released 2009-10-02, how come that I did partial upgrade on
> my live USB yesterday, 2009-10-09, and my manually changed file
> /etc/init/tty2.conf was restored to the previous state?

Upgrades of live images are a bit odd. The fix for this is applied at
*boot time*, and whether upgrades will preserve that is a bit of a
guessing game really.

I see, but does it matter that the file was not reverted to original
one, it was changed by upgrade again?

What I am afraid of is not special cases of live images, but that
there's a code in some .deb that stubbornly puts that nasty "exec
/bin/login -f ubuntu </dev/tty2.conf > /dev/tty2.conf 2>&1" line into
/etc/init/ttyX files again and again. If I had a hint where to look
for it, I'd tried to check this.

Colin Watson (cjwatson) wrote :

Did you upgrade casper, regenerate the initramfs, and - most crucially - put the initramfs in the place where it's actually booted from, which may not be the same as the place that the upgrade writes it to? An upgrade probably won't do the last bit by itself. This is one place where upgrading live images is notably tricky.

Michael Lazarev (milaz) wrote :

No, I didin't do such a black magic :)

Anyway, I recently checked 9.10 RC, consoles are back. So, the part of
the problem I was concerned with is resolved. Also, Evan Dandrea fixed
bug 450259 about updating initramfs on live USB.

tags: added: iso-testing
To post a comment you must log in.
This report contains Public information  Edit
Everyone can see this information.

Other bug subscribers