From mboxrd@z Thu Jan 1 00:00:00 1970 X-Msuck: nntp://news.gmane.io/gmane.comp.tex.context/62449 Path: news.gmane.org!not-for-mail From: Florian Wobbe Newsgroups: gmane.comp.tex.context Subject: Re: calling ConTeXt as a background process Date: Fri, 08 Oct 2010 11:25:05 +0200 Message-ID: <95274FC9-42F1-4842-9943-103608507CB4@awi.de> References: <4CAD8800.2010909@elvenkind.com> <4CAD8D8A.6040802@elvenkind.com> <5A1428AE-DA31-4120-9B35-102E7B42D8AC@fiee.net> <90F33E64-7BB9-4DEB-9E89-A4FC99169401@awi.de> <48470924-D44D-4010-B895-12EA664C4D90@fiee.net> <93934DF3-21F9-4F68-99B1-75A09A7835C8@fiee.net> <67380489-10BF-4A55-8519-5BC981426F3C@awi.de> <2F3F5D5C-FA78-4EA2-885E-A6DB86880B34@fiee.net> Reply-To: mailing list for ConTeXt users NNTP-Posting-Host: lo.gmane.org Mime-Version: 1.0 Content-Type: text/plain; charset="us-ascii" Content-Transfer-Encoding: 7bit X-Trace: dough.gmane.org 1286529925 14015 80.91.229.12 (8 Oct 2010 09:25:25 GMT) X-Complaints-To: usenet@dough.gmane.org NNTP-Posting-Date: Fri, 8 Oct 2010 09:25:25 +0000 (UTC) To: mailing list for ConTeXt users Original-X-From: ntg-context-bounces@ntg.nl Fri Oct 08 11:25:22 2010 Return-path: Envelope-to: gctc-ntg-context-518@m.gmane.org Original-Received: from balder.ntg.nl ([195.12.62.10]) by lo.gmane.org with esmtp (Exim 4.69) (envelope-from ) id 1P49Cc-0003O2-KL for gctc-ntg-context-518@m.gmane.org; Fri, 08 Oct 2010 11:25:22 +0200 Original-Received: from localhost (localhost [127.0.0.1]) by balder.ntg.nl (Postfix) with ESMTP id 9A0AECA73F; Fri, 8 Oct 2010 11:25:21 +0200 (CEST) X-Virus-Scanned: Debian amavisd-new at balder.ntg.nl Original-Received: from balder.ntg.nl ([127.0.0.1]) by localhost (balder.ntg.nl [127.0.0.1]) (amavisd-new, port 10024) with LMTP id cjcqIW-ey+9O; Fri, 8 Oct 2010 11:25:19 +0200 (CEST) Original-Received: from balder.ntg.nl (localhost [127.0.0.1]) by balder.ntg.nl (Postfix) with ESMTP id E7B02CA749; Fri, 8 Oct 2010 11:25:18 +0200 (CEST) Original-Received: from localhost (localhost [127.0.0.1]) by balder.ntg.nl (Postfix) with ESMTP id 0866FCA749 for ; Fri, 8 Oct 2010 11:25:17 +0200 (CEST) X-Virus-Scanned: Debian amavisd-new at balder.ntg.nl Original-Received: from balder.ntg.nl ([127.0.0.1]) by localhost (balder.ntg.nl [127.0.0.1]) (amavisd-new, port 10024) with LMTP id OeQ09Wz5bMo4 for ; Fri, 8 Oct 2010 11:25:14 +0200 (CEST) Original-Received: from filter1-nij.mf.surf.net (filter1-nij.mf.surf.net [195.169.124.152]) by balder.ntg.nl (Postfix) with ESMTP id 95BFDCA73F for ; Fri, 8 Oct 2010 11:25:14 +0200 (CEST) Original-Received: from mails3.awi.de (mails3.AWI.DE [134.1.2.14]) by filter1-nij.mf.surf.net (8.14.3/8.14.3/Debian-5+lenny1) with ESMTP id o989PDxh016521 for ; Fri, 8 Oct 2010 11:25:13 +0200 Original-Received: from localhost (localhost [127.0.0.1]) by mails3.awi.de (Postfix) with ESMTP id D9C2FB573F for ; Fri, 8 Oct 2010 11:25:12 +0200 (MEST) X-Virus-Scanned: amavisd-new at awi.de Original-Received: from localhost ([127.0.0.1]) by localhost (mails3.awi.de [127.0.0.1]) (amavisd-new, port 10025) with ESMTP id IbYpfmRi1T7p for ; Fri, 8 Oct 2010 11:25:04 +0200 (MEST) Original-Received: from msg.awi.de (msg.AWI.DE [134.1.3.16]) by mails3.awi.de (Postfix) with ESMTP id E9429B571F for ; Fri, 8 Oct 2010 11:25:04 +0200 (MEST) Original-Received: from vpn-awinet-16-21.awi.de ([unknown] [172.28.16.21]) by msg.awi.de (Sun Java(tm) System Messaging Server 7u3-12.01 64bit (built Oct 15 2009)) with ESMTPSA id <0L9Y009VUSTTWS80@msg.awi.de> for ntg-context@ntg.nl; Fri, 08 Oct 2010 11:25:05 +0200 (MEST) In-reply-to: <2F3F5D5C-FA78-4EA2-885E-A6DB86880B34@fiee.net> X-Mailer: Apple Mail (2.1081) X-Bayes-Prob: 0.0001 (Score 0, tokens from: @@RPTN) X-CanIt-Geo: ip=134.1.2.14; country=DE; region=03; city=Bremerhaven; latitude=53.5500; longitude=8.5833; http://maps.google.com/maps?q=53.5500,8.5833&z=6 X-CanItPRO-Stream: uu:ntg-context@ntg.nl (inherits from uu:default, base:default) X-Canit-Stats-ID: 07Dg9pdbd - da5ea7c8db6d - 20101008 X-Scanned-By: CanIt (www . roaringpenguin . com) on 195.169.124.152 X-BeenThere: ntg-context@ntg.nl X-Mailman-Version: 2.1.12 Precedence: list List-Id: mailing list for ConTeXt users List-Unsubscribe: , List-Archive: List-Post: List-Help: List-Subscribe: , Original-Sender: ntg-context-bounces@ntg.nl Errors-To: ntg-context-bounces@ntg.nl Xref: news.gmane.org gmane.comp.tex.context:62449 Archived-At: > Am 2010-10-08 um 09:59 schrieb Florian Wobbe: > >>> Thank you, but the problem is most probably something in my server setup that doesn't fit something in LuaTeX. >>> As I mentioned: I got no problems calling TeX directly, just from the server process. >> >> All right. I have one more suggestion. If you don't want to dive into debugging via gdb you should try another attempt at strace. Previously you posted a tracedump of context. But it only shows context (the shell script) waiting and nothing related to luatex. You may want to make strace follow forks (-f). > > > Sorry, I've no experience using strace. Some things are explained here: http://blog.ksplice.com/tag/unix/ > Here we are: > > This is how my process tree looked: > 14025 ? Sl 0:01 | \_ /var/www/xxx/bin/python /var/www/xxx/.../manage.py runfcgi ... > 14116 ? S 0:00 | \_ /bin/sh -c set >> _context.log && strace -f context --batchmode --once hello >> _context.log > 14117 ? S 0:00 | \_ strace -f context --batchmode --once hello > 14118 ? T 0:00 | \_ /bin/sh /var/opt/context/tex/texmf-linux-64/bin/context --batchmode --once hello > 14119 ? R 0:11 | \_ texlua /var/opt/context/tex/texmf-linux-64/bin/mtxrun --script context --batchmode --once hello > > The logfile was empty, texlua seemed to hang. I killed 14119 and got: > [...] > [pid 14119] brk(0xaa3c000) = 0xaa3c000 > [pid 14119] brk(0xaa5f000) = 0xaa5f000 > [pid 14119] brk(0xaa82000) = 0xaa82000 > [pid 14119] brk(0xaaa3000) = 0xaaa3000 > [pid 14119] uname({sys="Linux", node="aine.fiee.net", ...}) = 0 This output looks quite messy because it is composed of the mixed output for five processes. I don't suspect the fault in luatex executable itself, however, mtxrun calls uname -m in a subshell and my guess is that it hangs there. Have you tried calling uname alone from your script? Next you could do strace -ff -o ctxtrace mtxrun --script context --batchmode --once hello This gives you hopefully four ctxtrace. files. Then do (for each pid) strace -p before killing luatex and see where it hangs. Interrupt and kill your luatex and have a look at the ctxtrace.* files. Florian ___________________________________________________________________________________ If your question is of interest to others as well, please add an entry to the Wiki! maillist : ntg-context@ntg.nl / http://www.ntg.nl/mailman/listinfo/ntg-context webpage : http://www.pragma-ade.nl / http://tex.aanhet.net archive : http://foundry.supelec.fr/projects/contextrev/ wiki : http://contextgarden.net ___________________________________________________________________________________