For no apparent reason, my machine is rebooting.
last reboot
brings lines like this:
reboot system boot 3.13.0-24-generi Tue Dec 9 18:57 - 19:09 (00:11)
reboot system boot 3.13.0-24-generi Tue Dec 9 12:59 - 19:09 (06:09)
reboot system boot 3.13.0-24-generi Tue Dec 9 11:07 - 11:35 (00:28)
reboot system boot 3.13.0-24-generi Mon Dec 8 13:52 - 01:20 (11:27)
With the pseudo-user reboot.
I need to know:
- who is calling/activating this pseudo-user reboot?
- why(how to track it)?
- and how to fix/prevent that? (I may have to answer this one myself after I discover what is happening)
I am still researching, but my machine may suddenly reboot, so I have to post now!
related: Why does a grep reboot the machine?, about IO problems
related: about full memory
After two weeks my machine still reboots for no reason. I wonder if anyone has any idea of what "things" should not be accessed? I mean: are there places in /proc
or /dev
where we should avoid performing too many reads or writes? Or some commands that we should avoid? Do xdotool
or wmctrl
have some specific commands that should be avoided like trying to command a closed window id or something like that? any idea?
Narrowing it Down
My machine seems to not reboot if I keep some scripts stopped.
I am trying to narrow down what can cause this; I think a script I have may be the source; it, along with others, runs commands like these:
windowId=`xdotool getactivewindow`
xdotool getwindowname $windowId
xdotool search --sync "^Desktop$"
wmctrl -d
wmctrl -i -r $windowId -b toggle,maximized_vert,maximized_horz
xwininfo -wm -id $lnWindowId
Not exactly in this order, but basically they are all related to X window manipulations.
And, they happen very often, like 4 times each second;
And, they may happen on an unavailable window (that was just closed), or on some special windows like conky clock one, or in any non standard "window" (that is not a window like the unity hud).
It seems X windows manipulation can cause reboot then?
/var/log/messages
and your bash history from the time that the reboots were happening. Is this a desktop or a server? – Chris Davidson Dec 09 '14 at 21:21last
uses, no matter what triggered the reboot. – muru Dec 09 '14 at 21:46shutdown
in the various log files in/var/log
as a first step? The exact files varies based on distribution (I don't have amessages
, for example). – muru Dec 09 '14 at 21:54/var/log/syslog
also. But anyway, at /var/log, thisgrep shutdown * -irn 2>/dev/null
only showed wtmp (but that is what we read atlast
) – Aquarius Power Dec 09 '14 at 22:10