[Bug 447289] New: mingetty broken by a recent vanilla kernel
https://bugzilla.novell.com/show_bug.cgi?id=447289 User omb@khandalf.com added comment https://bugzilla.novell.com/show_bug.cgi?id=447289#c1 Summary: mingetty broken by a recent vanilla kernel Product: openSUSE 11.0 Version: Final Platform: Other OS/Version: openSUSE 11.0 Status: NEW Severity: Normal Priority: P5 - None Component: Other AssignedTo: bnc-team-screening@forge.provo.novell.com ReportedBy: omb@khandalf.com QAContact: qa@suse.de Found By: Beta-Customer Background, I try to run the latest stable kernel :so: uname -a: Linux alien 2.6.26.3-default #1 SMP Sun Aug 24 16:57:00 CEST 2008 x86_64 x86_64 x86_64 GNU/Linux cat /etc/SuSE-release: openSUSE 11.0.42 (X86-64) Alpha1 VERSION = 11.0.42 mingetty: (md5sum, no version) 8a62cbf0e85f69d202241fd6bc286b5b /sbin/mingetty Am ioctl:3812 TIOCSCTTY on /dev/ttyn now fails and mingetty punts, this means that all the character terminals are gone, a(nother) major regression causing completely unnecessary major pain. BTW it looks as if something is screwed up with tk/tcl and the BLT extension as well ... more later. open("/dev/tty8", O_RDWR) = 6 3812 ioctl(6, SNDCTL_TMR_TIMEBASE or TCGETS, {B38400 opost isig icanon echo ..}) = 0 3812 vhangup() = 0 3812 close(2) = 0 3812 close(1) = 0 3812 close(0) = 0 3812 --- SIGHUP (Hangup) @ 0 (0) --- 3812 close(6) = 0 3812 --- SIGHUP (Hangup) @ 0 (0) --- 3812 --- SIGCONT (Continued) @ 0 (0) --- 3812 open("/dev/tty8", O_RDWR) = 0 3812 ioctl(0, TIOCSCTTY) = -1 EPERM (Operation not permitted) 3812 gettimeofday({1227213828, 721832}, NULL) = 0 3812 open("/etc/localtime", O_RDONLY) = 1 3812 fstat(1, {st_mode=S_IFREG|0644, st_size=1920, ...}) = 0 3812 fstat(1, {st_mode=S_IFREG|0644, st_size=1920, ...}) = 0 3812 mmap(NULL, 4096, PROT_READ|PROT_WRITE, MAP_PRIVATE|MAP_ANONYMOUS, -1, 0) = 0x7f3a191b1000 3812 read(1, "TZif2\0\0\0\0\0\0\0\0\0\0\0\0\0\0\0\0\0\0\4\0\0\0\4\0\0\0\0\0"..., 4096) = 1920 3812 lseek(1, -1235, SEEK_CUR) = 685 3812 read(1, "TZif2\0\0\0\0\0\0\0\0\0\0\0\0\0\0\0\0\0\0\6\0\0\0\6\0\0\0\0\0"..., 4096) = 1235 3812 close(1) = 0 3812 munmap(0x7f3a191b1000, 4096) = 0 3812 stat("/etc/localtime", {st_mode=S_IFREG|0644, st_size=1920, ...}) = 0 3812 socket(PF_FILE, SOCK_DGRAM, 0) = 1 3812 fcntl(1, F_SETFD, FD_CLOEXEC) = 0 3812 connect(1, {sa_family=AF_FILE, path="/dev/log"...}, 110) = 0 3812 sendto(1, "<35>Nov 20 21:43:48 mingetty[3812"..., 108, MSG_NOSIGNAL, NULL, 0) = 108 3812 close(1) = 0 3812 exit_group(1) -- Configure bugmail: https://bugzilla.novell.com/userprefs.cgi?tab=email ------- You are receiving this mail because: ------- You are on the CC list for the bug.
https://bugzilla.novell.com/show_bug.cgi?id=447289 Robert Vojcik <rvojcik@novell.com> changed: What |Removed |Added ---------------------------------------------------------------------------- AssignedTo|bnc-team-screening@forge.provo.novell.com |werner@novell.com -- Configure bugmail: https://bugzilla.novell.com/userprefs.cgi?tab=email ------- You are receiving this mail because: ------- You are on the CC list for the bug.
https://bugzilla.novell.com/show_bug.cgi?id=447289 User werner@novell.com added comment https://bugzilla.novell.com/show_bug.cgi?id=447289#c1 Dr. Werner Fink <werner@novell.com> changed: What |Removed |Added ---------------------------------------------------------------------------- Status|NEW |RESOLVED Resolution| |INVALID --- Comment #1 from Dr. Werner Fink <werner@novell.com> 2008-11-27 11:14:44 MST --- Sorry but in this case the kernel is broken. If this is a vanilla kernel you are at your own (IMHO). Please report only problems with original kernels from openSuSE fitting your openSuSE version. -- Configure bugmail: https://bugzilla.novell.com/userprefs.cgi?tab=email ------- You are receiving this mail because: ------- You are on the CC list for the bug.
https://bugzilla.novell.com/show_bug.cgi?id=447289 User gregkh@novell.com added comment https://bugzilla.novell.com/show_bug.cgi?id=447289#c2 Greg Kroah-Hartman <gregkh@novell.com> changed: What |Removed |Added ---------------------------------------------------------------------------- CC| |gregkh@novell.com Status|RESOLVED |REOPENED Resolution|INVALID | --- Comment #2 from Greg Kroah-Hartman <gregkh@novell.com> 2008-11-27 21:30:07 MST --- Does this also happen with the 11.1 beta releases? The 11.0 userspace might have issues working with newer kernels for odd reasons like this. -- Configure bugmail: https://bugzilla.novell.com/userprefs.cgi?tab=email ------- You are receiving this mail because: ------- You are on the CC list for the bug.
https://bugzilla.novell.com/show_bug.cgi?id=447289 Greg Kroah-Hartman <gregkh@novell.com> changed: What |Removed |Added ---------------------------------------------------------------------------- Status|REOPENED |NEEDINFO Info Provider| |omb@khandalf.com -- Configure bugmail: https://bugzilla.novell.com/userprefs.cgi?tab=email ------- You are receiving this mail because: ------- You are on the CC list for the bug.
https://bugzilla.novell.com/show_bug.cgi?id=447289 User werner@novell.com added comment https://bugzilla.novell.com/show_bug.cgi?id=447289#c3 Dr. Werner Fink <werner@novell.com> changed: What |Removed |Added ---------------------------------------------------------------------------- CC| |werner@novell.com AssignedTo|werner@novell.com |gregkh@novell.com Status|NEEDINFO |NEW Info Provider|omb@khandalf.com | --- Comment #3 from Dr. Werner Fink <werner@novell.com> 2008-11-28 03:42:11 MST --- This is not my bug. The mingetty program uses the ioctl TIOCSCTTY as root and this has work now about more then a decade. -- Configure bugmail: https://bugzilla.novell.com/userprefs.cgi?tab=email ------- You are receiving this mail because: ------- You are on the CC list for the bug.
https://bugzilla.novell.com/show_bug.cgi?id=447289 User gregkh@novell.com added comment https://bugzilla.novell.com/show_bug.cgi?id=447289#c4 Greg Kroah-Hartman <gregkh@novell.com> changed: What |Removed |Added ---------------------------------------------------------------------------- Status|NEW |NEEDINFO Info Provider| |omb@khandalf.com --- Comment #4 from Greg Kroah-Hartman <gregkh@novell.com> 2009-01-08 17:06:25 MST --- Is this a problem in the 11.1 release? -- Configure bugmail: https://bugzilla.novell.com/userprefs.cgi?tab=email ------- You are receiving this mail because: ------- You are on the CC list for the bug.
https://bugzilla.novell.com/show_bug.cgi?id=447289 User gregkh@novell.com added comment https://bugzilla.novell.com/show_bug.cgi?id=447289#c5 Greg Kroah-Hartman <gregkh@novell.com> changed: What |Removed |Added ---------------------------------------------------------------------------- Status|NEEDINFO |RESOLVED Info Provider|omb@khandalf.com | Resolution| |NORESPONSE --- Comment #5 from Greg Kroah-Hartman <gregkh@novell.com> 2009-01-21 07:42:40 MST --- Closing due to lack of response :( -- Configure bugmail: https://bugzilla.novell.com/userprefs.cgi?tab=email ------- You are receiving this mail because: ------- You are on the CC list for the bug.
https://bugzilla.novell.com/show_bug.cgi?id=447289 User omb@khandalf.com added comment https://bugzilla.novell.com/show_bug.cgi?id=447289#c6 Brain O'Mahoney <omb@khandalf.com> changed: What |Removed |Added ---------------------------------------------------------------------------- Status|RESOLVED |REOPENED Resolution|NORESPONSE | --- Comment #6 from Brain O'Mahoney <omb@khandalf.com> 2009-01-21 09:33:47 MST --- Sorry, ioctls still fail with 2.6.28.1 (same 11.0 userland, mingetty-1.08 patched to make the ioctl fail non fatal), see snip strace below. 7502 close(2) = 0 7502 close(1) = 0 7502 close(0) = 0 7502 close(6) = 0 7502 open("/dev/tty6", O_RDWR) = 0 7502 ioctl(0, TIOCSCTTY) = -1 EPERM (Operation not permitted) 7502 gettimeofday({1232554065, 824729}, NULL) = 0 7502 open("/etc/localtime", O_RDONLY) = 1 7502 fstat(1, {st_mode=S_IFREG|0644, st_size=1920, ...}) = 0 7502 fstat(1, {st_mode=S_IFREG|0644, st_size=1920, ...}) = 0 7502 mmap(NULL, 4096, PROT_READ|PROT_WRITE, MAP_PRIVATE|MAP_ANONYMOUS, -1, 0) = 0x7fa3cbed0000 7502 read(1, "TZif2\0\0\0\0\0\0\0\0\0\0\0\0\0\0\0\0\0\0\4\0\0\0\4\0\0\0\0\0"..., 4096) = 1920 7502 lseek(1, -1235, SEEK_CUR) = 685 7502 read(1, "TZif2\0\0\0\0\0\0\0\0\0\0\0\0\0\0\0\0\0\0\6\0\0\0\6\0\0\0\0\0"..., 4096) = 1235 7502 close(1) = 0 7502 munmap(0x7fa3cbed0000, 4096) = 0 7502 stat("/etc/localtime", {st_mode=S_IFREG|0644, st_size=1920, ...}) = 0 7502 socket(PF_FILE, SOCK_DGRAM, 0) = 1 7502 fcntl(1, F_SETFD, FD_CLOEXEC) = 0 7502 connect(1, {sa_family=AF_FILE, path="/dev/log"...}, 110) = 0 7502 sendto(1, "<36>Jan 21 17:07:45 mingetty[7502"..., 108, MSG_NOSIGNAL, NULL, 0) = 108 7502 close(1) = 0 7502 ioctl(0, TIOCSPGRP, [7502]) = -1 ENOTTY (Inappropriate ioctl for device) 7502 gettimeofday({1232554065, 828186}, NULL) = 0 7502 stat("/etc/localtime", {st_mode=S_IFREG|0644, st_size=1920, ...}) = 0 7502 socket(PF_FILE, SOCK_DGRAM, 0) = 1 7502 fcntl(1, F_SETFD, FD_CLOEXEC) = 0 7502 connect(1, {sa_family=AF_FILE, path="/dev/log"...}, 110) = 0 7502 sendto(1, "<36>Jan 21 17:07:45 mingetty[7502"..., 113, MSG_NOSIGNAL, NULL, 0) = 113 7502 close(1) = 0 7502 dup2(0, 0) = 0 7502 dup2(0, 1) = 1 7502 dup2(0, 2) = 2 7502 ioctl(0, KDGKBMODE, 0x605370) = 0 7502 write(0, "\33[r\33[H\33[J"..., 9) = 9 7502 stat("/dev/vcs6", {st_mode=S_IFCHR|0660, st_rdev=makedev(7, 6), ...}) = 0 7502 chown("/dev/vcs6", 0, 5) = 0 7502 chmod("/dev/vcs6", 0660) = 0 -- Configure bugmail: https://bugzilla.novell.com/userprefs.cgi?tab=email ------- You are receiving this mail because: ------- You are on the CC list for the bug.
https://bugzilla.novell.com/show_bug.cgi?id=447289 User werner@novell.com added comment https://bugzilla.novell.com/show_bug.cgi?id=447289#c7 --- Comment #7 from Dr. Werner Fink <werner@novell.com> 2009-01-21 10:04:36 MST --- Created an attachment (id=266580) --> (https://bugzilla.novell.com/attachment.cgi?id=266580) mingetty-1.0.7s-70.50.i586.rpm -- Configure bugmail: https://bugzilla.novell.com/userprefs.cgi?tab=email ------- You are receiving this mail because: ------- You are on the CC list for the bug.
https://bugzilla.novell.com/show_bug.cgi?id=447289 User werner@novell.com added comment https://bugzilla.novell.com/show_bug.cgi?id=447289#c8 --- Comment #8 from Dr. Werner Fink <werner@novell.com> 2009-01-21 10:05:06 MST --- Created an attachment (id=266581) --> (https://bugzilla.novell.com/attachment.cgi?id=266581) mingetty-1.0.7s-70.50.x86_64.rpm -- Configure bugmail: https://bugzilla.novell.com/userprefs.cgi?tab=email ------- You are receiving this mail because: ------- You are on the CC list for the bug.
https://bugzilla.novell.com/show_bug.cgi?id=447289 User werner@novell.com added comment https://bugzilla.novell.com/show_bug.cgi?id=447289#c9 Dr. Werner Fink <werner@novell.com> changed: What |Removed |Added ---------------------------------------------------------------------------- Status|REOPENED |NEEDINFO Info Provider| |omb@khandalf.com --- Comment #9 from Dr. Werner Fink <werner@novell.com> 2009-01-21 10:07:29 MST --- Please test one of the above mingetty packages as these include a small patch which avoids getting a controlling tty twice, first on the open(2) and then on the explicit ioctls(2) its self. -- Configure bugmail: https://bugzilla.novell.com/userprefs.cgi?tab=email ------- You are receiving this mail because: ------- You are on the CC list for the bug.
https://bugzilla.novell.com/show_bug.cgi?id=447289 User omb@khandalf.com added comment https://bugzilla.novell.com/show_bug.cgi?id=447289#c10 --- Comment #10 from Brain O'Mahoney <omb@khandalf.com> 2009-01-21 11:00:25 MST --- Can you mail me the patch or an srpm please. B -- Configure bugmail: https://bugzilla.novell.com/userprefs.cgi?tab=email ------- You are receiving this mail because: ------- You are on the CC list for the bug.
https://bugzilla.novell.com/show_bug.cgi?id=447289 User werner@novell.com added comment https://bugzilla.novell.com/show_bug.cgi?id=447289#c11 --- Comment #11 from Dr. Werner Fink <werner@novell.com> 2009-01-22 04:09:53 MST --- Created an attachment (id=266828) --> (https://bugzilla.novell.com/attachment.cgi?id=266828) mingetty-1.0.7s-ctty.dif you may try this one -- Configure bugmail: https://bugzilla.novell.com/userprefs.cgi?tab=email ------- You are receiving this mail because: ------- You are on the CC list for the bug.
https://bugzilla.novell.com/show_bug.cgi?id=447289 User werner@novell.com added comment https://bugzilla.novell.com/show_bug.cgi?id=447289#c12 --- Comment #12 from Dr. Werner Fink <werner@novell.com> 2009-01-22 04:11:33 MST --- Please report if this works for you -- Configure bugmail: https://bugzilla.novell.com/userprefs.cgi?tab=email ------- You are receiving this mail because: ------- You are on the CC list for the bug.
https://bugzilla.novell.com/show_bug.cgi?id=447289 User omb@khandalf.com added comment https://bugzilla.novell.com/show_bug.cgi?id=447289#c13 --- Comment #13 from Brain O'Mahoney <omb@khandalf.com> 2009-01-22 23:58:52 MST --- Created an attachment (id=267129) --> (https://bugzilla.novell.com/attachment.cgi?id=267129) patched mingetty.c src (entire) -- Configure bugmail: https://bugzilla.novell.com/userprefs.cgi?tab=email ------- You are receiving this mail because: ------- You are on the CC list for the bug.
https://bugzilla.novell.com/show_bug.cgi?id=447289 User omb@khandalf.com added comment https://bugzilla.novell.com/show_bug.cgi?id=447289#c14 Brain O'Mahoney <omb@khandalf.com> changed: What |Removed |Added ---------------------------------------------------------------------------- Status|NEEDINFO |REOPENED CC| |omb@khandalf.com Info Provider|omb@khandalf.com | --- Comment #14 from Brain O'Mahoney <omb@khandalf.com> 2009-01-23 00:05:04 MST --- No it still dosnt work. I got the latest suse factory srpm mingetty-1.0.7s-92.15.src.rpm applied the included patches and when you latest patch did not apply cleanly did it by hand, from the strace: 8085 chown("/dev/tty6", 0, 5) = 0 8085 chmod("/dev/tty6", 0660) = 0 8085 rt_sigaction(SIGHUP, {SIG_IGN}, {SIG_DFL}, 8) = 0 8085 rt_sigaction(SIGQUIT, {0x4022df, [], SA_RESTORER, 0x7fb76834b660}, NULL, 8) = 0 8085 open("/dev/tty6", O_RDWR|O_NOCTTY) = 6 8085 ioctl(6, SNDCTL_TMR_TIMEBASE or TCGETS, {B38400 opost isig icanon echo ..}) = 0 8085 ioctl(6, TIOCGSID, 0x7fff7088bc74) = -1 ENOTTY (Inappropriate ioctl for device) 8085 ioctl(6, TIOCSCTTY) = -1 EPERM (Operation not permitted) you see the open worked but the ioctls still fail, please advise. I have added attached the entire patched mingetty.c file for your convenience and to avoid confusion. -- Configure bugmail: https://bugzilla.novell.com/userprefs.cgi?tab=email ------- You are receiving this mail because: ------- You are on the CC list for the bug.
https://bugzilla.novell.com/show_bug.cgi?id=447289 User werner@novell.com added comment https://bugzilla.novell.com/show_bug.cgi?id=447289#c15 Dr. Werner Fink <werner@novell.com> changed: What |Removed |Added ---------------------------------------------------------------------------- Status|REOPENED |NEEDINFO Info Provider| |omb@khandalf.com --- Comment #15 from Dr. Werner Fink <werner@novell.com> 2009-01-23 03:24:22 MST --- AFAICS: open("/dev/tty6", O_RDWR|O_NOCTTY) = 6 ioctl(6, TIOCGSID, 0x7fff7088bc74) = -1 ENOTTY makes no sence to me as /dev/tty6 *is* a TTY. IHMO your kernel setup seems to be broken. Please report cat /proc/tty/drivers and the values of CONFIG_VT_CONSOLE CONFIG_HW_CONSOLE CONFIG_VT_HW_CONSOLE_BINDING of your kernels configuration. -- Configure bugmail: https://bugzilla.novell.com/userprefs.cgi?tab=email ------- You are receiving this mail because: ------- You are on the CC list for the bug.
https://bugzilla.novell.com/show_bug.cgi?id=447289 User omb@khandalf.com added comment https://bugzilla.novell.com/show_bug.cgi?id=447289#c16 Brain O'Mahoney <omb@khandalf.com> changed: What |Removed |Added ---------------------------------------------------------------------------- Status|NEEDINFO |REOPENED Info Provider|omb@khandalf.com | --- Comment #16 from Brain O'Mahoney <omb@khandalf.com> 2009-01-23 05:04:34 MST --- Thank you for your info, at least mingetty.c is now in sync, FYI the kernel source I tested on is based on the git head distributed by gregkh from: http://git.kernel.org/?p=linux/kernel/git/stable/linux-2.6.28.y.git;a=summar... git pull ... which leaves me with HEAD:c5d8afab63194a50e6dfc6b0b03a604a7de6d5a3 Linux alien 2.6.28.1-default #6 SMP Wed Jan 21 00:48:14 CET 2009 x86_64 x86_64 x86_64 GNU/Linux To answer your other requests: cat /proc/tty/drivers: /dev/tty /dev/tty 5 0 system:/dev/tty /dev/console /dev/console 5 1 system:console /dev/ptmx /dev/ptmx 5 2 system /dev/vc/0 /dev/vc/0 4 0 system:vtmaster rfcomm /dev/rfcomm 216 0-255 serial serial /dev/ttyS 4 64-67 serial pty_slave /dev/pts 136 0-1048575 pty:slave pty_master /dev/ptm 128 0-1048575 pty:master unknown /dev/tty 4 1-63 console and: CONFIG_VT_CONSOLE=y CONFIG_HW_CONSOLE=y CONFIG_VT_HW_CONSOLE_BINDING=y Lastly I thought to retry the ttyn on tty3 not tty6 to avoid an un-necessary iteration: 13518 chown("/dev/tty3", 0, 5) = 0 13518 chmod("/dev/tty3", 0660) = 0 13518 rt_sigaction(SIGHUP, {SIG_IGN}, {SIG_DFL}, 8) = 0 13518 rt_sigaction(SIGQUIT, {0x4022df, [], SA_RESTORER, 0x7f4eb28d4660}, NULL, 8) = 0 13518 open("/dev/tty3", O_RDWR|O_NOCTTY) = 6 13518 ioctl(6, SNDCTL_TMR_TIMEBASE or TCGETS, {B38400 opost isig icanon echo ..}) = 0 13518 ioctl(6, TIOCGSID, 0x7fffbae151f4) = -1 ENOTTY (Inappropriate ioctl for device) 13518 ioctl(6, TIOCSCTTY) = -1 EPERM (Operation not permitted) I hope this helps. Grüss, Brian -- Configure bugmail: https://bugzilla.novell.com/userprefs.cgi?tab=email ------- You are receiving this mail because: ------- You are on the CC list for the bug.
https://bugzilla.novell.com/show_bug.cgi?id=447289 User werner@novell.com added comment https://bugzilla.novell.com/show_bug.cgi?id=447289#c17 --- Comment #17 from Dr. Werner Fink <werner@novell.com> 2009-01-23 05:34:41 MST --- IMHo this kernel is broken ... it could be OK to fail TIOCGSID for with ENOTTY if the terminal is not a master pseudo-terminal and not our controlling terminal. In this case the TIOCSCTTY should succeed, from the manual page tty_ioctl(4): Controlling terminal TIOCSCTTY int arg Make the given terminal the controlling terminal of the calling process. The calling process must be a session leader and not have a controlling terminal already. If this terminal is already the controlling terminal of a different session group then the ioctl fails with EPERM, unless the caller is root (more precisely: has the CAP_SYS_ADMIN capability) and arg equals 1, in which case the terminal is stolen, and all processes that had it as controlling terminal lose it. ... -- Configure bugmail: https://bugzilla.novell.com/userprefs.cgi?tab=email ------- You are receiving this mail because: ------- You are on the CC list for the bug.
https://bugzilla.novell.com/show_bug.cgi?id=447289 User omb@khandalf.com added comment https://bugzilla.novell.com/show_bug.cgi?id=447289#c18 --- Comment #18 from Brain O'Mahoney <omb@khandalf.com> 2009-01-23 07:13:05 MST --- I agree that something is broken, or there is a mis-understood API change som ewhere. The question is what, or rather who is going to actually __do__ something about it? The choices are you (wf), grehkh, the TTY IO subsystem maintainer (now we can give them an agreed mingetty source) ie post to LKML, me (omb)? I am quite busy and dont know the TTY subsystem well. Does gregkh have a recommendation/preference for this??? I think getting this fixed in (Open)SuSE is quite important as it really kills you when something goes wrong in the X sub-system and do <ctl><alt>Fn to get a non X login to investigate what got screwed up. Not finding a getty is a real newbie killer, since, unless they think of SysReq or ssh it is likely to be the power switch, and no wiser what _really_ went wrong. I really do not like it when Linux regressions give the M$ windows effect. -- Configure bugmail: https://bugzilla.novell.com/userprefs.cgi?tab=email ------- You are receiving this mail because: ------- You are on the CC list for the bug.
https://bugzilla.novell.com/show_bug.cgi?id=447289 User jfrantzius@web.de added comment https://bugzilla.novell.com/show_bug.cgi?id=447289#c19 Jörg von Frantzius <jfrantzius@web.de> changed: What |Removed |Added ---------------------------------------------------------------------------- CC| |jfrantzius@web.de --- Comment #19 from Jörg von Frantzius <jfrantzius@web.de> 2009-02-13 06:16:10 MST --- Very annoying indeed. -- Configure bugmail: https://bugzilla.novell.com/userprefs.cgi?tab=email ------- You are receiving this mail because: ------- You are on the CC list for the bug.
participants (1)
-
bugzilla_noreply@novell.com