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

[master&rhel6-branch] Re-enable usable pdb with vnc on s390x



This makes pdb in the ssh terminal work on s390x with vnc
which is extremely helpful for debugging anaconda issues.

d2d66577fbe3dd34efa0ddcec9640ebf41a9d49d introduced a shell on tty1
with vnc to help debugging when there are no virtual terminals.
047bc24212bd68942303242b864459bfc46be5d0 made the availability of this shell
dependent on isConsoleOnVirtualTerminal() so only for s390 and serial.
However, this shell makes pdb unusable due a race between both pdb
and the shell accessing the same terminal. See also #520831.
In fact, s390 has a default preferred console ttyS0,
on which /sbin/init (linuxrc.s390) provides a rescue shell already.
The shell on tty1 requires an ssh login on s390 anyway
and with available ssh logins, the user can get as many shells as he wants.
Therefore, s390 does not need the shell on tty1, not even with broken net.
This patch removes the shell on tty1 also for s390.
The if clause actually boils down to "if not flags.serial:".
Note that iutil.isConsoleOnVirtualTerminal() is used elsewhere since
60ac73a7e6241030392974e4a23e7a3abf549706,
so we cannot just modify its semantics.

Related: rhbz#597223
---
 anaconda |    5 +++--
 1 files changed, 3 insertions(+), 2 deletions(-)

diff --git a/anaconda b/anaconda
index 5d69a5e..280b20b 100755
--- a/anaconda
+++ b/anaconda
@@ -344,11 +344,12 @@ def runVNC():
                 break
 
         while True:
-            # s390/s390x are the only places we /really/ need a shell on tty1,
+            # Not having a virtual terminal or otherwise free console
+            # are the only places we /really/ need a shell on tty1,
             # and everywhere else this just gets in the way of pdb.  But we
             # don't want to return, because that'll return try to start X
             # a second time.
-            if iutil.isConsoleOnVirtualTerminal():
+            if iutil.isConsoleOnVirtualTerminal() or iutil.isS390():
                     time.sleep(10000)
             else:
                     print _("Press <enter> for a shell")
-- 
1.7.0.4



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