[Date Prev][Date Next] [Thread Prev][Thread Next] [Date Index] [Thread Index]

Bug#926539: rootskel: steal-ctty no longer works on at least sparc64



On Sat, 2019-04-06 at 21:33 +0200, John Paul Adrian Glaubitz wrote:
> On 4/6/19 6:46 PM, John Paul Adrian Glaubitz wrote:
> > My suspicion is that the support multiple consoles in parallel [2] introduced
> > this particular regression. I haven't done any debugging yet though as I'm
> > not sure where to start, I haven't touched the rootskel package before and
> > therefore would be interested in any pointers how to debug this.
> 
> The problem seems to be the fact that the sparc64 kernel uses different names
> for /proc/console and the actual console name:
> 
> root@landau:~# cat /proc/consoles 
> ttyHV0               -W- (EC p  )    4:64
> tty0                 -WU (E     )    4:1
> root@landau:~# readlink /sys/dev/char/4:64
> ../../devices/root/f0299a70/f029b788/tty/ttyS0

The inconsistent name seems like a kernel bug...

> root@landau:~#
> 
> And this is what used to make it work [1]:
> 
> 	    *) # >= 2.6.38
> 		console_major_minor="$(get-real-console-linux)"
> 		console_raw="$(readlink "/sys/dev/char/${console_major_minor}")"
> 		console="${console_raw##*/}"
> 		;;

So maybe rootskel should use that again, but applied to each console's
char device number.

(Though directly using the symlinks under /dev/char seems cleaner than
poking in sysfs.)

Ben.

-- 
Ben Hutchings
This sentence contradicts itself - no actually it doesn't.


Attachment: signature.asc
Description: This is a digitally signed message part


Reply to: