Subject: install/13249: i386 serial console install does not enable logins on the serial port
To: None <gnats-bugs@gnats.netbsd.org>
From: None <nathanw@mit.edu>
List: netbsd-bugs
Date: 06/19/2001 14:11:25
>Number:         13249
>Category:       install
>Synopsis:       i386 serial console install does not enable logins on the serial port
>Confidential:   no
>Severity:       serious
>Priority:       medium
>Responsible:    install-manager
>State:          open
>Class:          sw-bug
>Submitter-Id:   net
>Arrival-Date:   Tue Jun 19 11:10:00 PDT 2001
>Closed-Date:
>Last-Modified:
>Originator:     Nathan J. Williams
>Release:        20010526-1.5V snapshot
>Organization:
	
>Environment:
	
System: NetBSD daffy-duck.putnam 1.5W NetBSD 1.5W (DAFFY-DUCK) #148: Fri Jun 15 14:13:03 EDT 2001 nathanw@daffy-duck.putnam:/u1/nbsd/src/sys/arch/alpha/compile/DAFFY-DUCK alpha
Architecture: alpha
Machine: alpha
>Description:

After installing a serial-port-only system with the boot-com floppy
set (which is a great feature), I found that getty had not been
enabled on the serial console of the system, forcing me to reboot
uncleanly and start in single-user mode to regain access. Yuck.

>How-To-Repeat:
	Install with the serial-console floppies. Reboot. Note the
lack of a login prompt at the serial console, which is awkward if
there's no video console.

>Fix:
Something like the following patch to distrib/utils/sysinst/arch/i386/md.c:

*** md.c	2001/01/27 07:34:39	1.55
--- md.c	2001/06/19 18:06:31
***************
*** 464,469 ****
--- 464,483 ----
  	do_system(cmd);
  
  	run_prog(RUN_FATAL, NULL, "mv -f %s %s", realto, realfrom);
+ 
+ 	/* If we're installing on a serial console, enable logins on the
+ 	 * serial port.
+ 	 */
+ 	if (strcmp(boottype, "serial") == 0) {
+ 		strncpy(realfrom, target_expand("/etc/ttys"), STRSIZE);
+ 		strncpy(realto, target_expand("/etc/ttys.install"), STRSIZE);
+ 		sprintf(cmd, "sed "
+ 				"-e '/^tty00/s/off/on/'"
+ 				" < %s > %s", realfrom, realto);
+ 		scripting_fprintf(log, "%s\n", cmd);
+ 		do_system(cmd);
+ 		run_prog(RUN_FATAL, NULL, "mv -f %s %s", realto, realfrom);
+ 	}
  	
  	add_rc_conf("wscons=YES");
  


>Release-Note:
>Audit-Trail:
>Unformatted: