Bug 97188 - Incorrect tty search when setting console fonts at boot time
Summary: Incorrect tty search when setting console fonts at boot time
Alias: None
Product: Red Hat Linux
Classification: Retired
Component: initscripts (Show other bugs)
(Show other bugs)
Version: 9
Hardware: All Linux
Target Milestone: ---
Assignee: Bill Nottingham
QA Contact: Brock Organ
: 116514 (view as bug list)
Depends On:
TreeView+ depends on / blocked
Reported: 2003-06-11 12:02 UTC by Tarhon-Onu Victor
Modified: 2014-03-17 02:36 UTC (History)
2 users (show)

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

Attachments (Terms of Use)

Description Tarhon-Onu Victor 2003-06-11 12:02:24 UTC
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 16:11:20 UTC
Fixed in CVS, will be in 7.25-1, thanks!

Comment 2 Bill Nottingham 2004-02-22 05:48:32 UTC
*** 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.