Bug 84842 - [NVC4] Xorg freezes every time on long idle
Summary: [NVC4] Xorg freezes every time on long idle
Status: RESOLVED INVALID
Alias: None
Product: xorg
Classification: Unclassified
Component: Driver/nouveau (show other bugs)
Version: 7.7 (2012.06)
Hardware: x86 (IA32) Linux (All)
: medium normal
Assignee: Nouveau Project
QA Contact: Xorg Project Team
URL:
Whiteboard:
Keywords:
Depends on:
Blocks:
 
Reported: 2014-10-09 14:34 UTC by kenorb
Modified: 2015-10-22 04:13 UTC (History)
1 user (show)

See Also:
i915 platform:
i915 features:


Attachments
full syslog file (231.02 KB, text/plain)
2014-10-09 14:34 UTC, kenorb
no flags Details

Description kenorb 2014-10-09 14:34:46 UTC
Created attachment 107619 [details]
full syslog file

My Xorg on Knoppix 7.2 freezes within 1h when left on idle. Could be related to compiz (0.8.4), but Xorg is the one which is in blocked state.

Reproducible steps:
1. Boot Knoppix 7.2.
2. In my case I've been running some rsync between 2 hdds.
3. Leave it for 1-2h.
4. Xorg is frozen on screensaver.

When it's frozen, mouse doesn't move, doesn't react on any keys, changing the terminal won't work, even doesn't react Ctrl-Alt-Del.
The only reaction is on Magic SysRq keys. Logged couple of backtraces (see below) and rebooted via REISUB SysRq keys.

Before the freeze, I was dumping `top -b` into file every 2 seconds, so avg. load was fine (it should be higher, because of running rsync).

10 minutes before the freeze which happened at around 9:10:

top - 09:00:00 up  4:29,  7 users,  load average: 4.20, 4.01, 3.68
Tasks: 198 total,   3 running, 195 sleeping,   0 stopped,   0 zombie
%Cpu(s):  3.4 us,  3.6 sy,  0.1 ni, 72.1 id, 20.5 wa,  0.0 hi,  0.3 si,  0.0 st
(rsync is running fine)

5 minutes to the freeze:
top - 09:05:00 up  4:34,  7 users,  load average: 4.14, 4.10, 3.81
Tasks: 198 total,   3 running, 195 sleeping,   0 stopped,   0 zombie
%Cpu(s):  0.8 us,  7.6 sy,  0.3 ni, 63.4 id, 27.2 wa,  0.0 hi,  0.8 si,  0.0 st

possible freeze, as the load avg. is low, high idle, only 1 process running:
top - 09:10:00 up  4:39,  7 users,  load average: 1.19, 2.42, 3.20
Tasks: 198 total,   1 running, 197 sleeping,   0 stopped,   0 zombie
%Cpu(s):  0.2 us,  0.1 sy,  0.0 ni, 99.1 id,  0.5 wa,  0.0 hi,  0.0 si,  0.0 st

definitively freeze:

top - 09:15:57 up  4:45,  7 users,  load average: 1.03, 1.49, 2.53
Tasks: 197 total,   1 running, 196 sleeping,   0 stopped,   0 zombie
%Cpu(s):  0.1 us,  0.1 sy,  0.0 ni, 99.8 id,  0.0 wa,  0.0 hi,  0.0 si,  0.0 st
KiB Mem:   3100584 total,  2980040 used,   120544 free,   511256 buffers
KiB Swap:  2325436 total,        0 used,  2325436 free,  1597052 cached

  PID  PPID   UID USER     RUSER     PR TTY         TIME+   RES  %CPU %MEM S COMMAND
 9893  9892     0 root     root      20 pts/0     38:28.42 178m   0.0  5.9 S rsync -vuar sda5/ sdd2/Backups/
 3081  3029  1000 knoppix  knoppix   20 ?          0:00.04 1192   0.0  0.0 S /usr/bin/ck-launch-session /usr/bin/dbus-launch --exit-with-session sta
 3029  2917  1000 knoppix  knoppix   20 ?          0:00.00  540   0.0  0.0 S xinit /etc/X11/xinit/xinitrc -- /usr/bin/X :0 vt5 -dpi 96 -br -noreset 
 2917  2582  1000 knoppix  knoppix   20 ?          0:00.00 1156   0.0  0.0 S /bin/sh /usr/bin/startx -- vt5 -dpi 96 -br -noreset -nolisten tcp
10104  3684  1000 knoppix  knoppix   20 pts/2      1:35.80  44m   0.0  1.5 S compiz
 3215  3201  1000 knoppix  knoppix   20 ?          0:01.49 2120   0.0  0.1 S xscreensaver -no-splash -no-capture-stderr
11261     2     0 root     root      20 ?          0:04.47    0   1.0  0.0 S [kworker/0:1]

The only process with 1% CUP is kworker/0:1

vmstat half an hour before the freeze:
 1  4      0 121408 525860 1587820    0    0   200   322  194  148  3  9 72 16
 1  1      0 131900 531776 1572540    0    0 27030 27328 2843 9992  1  4 74 21

vmstat after the freeze:
 0  0      0 131696 510640 1588524    0    0     0    64  156  143  0  0 100  0
 0  0      0 131696 510640 1588568    0    0     0     0  151  143  0  0 100  0

Here is the most important part, the backtrace of blocked tasks at 9:12:

SysRq : Show Blocked State
  task                PC stack   pid father
Xorg            D 00200200     0  3068   3029 0x00000004
 f3ddfd34 00000082 00100100 00200200 f3d721c0 f35d0480 000000db c19b0200
 f3ddfbe8 c19b0200 00000000 00000000 f4894100 f3ddfd14 c12f0c6c 00000001
 00000001 f3ddfd28 00000000 00000020 f3ddfd2c f351562c 00000003 f3ddfd1c
Call Trace:
 [<c12f0c6c>] ? idr_get_empty_slot+0x1c9/0x2cc
 [<c165faa1>] ? _raw_spin_unlock_irqrestore+0x1c/0x27
 [<c1053dbb>] ? __wake_up+0x3b/0x42
 [<c165f00b>] schedule+0x52/0x54
 [<c165f182>] schedule_preempt_disabled+0x12/0x1e
 [<c165e3c6>] __mutex_lock_common.isra.7+0x168/0x182
 [<c165e43f>] __mutex_lock_slowpath+0xd/0xf
 [<c165e1d4>] mutex_lock+0x11/0x1e
 [<f83c45c9>] nouveau_crtc_page_flip+0xf8/0x38a [nouveau]
 [<c13b8dc8>] drm_mode_page_flip_ioctl+0x1ef/0x273
 [<c13b8bd9>] ? drm_mode_gamma_get_ioctl+0xb4/0xb4
 [<c13ac1a6>] drm_ioctl+0x298/0x356
 [<c13b8bd9>] ? drm_mode_gamma_get_ioctl+0xb4/0xb4
 [<c10dae2f>] ? do_sync_read+0x69/0xa0
 [<c13abf0e>] ? drm_version+0x86/0x86
 [<c10e69a3>] vfs_ioctl+0x1b/0x25
 [<c10e7390>] do_vfs_ioctl+0x3da/0x418
 [<c10daec7>] ? fsnotify_access+0x61/0x69
 [<c10db531>] ? vfs_read+0x9a/0xe5
 [<c10ed841>] ? fget_light+0x2b/0x7d
 [<c10e740f>] sys_ioctl+0x41/0x5e
 [<c165fce5>] syscall_call+0x7/0xb

And some other stats:
active_anon:240980 inactive_anon:92120 isolated_anon:0
 active_file:182815 inactive_file:192232 isolated_file:0
 unevictable:23 dirty:14 writeback:0 unstable:0
 free:31748 slab_reclaimable:14961 slab_unreclaimable:8572
 mapped:21666 shmem:150771 pagetables:1876 bounce:0
 free_cma:0

DMA free:12464kB min:296kB low:368kB high:444kB active_anon:52kB inactive_anon:296kB active_file:1028kB inactive_file:1268kB unevictable:0kB isolated(anon):0kB isolated(file):0kB present:15988kB managed:15912kB mlocked:0kB dirty:0kB writeback:0kB mapped:0kB shmem:292kB slab_reclaimable:652kB slab_unreclaimable:152kB kernel_stack:0kB pagetables:0kB unstable:0kB bounce:0kB free_cma:0kB writeback_tmp:0kB pages_scanned:0 all_unreclaimable? no
525863 total pagecache pages
0 pages in swap cache
Swap cache stats: add 0, delete 0, find 0/0
Free swap  = 2325436kB
Total swap = 2325436kB
784255 pages RAM
556930 pages HighMem
9109 pages reserved
2590725681 pages shared
409588 pages non-shared

For full syslog, check the attachment.


Environment:

$ dpkg -l | grep xorg | head -n1
ii  xorg                                                        1:7.7+3~deb7u1                              i386         X.Org X Window System

$ Xorg -version

X.Org X Server 1.12.4
Release Date: 2012-08-27
X Protocol Version 11, Revision 0
Build Operating System: Linux 2.6.32-5-686-bigmem i686 Debian
Current Operating System: Linux Microknoppix 3.9.6 #25 SMP PREEMPT Sat Jun 15 15:27:01 CEST 2013 i686
Kernel command line: lang=en apm=power-off initrd=minirt.gz nomce libata.force=noncq hpsa.hpsa_allow_any=1 loglevel=1 BOOT_IMAGE=linux 
Build Date: 17 April 2013  11:13:16AM
xorg-server 2:1.12.4-6 (Julien Cristau <jcristau@debian.org>) 
Current version of pixman: 0.26.0
02:00.0 VGA compatible controller: NVIDIA Corporation GF104 [GeForce GTX 460] (rev a1)
drm_kms_helper         20665  1 nouveau

/etc/X11/xorg.conf
direct rendering: Yes
server glx vendor string: SGI
client glx vendor string: Mesa Project and SGI
OpenGL vendor string: nouveau

Modules:
"dbe", "dri", "glx", "record", "extmod", "extmod", "dri2", "nouveau", "dri2", "fb", "exa", "shadowfb", "evdev"

Hardware:
Intel Quad-Core i7 CPU 930
NVIDIA GeForce GTX 460
Comment 2 Ilia Mirkin 2015-02-09 09:10:41 UTC
Build Operating System: Linux 2.6.32-5-686-bigmem i686 Debian

nouveau has come a long way in the past 5+ years since 2.6.32 came out. Please try something a little bit more recent and see if the issue persists.
Comment 3 Marcin Slusarz 2015-02-09 20:06:45 UTC
"Build Operating System" does not matter ("Current Operating System" does), but Ilia's advise to try something newer still stands - you use 2 years old kernel (3.9 was released 2013-04-29)
Comment 4 Ilia Mirkin 2015-10-22 04:13:55 UTC
No retest in over 6 months as requested. Bug is about an ancient kernel.


Use of freedesktop.org services, including Bugzilla, is subject to our Code of Conduct. How we collect and use information is described in our Privacy Policy.