Tuesday Jan 26, 2010

Workaround for runaway metacity

Sun Ray on OpenSolaris build 131 requires the same workarounds I previously mentioned.

There is one more that helps with both 130 and 131. With the new gdm set up the login screen now runs "metacity" and occasionally this can get into a loop just consuming CPU. The trigger is that metacity has been sent a signal to terminate but then tries to be a bit too clever and goes into the loop. I've filed this bug so that it can be fixed.

Happily once again you can work around this with a bit of dtrace:

#!/usr/sbin/dtrace -qws

proc:::signal-handle
/ execname == "metacity" && args[0] == 15 / {
        system("logger -t metacity.d -p daemon.notice killing metacity[%d]", pid); 
        raise(9)
}

Friday Feb 08, 2008

Good Morning Build 81 - part 2

The responsible engineer for the portfs bug 6659309 sent me some new binaries and now our system is back running build 82 but with a new portfs module. Just to be 100% certain the bug is fixed I ran this D that show that we would have paniced without the patch:

: estale.eu FSS 18 $; pfexec /usr/sbin/dtrace -n 'fbt::port_pfp_setup:entry {>
pfexec /usr/sbin/dtrace -n 'fbt::port_pfp_setup:entry {
	self->pfs = 1;
}
fbt::port_alloc_event_local:return / self->pfs == 1 && arg1 == 0 /  {
	self->pfs = 2;
}
fbt::port_pfp_setup:return /arg1 != 0 && self->pfs == 2/ {
	printf("port_pfp_setup failed %d: We would have crashed!", arg1);
}
fbt::port_pfp_setup:return /self->pfs / {
	self->pfs = 0
}'
dtrace: description 'fbt::port_pfp_setup:entry ' matched 4 probes
CPU     ID                    FUNCTION:NAME
  0  45054            port_pfp_setup:return port_pfp_setup failed 22: We would have crashed!
  0  45054            port_pfp_setup:return port_pfp_setup failed 22: We would have crashed!

So that pretty much tells us the bug is fixed. Well that and the fact that the system is not crashing!


However metacity is. I wonder if the two are related. Time to investigate this core dump:

: estale.eu FSS 11 $; pstack  core-estale-metacity.9140
core 'core-estale-metacity.9140' of 9140:       metacity --sm-save-file 1187603434-7917-1684782535.ms
 c40cab10 _lwp_kill (6, 0, 5, 6, ffffffff, 6) + 8
 c4054b44 abort    (1, 1, 6, c4153940, fbc5c, 0) + 108
 c3e4a550 g_logv   (ba58c, 6, 5, c3ee5404, 4, c3ee3404) + 484
 c3e4a57c g_log    (ba58c, 4, ba598, ba5c4, 1a4, ba7d0) + 1c
 00073f5c meta_window_new_with_attrs (19fa88, 1180001, ba400, ffbfe56c, fb7188, 0) + 3d8
 00073b5c meta_window_new (19fa88, 1180001, 0, daddcafe, 12, fe8) + 78
 00034780 event_callback (ffbfea28, 19fa88, 0, 33400, 14, 1180001) + f74
 00071d64 filter_func (0, ba000, 243068, 1212d0, 3380c, 243068) + 54
 c3f4d308 gdk_event_apply_filters (71d10, 11f1630, 0, 243048, 317c98, ffbfea28) + 24
 c3f4def8 gdk_event_translate (1af020, ffbfea28, ffbfea28, 0, 11f1630, 1a4e3c0) + 44
 c3f4fbc4 _gdk_events_queue (1af020, 0, 5, 0, 1b2228, ffbfea28) + ac
 c3f4fda8 gdk_event_dispatch (197a50, 0, 0, c3f9c8c0, 4cb54, 1af020) + 40
 c3e3ffc4 g_main_dispatch (171f00, 0, 0, 0, c3ee3404, 171f08) + 1e4
 c3e4166c g_main_context_dispatch (1, 1, c3ee53fc, 2, c3ee5400, 171f00) + c8
 c3e41b8c g_main_context_iterate (1, 1, 1, 171f00, 27, 28) + 49c
 c3e42490 g_main_loop_run (113dc0, 0, 0, 141fc8, 113dc8, 1) + 3e4
 000495f4 main     (b2000, b1c00, b1c00, 1, 48c00, 49400) + 4c0
 0002b160 _start   (0, 0, 0, 0, 0, 0) + 108
: estale.eu FSS 12 $; 
: estale.eu FSS 13 $; mdb core-estale-metacity.9140
Loading modules: [ libumem.so.1 libc.so.1 libuutil.so.1 ld.so.1 ]
> ba58c/s
0xba58c:        metacity
> ba598/s
0xba598:        file %s: line %d: assertion failed: (%s)
> ba5c4/s
0xba5c4:        window.c
> ba7d0/s
0xba7d0:        window->screen
> 
About

This is the old blog of Chris Gerhard. It has mostly moved to http://chrisgerhard.wordpress.com

Search

Archives
« April 2014
MonTueWedThuFriSatSun
 
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
24
25
26
27
28
29
30
    
       
Today