From owner-freebsd-questions@FreeBSD.ORG Tue Mar 20 17:01:49 2007 Return-Path: X-Original-To: freebsd-questions@freebsd.org Delivered-To: freebsd-questions@freebsd.org Received: from mx1.freebsd.org (mx1.freebsd.org [69.147.83.52]) by hub.freebsd.org (Postfix) with ESMTP id 6F32316A400 for ; Tue, 20 Mar 2007 17:01:49 +0000 (UTC) (envelope-from gandalf@designaproduct.biz) Received: from designaproduct.biz (135-shost.hostoffice.hu [195.228.74.135]) by mx1.freebsd.org (Postfix) with ESMTP id 3111F13C457 for ; Tue, 20 Mar 2007 17:01:49 +0000 (UTC) (envelope-from gandalf@designaproduct.biz) Received: from [172.16.0.43] (localhost [127.0.0.1]) by designaproduct.biz (Postfix) with ESMTP id 02EB21DD422; Tue, 20 Mar 2007 12:55:13 -0400 (EDT) Message-ID: <4600137D.3000607@designaproduct.biz> Date: Tue, 20 Mar 2007 18:01:49 +0100 From: Laszlo Nagy User-Agent: Thunderbird 1.5.0.10 (Windows/20070221) MIME-Version: 1.0 To: Alex Zbyslaw , freebsd-questions@freebsd.org References: <45FFE73B.1080406@designaproduct.biz> <45FFF62B.9030206@dial.pipex.com> <45FFFBFD.7050607@designaproduct.biz> <46000435.7020600@dial.pipex.com> In-Reply-To: <46000435.7020600@dial.pipex.com> Content-Type: text/plain; charset=ISO-8859-1; format=flowed Content-Transfer-Encoding: 7bit Cc: Subject: Re: Disappearing files, created from /etc/X11/Xclients X-BeenThere: freebsd-questions@freebsd.org X-Mailman-Version: 2.1.5 Precedence: list List-Id: User questions List-Unsubscribe: , List-Archive: List-Post: List-Help: List-Subscribe: , X-List-Received-Date: Tue, 20 Mar 2007 17:01:49 -0000 >> Unfortunately, I cannot debug this way. The error is that no files >> are created by normal users, so I cannot use files for logging. Also >> there is no console because this is the /etcX11/Xclients script, e.g. >> it is executed by gdm after logging in to X window system through >> xdmpc. Well, I might setup an xml rpc server for logging, but hey, if >> I cannot write into a wicked file then I should not start with >> complex protocols and networking. > > Humour me. Try opening a fixed filename in a location which you > double-check is world-writeable. E.g. /tmp/FOO and print all your > relevant variables there. If it works as gandalf, then delete that > trace file and try as a non-working user. > > If that fails, then try opening the file in the home directory of the > user who you are testing as. I tried this before I wrote to this list. It does not work. No 'normal' users can create these files from /etc/X11/Xclients. But after gnome starts up, they can create these files. If I login with a normal user and I try to re-run /etc/X11/Xclients then the files gets created, and finally I get an error message telling that gnome is already running. > If that fails then you can try logging them with syslog. How can I do that from Python? :-) I tried this: from syslog import * syslog(|LOG_INFO | LOG_USER, 'test') No exception raised but I found nothing under /var/log.| > > Are you sure that if say the file() fails, that a window manager won't > start anyway? You can test that by making the filename something > clearly non-existent. To your request, I changed the ddir variable to '/nonexistent', and gnome was started! So you found the problem! Thanks! :-) It was that gdm started /usr/local/etc/gdm/Xsession. That script started /etc/X11/Xclients but ONLY for user gandalf. It is because I selected 'use system default session' in gdm before logging in. It was months ago, and I forgot it. Other users were using the default gnome session, e.g. they were NOT executing the Xclients script. Thank you again! Laszlo