257 lines
9.3 KiB
HTML
257 lines
9.3 KiB
HTML
<!--startcut ======================================================= -->
|
|
<!DOCTYPE HTML PUBLIC "-//W3C//DTD HTML 3.2//EN">
|
|
<html>
|
|
<head>
|
|
<META NAME="generator" CONTENT="lgazmail v1.3C.e">
|
|
<TITLE>The Answer Guy 51: Console Goes Comatose After a Few Days</TITLE>
|
|
</HEAD><BODY BGCOLOR="#FFFFFF" TEXT="#000000"
|
|
LINK="#3366FF" VLINK="#A000A0">
|
|
<!-- ::::::::::::::::::::::::::::::::::::::::::::::::::::::::::::::: -->
|
|
<H4>"The Linux Gazette...<I>making Linux just a little more fun!</I>"</H4>
|
|
<P> <hr> <P>
|
|
<!-- ::::::::::::::::::::::::::::::::::::::::::::::::::::::::::::::: -->
|
|
<center>
|
|
<H1><A NAME="answer">
|
|
<img src="../../gx/dennis/qbubble.gif" alt="(?)"
|
|
border="0" align="middle">
|
|
<font color="#B03060">The Answer Guy</font>
|
|
<img src="../../gx/dennis/bbubble.gif" alt="(!)"
|
|
border="0" align="middle">
|
|
</A></H1>
|
|
<BR>
|
|
<H4>By James T. Dennis,
|
|
<a href="mailto:linux-questions-only@ssc.com">linux-questions-only@ssc.com</a><BR>
|
|
LinuxCare,
|
|
<A HREF="http://www.linuxcare.com/">http://www.linuxcare.com/</A>
|
|
</H4>
|
|
</center>
|
|
|
|
<p><hr><p>
|
|
<!-- endcut ======================================================= -->
|
|
<!-- begin 4 -->
|
|
<H3 align="left"><img src="../../gx/dennis/qbubble.gif"
|
|
height="50" width="60" alt="(?) " border="0"
|
|
>Console Goes Comatose After a Few Days</H3>
|
|
|
|
|
|
<p><strong>From kodancha on Sun, 30 Jan 2000
|
|
</strong></p>
|
|
<!-- ::
|
|
Console Goes Comatose After a Few Days
|
|
~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~
|
|
:: -->
|
|
<P><STRONG>
|
|
sir
|
|
</STRONG></P>
|
|
<P><STRONG>
|
|
i have installed redhat linux 6.1 on piii hardware with fire
|
|
walls.IT works fine.But every 3-4 days i have to reboot the system
|
|
because of the following.
|
|
</STRONG></P>
|
|
<P><STRONG>
|
|
Sytems will not take any command.When i type any thing cursor
|
|
moves but no char appears on the screen.Even cntrl-alt-del is also
|
|
not working.But all oher clients connected this server has got no
|
|
problem.I tryied stty sane ,cntrl -c etc but it is not
|
|
respondig.Can u help me
|
|
</STRONG></P>
|
|
<P><STRONG>
|
|
gjkodancha
|
|
</STRONG></P>
|
|
<BLOCKQUOTE><IMG SRC="../../gx/dennis/bbub.gif" ALT="(!)"
|
|
HEIGHT="28" WIDTH="50" BORDER="0"
|
|
>
|
|
Well, you description doesn't give me much to go on.
|
|
</BLOCKQUOTE>
|
|
<BLOCKQUOTE>
|
|
Is this in X? Are you using a kernel with frame buffer
|
|
(graphics driven text mode) console support?
|
|
</BLOCKQUOTE>
|
|
<BLOCKQUOTE>
|
|
Try building a new kernel. Leave the system in
|
|
text mode and disable any "VESA VGA Graphics" support
|
|
in the kernel (in menuconfig under the "Console Drivers"
|
|
menu). Be sure to enable the "Magic SysRq Key" under
|
|
"Kernel Hacking." Read the docs about this "Magic SysRq"
|
|
in the <TT>/usr/src/linux/Documentation/sysrq.txt</TT> file.
|
|
</BLOCKQUOTE>
|
|
<BLOCKQUOTE>
|
|
Now, after you've built and installed the new kernel,
|
|
when you reboot with it, use runlevel 3 (<A HREF="http://www.redhat.com/">Red Hat</A>:
|
|
text mode multi-user mode) rather than runlevel 5
|
|
(multi-user with GUI/xdm login mode).
|
|
</BLOCKQUOTE>
|
|
<BLOCKQUOTE>
|
|
If the console seems to go comatose again, try
|
|
using some of the Magic SysRq keys, particularly
|
|
the p (processor status), t (task list) and m (memory
|
|
status) diagnostics, and the k and r keys to kill
|
|
everything on a given console and to "reset" the
|
|
keyboard driver.
|
|
</BLOCKQUOTE>
|
|
<BLOCKQUOTE>
|
|
A couple of other things you can do:
|
|
</BLOCKQUOTE>
|
|
<BLOCKQUOTE>
|
|
Edit <TT>/etc/syslog.conf</TT> and add a line like:
|
|
</BLOCKQUOTE>
|
|
<BLOCKQUOTE><BlockQuote><Code>
|
|
*.* <TT>/dev/tty12</TT>
|
|
</Code></BlockQuote></BLOCKQUOTE>
|
|
<BLOCKQUOTE>
|
|
... (and restart your syslog daemon). This will
|
|
copy all syslog messages to your twelfth virtual
|
|
console. When you leave your system unattended,
|
|
switch to that VC. If it appears comatose when
|
|
you get back, look at the messages at the end.
|
|
</BLOCKQUOTE>
|
|
<BLOCKQUOTE>
|
|
When you restart your system, look at the tail
|
|
of the <TT>/var/log/messages</TT> file. That's where most
|
|
system warnings and errors are logged.
|
|
</BLOCKQUOTE>
|
|
<BLOCKQUOTE>
|
|
Also you can try logging in via ssh (or telnet,
|
|
rlogin or some other insecure protocol) and using
|
|
the commands: chvt 1 or chvt 2
|
|
... to force the console to switch to another VC.
|
|
See if that works.
|
|
</BLOCKQUOTE>
|
|
<BLOCKQUOTE>
|
|
You can also run commands like
|
|
</BLOCKQUOTE>
|
|
<BLOCKQUOTE><BlockQuote><Code>
|
|
stty sane < <TT>/dev/tty1</TT>
|
|
</Code></BlockQuote></BLOCKQUOTE>
|
|
<BLOCKQUOTE>
|
|
And:
|
|
</BLOCKQUOTE>
|
|
<BLOCKQUOTE><BLOCKQUOTE><CODE>
|
|
setterm -reset > <TT>/dev/tty1</TT>
|
|
</CODE></BLOCKQUOTE></BLOCKQUOTE>
|
|
<BLOCKQUOTE>
|
|
(note: the redirection operator on my stty
|
|
command is NOT backwards. stty performs<TT> ioctl()</TT>
|
|
calls on it's input device while setterm
|
|
words on it's output file descriptor. It looks
|
|
weird but stty was written a long time ago and
|
|
it actually made sense back then).
|
|
</BLOCKQUOTE>
|
|
<BLOCKQUOTE>
|
|
I've had cases where I could revive a console (from a
|
|
crashed X session or a wacked out SVGAlib program failure)
|
|
by running startx (from a remote session, even from a serial
|
|
login. That works sometimes (since the X server has to
|
|
reset quite a bit of the video and keyboard state as it
|
|
starts).
|
|
</BLOCKQUOTE>
|
|
<BLOCKQUOTE>
|
|
These kinds of console oddities are pretty rare.
|
|
It's usually the result of some buggy program that's
|
|
running with root privileges or some buggy driver
|
|
(which naturally is running with system/kernel
|
|
level access to the hardware). It could be a bit
|
|
of flaky hardware, too. It would be good to
|
|
figure out what is doing this. However, if this
|
|
is set up as a server, it may be that you don't
|
|
need the console all that much. You can treat it
|
|
like a "headless" system if you need to.
|
|
</BLOCKQUOTE>
|
|
<BLOCKQUOTE>
|
|
If you do decide to switch out hardware, try a
|
|
cheap replacement video card. Under Linux, in
|
|
server applications there is no point to using a
|
|
high end video card. Meanwhile the high end video
|
|
cards are most likely to have the cutting edge
|
|
technology and the highest chance of conflict with
|
|
other system components. Also make sure that any
|
|
"Plug and Pray" (PNP) settings are disabled in your
|
|
ISA peripherals and BIOS/CMOS.
|
|
</BLOCKQUOTE>
|
|
<BLOCKQUOTE>
|
|
If you think it's software then try attaching
|
|
strace to various processes that are bound to
|
|
your console. See if there's some oddity to
|
|
the system calls they're making before the lockup.
|
|
</BLOCKQUOTE>
|
|
<BLOCKQUOTE>
|
|
(Read the strace man page to understand a bit more
|
|
about this. Don't even bother if you don't know
|
|
the difference between a system call and a library
|
|
function. There's a pile of learning curve in
|
|
that direction).
|
|
</BLOCKQUOTE>
|
|
|
|
<!-- sig -->
|
|
|
|
|
|
<!-- end 4 -->
|
|
<!--startcut ======================================================= -->
|
|
<P> <hr> <P>
|
|
<H5 align="center"><a href="http://www.linuxgazette.com/copying.html"
|
|
>Copyright ©</a> 2000, James T. Dennis
|
|
<BR>Published in <I>The Linux Gazette</I> Issue 51 March 2000</H5>
|
|
<H6 ALIGN="center">HTML transformation by
|
|
<A HREF="mailto:star@tuxtops.com">Heather Stern</a> of
|
|
Tuxtops, Inc.,
|
|
<A HREF="http://www.tuxtops.com/">http://www.tuxtops.com/</A>
|
|
</H6>
|
|
<P> <hr> <P>
|
|
<!-- begin tagnav ::::::::::::::::::::::::::::::::::::::::::::::::::-->
|
|
<TABLE WIDTH="95%"><TR VALIGN="center" ALIGN="center">
|
|
<TD colspan="2" rowspan="2"><A
|
|
HREF="../lg_answer51.html"
|
|
><IMG SRC="../../gx/dennis/answernew.gif"
|
|
ALT="[ Answer Guy Current Index ]"></A>
|
|
<TD colspan="2" rowspan="2"><A
|
|
HREF="../../tag/kb.html"
|
|
><IMG SRC="../../gx/dennis/answertoc.gif"
|
|
ALT="[ Index of Past Answers ]"></A></td>
|
|
<TD WIDTH="11%"><A HREF="../lg_answer51.html#greeting"><img
|
|
src="../../gx/dennis/smily.gif" alt="greetings" border="0"></A></TD>
|
|
<TD WIDTH="11%"><A HREF="1.html">1</A></TD>
|
|
<TD WIDTH="11%"><A HREF="2.html">2</A></TD>
|
|
<TD WIDTH="11%"><A HREF="3.html">3</A></TD>
|
|
<TD WIDTH="11%"><A HREF="4.html">5</A></TD>
|
|
</TR><TR VALIGN="center" ALIGN="center">
|
|
<TD WIDTH="11%"><A HREF="5.html">5</A></TD>
|
|
<TD WIDTH="11%"><A HREF="6.html">6</A></TD>
|
|
<TD WIDTH="11%"><A HREF="7.html">7</A></TD>
|
|
<TD WIDTH="11%"><A HREF="8.html">8</A></TD>
|
|
<TD WIDTH="11%"><A HREF="9.html">9</A></TD>
|
|
</TR><TR VALIGN="center" ALIGN="center">
|
|
<TD WIDTH="10%"><A HREF="10.html">10</A></TD>
|
|
<TD WIDTH="10%"><A HREF="11.html">11</A></TD>
|
|
<TD WIDTH="10%"><A HREF="12.html">12</A></TD>
|
|
<TD WIDTH="10%"><A HREF="13.html">13</A></TD>
|
|
<TD WIDTH="11%"><A HREF="14.html">14</A></TD>
|
|
<TD WIDTH="11%"><A HREF="15.html">15</A></TD>
|
|
<TD WIDTH="11%"><A HREF="16.html">16</A></TD>
|
|
<TD WIDTH="11%"><A HREF="17.html">17</A></TD>
|
|
</TR><TR VALIGN="center" ALIGN="center">
|
|
<TD WIDTH="10%"><A HREF="18.html">18</A></TD>
|
|
<TD WIDTH="10%"><A HREF="19.html">19</A></TD>
|
|
<TD WIDTH="10%"><A HREF="20.html">20</A></TD>
|
|
<TD WIDTH="10%"><A HREF="21.html">21</A></TD>
|
|
<TD WIDTH="11%"><A HREF="22.html">22</A></TD>
|
|
</TR></TABLE>
|
|
</TR><TR VALIGN="center" ALIGN="center">
|
|
<!-- end tagnav ::::::::::::::::::::::::::::::::::::::::::::::::::::-->
|
|
<P> <hr> <P>
|
|
<!-- begin lgnav ::::::::::::::::::::::::::::::::::::::::::::::::::: -->
|
|
<A HREF="../index.html"
|
|
><IMG SRC="../../gx/indexnew.gif" ALT="[ Table Of Contents ]"></A>
|
|
<A HREF="../../index.html"
|
|
><IMG SRC="../../gx/homenew.gif" ALT="[ Front Page ]"></A>
|
|
<A HREF="../lg_bytes51.html"
|
|
><IMG SRC="../../gx/back2.gif" ALT="[ Previous Section ]"></A>
|
|
<A HREF="../../faq/index.html"
|
|
><IMG SRC="../../gx/dennis/faq.gif"
|
|
ALT="[ Linux Gazette FAQ ]"></A>
|
|
<A HREF="../lg_tips51.html"
|
|
><IMG SRC="../../gx/fwd.gif" ALT="[ Next Section ]"></A>
|
|
<!-- end lgnav ::::::::::::::::::::::::::::::::::::::::::::::::::::: -->
|
|
<!-- ::::::::::::::::::::::::::::::::::::::::::::::::::::::::::::::: -->
|
|
</BODY></HTML>
|
|
<!--endcut ========================================================= -->
|