From owner-freebsd-current@FreeBSD.ORG Mon Jul 26 15:12:34 2010 Return-Path: Delivered-To: freebsd-current@freebsd.org Received: from mx1.freebsd.org (mx1.freebsd.org [IPv6:2001:4f8:fff6::34]) by hub.freebsd.org (Postfix) with ESMTP id 0035C1065673 for ; Mon, 26 Jul 2010 15:12:33 +0000 (UTC) (envelope-from pagxir@gmail.com) Received: from mail-gw0-f54.google.com (mail-gw0-f54.google.com [74.125.83.54]) by mx1.freebsd.org (Postfix) with ESMTP id B31AE8FC14 for ; Mon, 26 Jul 2010 15:12:33 +0000 (UTC) Received: by gwj23 with SMTP id 23so120236gwj.13 for ; Mon, 26 Jul 2010 08:12:33 -0700 (PDT) DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=gmail.com; s=gamma; h=domainkey-signature:mime-version:received:received:date:message-id :subject:from:to:content-type; bh=HDSCjuDOUFeMcUXF17hMeCTg4Lc6eOeJUN7A9CGeSxM=; b=G5JBFrjnzolKQrsQiEAyN2HfK7H3g/+nAPpLho/bIH6N3Z8+rgmlmPhbv+5uMt+rV1 eVDU0o6wkfMaVkgtSfXYVsAYXuEjHtXCSKa+D/AiGT4xvB/kki+AV8J0Le2d0pPq17oh rWifEqwCntCtVup7vOI9RwWPiVCjylHvXn8Vs= DomainKey-Signature: a=rsa-sha1; c=nofws; d=gmail.com; s=gamma; h=mime-version:date:message-id:subject:from:to:content-type; b=nsw/4bvd0ZuxEJuc1fdLKHu87TNV8xX7ihzFnJAjeSERWd/vNbbU/4rDfBA7C4c2Ks 6nXRMjIB9UTeHJcH3/z7I0s0hJWlgM6P9CDJrHJfW0wVk+gS0e3GB5jurGIdq3dAJFdj v4T/numUHhwp1PZOzrrmqdUevt0nGHzwVAG90= MIME-Version: 1.0 Received: by 10.100.124.4 with SMTP id w4mr7853816anc.140.1280155599632; Mon, 26 Jul 2010 07:46:39 -0700 (PDT) Received: by 10.100.191.9 with HTTP; Mon, 26 Jul 2010 07:46:39 -0700 (PDT) Date: Mon, 26 Jul 2010 14:46:39 +0000 Message-ID: From: =?UTF-8?B?6KO05Zu95YW0?= To: freebsd-current@freebsd.org Content-Type: text/plain; charset=UTF-8 Content-Transfer-Encoding: quoted-printable X-Content-Filtered-By: Mailman/MimeDel 2.1.5 Subject: gnome 2.30 slow startup (Could not ask session manager if shut down is available) X-BeenThere: freebsd-current@freebsd.org X-Mailman-Version: 2.1.5 Precedence: list List-Id: Discussions about the use of FreeBSD-current List-Unsubscribe: , List-Archive: List-Post: List-Help: List-Subscribe: , X-List-Received-Date: Mon, 26 Jul 2010 15:12:34 -0000 Recently, I update my FreeBSD to 8.1, and Found that gnome 2.30 startup ver= y slow. It take one nimus or more to finish startup. When startup, the gnome-panel will display after nautilus about 30 seconds. >From the console, I see that 1=E3=80=81gnome-session[1935]: WARNING: Application 'metacity.desktop' fail= ed to register before timeout --------- after about 30 seconds ---------- 2=E3=80=81** (gnome-panel:1966): WARNING **: Could not ask session manager = if shut down is available: Did not receive a reply. Possible causes include: the remote application did not send a reply, the message bus security policy blocked the reply, the reply timeout expired, or the network connection was broken. I recompile metacity, and "WARNING: Application 'metacity.desktop' failed t= o register before timeout" disappear. I try to recompile gnome-session, but not work. Finally, I do a little change for gnome-session and compile, it work. the change file is gsm_manager.c GsmConsolekit *consolekit; gboolean can_suspend =3D 0; gboolean can_hibernate =3D 0; #if 0 g_object_get (manager->priv->dkp_client, "can-suspend", &can_suspend, "can-hibernate", &can_hibernate, NULL); #endif g_debug ("GsmManager: CanShutdown called"); g_return_val_if_fail (GSM_IS_MANAGER (manager), FALSE); consolekit =3D gsm_get_consolekit (); *shutdown_available =3D gsm_consolekit_can_stop (consolekit) || gsm_consolekit_can_restart (consolekit) || can_suspend || can_hibernate; g_object_unref (consolekit); *shutdown_available =3D 0; I use following command to start session setenv GNOME_SESSION "/usr/local/bin/ck-launch-session /usr/local/bin/gnome-session" env LC_ALL=3Dzh_CN.UTF-8 XMODIFIERS=3D@im=3Dibus startx $GNOME_SESSION I also found that if login user is root, it works very well. The question is why the g_object_get call will take such a long time on non-root user.