[Thiemo Seufer]
> Testing is broken due to exim4, yesterdays unstable works mostly but
> showed the "unconfigured fstab" problem, and failed to add an inittab
> entry for serial console.
The serial console thing *should* be fixed by a patch I sent to joshk
the other day. He said he'd review it before committing it, but I
suppose more eyeballs would be a Good Thing - I've only tested it on
sparc.
Peter
Index: packages/prebaseconfig/prebaseconfig.d/90prepare-base-config
===================================================================
--- packages/prebaseconfig/prebaseconfig.d/90prepare-base-config (revision 12001)
+++ packages/prebaseconfig/prebaseconfig.d/90prepare-base-config (working copy)
@@ -13,12 +13,19 @@
echo "SUITE=\"$SUITE\""
) >> /target/root/dbootstrap_settings
-console=$(chroot /target tty | sed 's/\/dev\///g')
+# Since this script is running with debconf, 'tty' does
+# not give reliable answers about what sort of terminal
+# we have. The stdin of /sbin/debian-installer seems
+# to tell the truth.
+console_=$(readlink /proc/$(pidof debian-installer)/fd/0)
+console=$(mapdevfs "$console_")
+console_=${console_#/dev/}
+console=${console#/dev/}
case "$console" in
ttyS*)
ttyspeed=$(chroot /target stty speed)
- ttyline=$(echo "$console" | sed 's/^ttyS//')
+ ttyline=${console#ttyS}
ttyterm="$TERM"
if [ -z "$ttyterm" ]; then ttyterm=vt100; fi
@@ -27,8 +34,11 @@
-e "s/^\([1-6]\):/#\1:/" \
-e "s/^#T0\(.*ttyS\).*/T$ttyline\1$ttyline $ttyspeed $ttyterm/" \
> /target/etc/inittab.real
- echo "# $console added by debian-installer" >> /target/etc/securetty
- echo "$console" >> /target/etc/securetty
+ echo "# serial console added by debian-installer" >> /target/etc/securetty
+ echo "$console_" >> /target/etc/securetty
+ if [ -n "$console" ] && [ "$console" != "$console_" ]; then
+ echo "$console" >> /target/etc/securetty
+ fi
;;
*)
# graphical console, leave inittab alone
Attachment:
signature.asc
Description: Digital signature