Bug 15066 - ``allscreens_flags'' in rc.conf not documented; produces unexpected results
Summary: ``allscreens_flags'' in rc.conf not documented; produces unexpected results
Status: Closed FIXED
Alias: None
Product: Base System
Classification: Unclassified
Component: misc (show other bugs)
Version: 3.3-STABLE
Hardware: Any Any
: Normal Affects Only Me
Assignee: Sheldon Hearn
URL:
Keywords:
Depends on:
Blocks:
 
Reported: 1999-11-23 22:00 UTC by Andy Farkas
Modified: 2000-03-27 11:14 UTC (History)
0 users

See Also:


Attachments

Note You need to log in before you can comment on or make changes to this bug.
Description Andy Farkas 1999-11-23 22:00:01 UTC
Firstly, ``allscreens_flags'' is not documented in rc.conf(5).

Secondly, with the following options set in rc.conf:

  font8x8="iso-8x8.fnt"
  allscreens_flags="-r black green 80x60 green black"

all ttyv's switch to 80x60 mode, but only ttyv0 gets the colour changed.

Fix: 

/etc/rc.i386 looks like it attempts to do the right thing with regards
to applying vidcontrol to /dev/ttyv*, but I guess the redirection may
have something to do with it.
How-To-Repeat: Add the above mentioned ``font8x8'' and ``allscreens_flags'' to your
rc.conf file.  Reboot, then notice only ttyv0 is green.
Comment 1 yokota 1999-11-28 07:57:41 UTC
>>Number:         15066
>>Category:       misc
>>Synopsis:       ``allscreens_flags'' in rc.conf not documented; produces unex
>pected results
[...]
>>Originator:     Andy Farkas
>>Release:        3.3-STABLE, 4.0-CURRENT
>>Organization:
>Speednet Communications
>>Environment:
>>Description:
>Firstly, ``allscreens_flags'' is not documented in rc.conf(5).
>
>Secondly, with the following options set in rc.conf:
>
>  font8x8="iso-8x8.fnt"
>  allscreens_flags="-r black green 80x60 green black"
>
>all ttyv's switch to 80x60 mode, but only ttyv0 gets the colour changed.
>
>>How-To-Repeat:
>Add the above mentioned ``font8x8'' and ``allscreens_flags'' to your
>rc.conf file.  Reboot, then notice only ttyv0 is green.
>
>>Fix:
>/etc/rc.i386 looks like it attempts to do the right thing with regards
>to applying vidcontrol to /dev/ttyv*, but I guess the redirection may
>have something to do with it.

The following patch to /etc/rc.i386 should fix it.  

Kazu

<<The patch for -CURRENT>>

Index: rc.i386
===================================================================
RCS file: /src/CVS/src/etc/etc.i386/rc.i386,v
retrieving revision 1.47
diff -u -r1.47 rc.i386
--- rc.i386	1999/09/15 11:17:59	1.47
+++ rc.i386	1999/11/28 07:57:44
@@ -204,7 +204,7 @@
 if [ -n "${allscreens_flags}" ]; then
 	echo -n ' allscreens'
 	for ttyv in /dev/ttyv*; do
-		vidcontrol < ${ttyv} ${allscreens_flags}
+		vidcontrol < ${ttyv} ${allscreens_flags} > ${ttyv} 2>&1
 	done
 fi
 



<<The patch for -STABLE>>

Index: rc.i386
===================================================================
RCS file: /src/CVS/src/etc/etc.i386/rc.i386,v
retrieving revision 1.37.2.5
diff -u -r1.37.2.5 rc.i386
--- rc.i386	1999/09/15 17:43:08	1.37.2.5
+++ rc.i386	1999/11/28 07:59:28
@@ -116,7 +116,7 @@
 	echo -n ' allscreens'
 	for ttyv in /dev/ttyv*
 	do
-		vidcontrol <$ttyv ${allscreens_flags}
+		vidcontrol <$ttyv ${allscreens_flags} >$ttyv 2>&1
 	done
 fi
 echo '.'
Comment 2 Andy Farkas 1999-11-28 12:43:45 UTC
> The following patch to /etc/rc.i386 should fix it.  

Yes, it does (tested on -current).  

Thank you.

> 
> Kazu
> 

--
 
 :{ andyf@speednet.com.au
  
        Andy Farkas
    System Administrator
   Speednet Communications
 http://www.speednet.com.au/
Comment 3 Sheldon Hearn freebsd_committer freebsd_triage 1999-12-21 11:43:44 UTC
State Changed
From-To: open->suspended

Fixed in CURRENT's rev 1.48 of rc.i386 and RELENG_3's rev 1.37.2.6 . 
I've documented the flag in CURRENT's rev 1.59 of rc.conf.5, but I'll 
wait a few days for objections before I MFC the change. 


Comment 4 Sheldon Hearn freebsd_committer freebsd_triage 1999-12-21 11:43:44 UTC
Responsible Changed
From-To: freebsd-bugs->sheldonh

Reminder for me. :-) 
Comment 5 Sheldon Hearn freebsd_committer freebsd_triage 2000-03-27 11:14:12 UTC
State Changed
From-To: suspended->closed

Merged onto the RELENG_3 branch.  Herendethelesson.