Bug 97188 - Incorrect tty search when setting console fonts at boot time
Incorrect tty search when setting console fonts at boot time
Product: Red Hat Linux
Classification: Retired
Component: initscripts (Show other bugs)
All Linux
low Severity low
: ---
: ---
Assigned To: Bill Nottingham
Brock Organ
: 116514 (view as bug list)
Depends On:
  Show dependency treegraph
Reported: 2003-06-11 08:02 EDT by Tarhon-Onu Victor
Modified: 2014-03-16 22:36 EDT (History)
2 users (show)

See Also:
Fixed In Version: 7.25-1
Doc Type: Bug Fix
Doc Text:
Story Points: ---
Clone Of:
Last Closed: 2003-06-11 12:11:20 EDT
Type: ---
Regression: ---
Mount Type: ---
Documentation: ---
Verified Versions:
Category: ---
oVirt Team: ---
RHEL 7.3 requirements from Atomic Host:
Cloudforms Team: ---

Attachments (Terms of Use)

  None (edit)
Description Tarhon-Onu Victor 2003-06-11 08:02:24 EDT
From Bugzilla Helper:
User-Agent: Mozilla/5.0 (X11; U; Linux i686; en-US; rv:1.4) Gecko/20030611

Description of problem:
In rc.sysinit, begining with line 37:

== cut ==
if [ "`/sbin/consoletype`" = "vt" -a -x /sbin/setsysfont ]; then
   for i in `LC_ALL=C grep '^[0-9]*.*respawn:/sbin/mingetty' /etc/inittab | sed
's/^.* tty\([0-9][0-9]*\).*/\1/g'`; do
      > /dev/tty$i
== cut ==

The regular expression should be: '^[0-9].*respawn:/sbin/mingetty' instead. The
'*' after [0-9] means 0 digits or more, so if there are lines containing
respawn:/sbin/mingetty that will also match the regular expression, causing
unexistent ttys to be written.

Version-Release number of selected component (if applicable):
initscripts-7.24 and older

How reproducible:

Steps to Reproduce:
1. in inittab add a comment before a line coresponding to a tty that should pe
initialised in standard runlevels;
2. grep '^[0-9]*.*respawn:/sbin/mingetty' /etc/inittab
3. grep '^[0-9].*respawn:/sbin/mingetty' /etc/inittab
 and compare outputs.

Actual Results:  The output for the grep run at 2. will contain also the
commented line(s) that contain 'respawn:/sbin/mingetty'' string.

Additional info:

This can be anoying then you comment lines in inittab for ttys that where
deleted (let's say you created tty30 for testing purposes and then you deleted)
or are used for other purposes than logging in (logs, whatever).
Comment 1 Bill Nottingham 2003-06-11 12:11:20 EDT
Fixed in CVS, will be in 7.25-1, thanks!
Comment 2 Bill Nottingham 2004-02-22 00:48:32 EST
*** Bug 116514 has been marked as a duplicate of this bug. ***

Note You need to log in before you can comment on or make changes to this bug.