Bug#549317: sed: can't read /etc/inittab: No such file or directory

2009-10-04 Thread Michael Schutte
tag 549317 + patch
thanks

Hi Jussi!

On Fri, Oct 02, 2009 at 03:05:53PM +0300, Jussi Myllykoski wrote:
 I get this message on boot:
 
 
 Setting console screen modes
 sed: can't read /etc/inittab: No such file or directory
 
 
 This is on a system where sysvinit has been replaced with upstart,
 so if I understand correctly the data that used to be in /etc/inittab
 is now in several files found at /etc/init/
 
 This isn't a showstopper by any means, just something that I thought
 might be good to bring to your attention (if it isn't already).

Thanks a lot for your report.  Init systems seem to be kbd’s greatest
enemy :-)

May I ask you to apply the attached patch to your local copy of
/etc/init.d/kbd and confirm that it works?  The solution isn’t perfect
since it’s theoretically possible that gettys are started from files
other than /etc/init/tty*.conf, but I guess it is good enough for most
cases.

Cheers,
-- 
Michael Schutte mi...@uiae.at
--- /etc/init.d/kbd~
+++ /etc/init.d/kbd
@@ -119,7 +119,13 @@ setup ()
 [ $VERBOSE != no ]  log_action_end_msg 0
 fi
 
-LIST_CONSOLES=`sed -e '/^ *#/d' /etc/inittab | grep -e '\tty[0-9]*\' | awk -F: '{printf %s , $1}'`
+if [ -d /etc/init ]  which initctl /dev/null; then
+	# Upstart
+	LIST_CONSOLES=`cd /etc/init; find -name 'tty*.conf' -printf '%f ' | sed -e 's/[^0-9 ]//g'`
+else
+	# traditional SysV init
+	LIST_CONSOLES=`sed -e '/^ *#/d' /etc/inittab | grep -e '\tty[0-9]*\' | awk -F: '{printf %s , $1}'`
+fi
 
 # Global default font+map
 if [ -z ${HAVE_SETUPCON} -a ${CONSOLE_FONT} ]; then


signature.asc
Description: Digital signature


Bug#549317: sed: can't read /etc/inittab: No such file or directory

2009-10-04 Thread Jussi Myllykoski
Hi!

On Sun, Oct 4, 2009 at 1:55 PM, Michael Schutte mi...@uiae.at wrote:
 May I ask you to apply the attached patch to your local copy of
 /etc/init.d/kbd and confirm that it works?  The solution isn’t perfect
 since it’s theoretically possible that gettys are started from files
 other than /etc/init/tty*.conf, but I guess it is good enough for most
 cases.

It certainly looks like to be working, no error message anymore.

Cheers,

-- 
Jussi Myllykoski
jussi.myllyko...@gmail.com



--
To UNSUBSCRIBE, email to debian-bugs-dist-requ...@lists.debian.org
with a subject of unsubscribe. Trouble? Contact listmas...@lists.debian.org



Bug#549317: sed: can't read /etc/inittab: No such file or directory

2009-10-02 Thread Jussi Myllykoski
Package: kbd
Version: 1.15-4
Severity: normal


I get this message on boot:


Setting console screen modes
sed: can't read /etc/inittab: No such file or directory


This is on a system where sysvinit has been replaced with upstart,
so if I understand correctly the data that used to be in /etc/inittab
is now in several files found at /etc/init/

This isn't a showstopper by any means, just something that I thought
might be good to bring to your attention (if it isn't already).


-- System Information:
Debian Release: squeeze/sid
  APT prefers unstable
  APT policy: (990, 'unstable'), (1, 'experimental')
Architecture: i386 (i686)

Kernel: Linux 2.6.31.1-eee901 (SMP w/2 CPU cores; PREEMPT)
Locale: LANG=en_US.UTF-8, LC_CTYPE=en_US.UTF-8 (charmap=UTF-8)
Shell: /bin/sh linked to /bin/dash

Versions of packages kbd depends on:
ii  console-setup 1.45   console font and keymap setup prog
ii  libc6 2.9-27 GNU C Library: Shared libraries
ii  lsb-base  3.2-23 Linux Standard Base 3.2 init scrip

Versions of packages kbd recommends:
ii  console-data  2:1.09-2   keymaps, fonts, charset maps, fall
ii  console-setup 1.45   console font and keymap setup prog

kbd suggests no packages.

-- no debconf information



-- 
To UNSUBSCRIBE, email to debian-bugs-dist-requ...@lists.debian.org
with a subject of unsubscribe. Trouble? Contact listmas...@lists.debian.org