From mboxrd@z Thu Jan 1 00:00:00 1970 X-Msuck: nntp://news.gmane.io/gmane.comp.tex.context/62468 Path: news.gmane.org!not-for-mail From: Henning Hraban Ramm Newsgroups: gmane.comp.tex.context Subject: Re: calling ConTeXt as a background process (SOLVED) Date: Fri, 8 Oct 2010 21:44:04 +0200 Message-ID: <8F16AAE5-1206-43F6-B6DD-FD0F0D187E19@fiee.net> 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> <95274FC9-42F1-4842-9943-103608507CB4@awi.de> <21C6E902-A3A4-4C4A-A9A0-2874DA107559@fiee.net> <6221687B-B252-4B09-BE36-4868261B78E1@awi.de> <2EDDB365-D3B3-448A-B854-55F768FA791D@fiee.net> <4CAF227D.3000703@elvenkind.com> <26119B9C-134E-4106-9EA9-06034A4DD083@fiee.net> <90D46F76-AE5F-4A42-9FDC-8FAA3CE91EEF@awi.de> Reply-To: mailing list for ConTeXt users NNTP-Posting-Host: lo.gmane.org Mime-Version: 1.0 (Apple Message framework v936) Content-Type: text/plain; charset="us-ascii"; Format="flowed"; DelSp="yes" Content-Transfer-Encoding: 7bit X-Trace: dough.gmane.org 1286567059 30334 80.91.229.12 (8 Oct 2010 19:44:19 GMT) X-Complaints-To: usenet@dough.gmane.org NNTP-Posting-Date: Fri, 8 Oct 2010 19:44:19 +0000 (UTC) To: mailing list for ConTeXt users Original-X-From: ntg-context-bounces@ntg.nl Fri Oct 08 21:44:16 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 1P4IrY-0007z8-7z for gctc-ntg-context-518@m.gmane.org; Fri, 08 Oct 2010 21:44:16 +0200 Original-Received: from localhost (localhost [127.0.0.1]) by balder.ntg.nl (Postfix) with ESMTP id 0152ACA757; Fri, 8 Oct 2010 21:44:15 +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 gEHPfPZLTg+I; Fri, 8 Oct 2010 21:44:12 +0200 (CEST) Original-Received: from balder.ntg.nl (localhost [127.0.0.1]) by balder.ntg.nl (Postfix) with ESMTP id 22ABECA761; Fri, 8 Oct 2010 21:44:12 +0200 (CEST) Original-Received: from localhost (localhost [127.0.0.1]) by balder.ntg.nl (Postfix) with ESMTP id 6DEDFCA761 for ; Fri, 8 Oct 2010 21:44:11 +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 8BxSu64K8mJy for ; Fri, 8 Oct 2010 21:44:08 +0200 (CEST) Original-Received: from filter4-nij.mf.surf.net (filter4-nij.mf.surf.net [195.169.124.155]) by balder.ntg.nl (Postfix) with ESMTP id D5E20CA757 for ; Fri, 8 Oct 2010 21:44:08 +0200 (CEST) Original-Received: from turan.fiee.net (turan.fiee.net [87.230.77.106]) by filter4-nij.mf.surf.net (8.14.3/8.14.3/Debian-5+lenny1) with ESMTP id o98Ji6gR013569 for ; Fri, 8 Oct 2010 21:44:07 +0200 X-No-Auth: unauthenticated sender Original-Received: from turan.fiee.net (lvps87-230-77-106.dedicated.hosteurope.de [127.0.0.1]) by turan.fiee.net (Postfix) with ESMTP id 23F2F35D44022 for ; Fri, 8 Oct 2010 21:44:06 +0200 (CEST) Original-Received: from [10.128.9.9] (199-149.76-83.cust.bluewin.ch [83.76.149.199]) by turan.fiee.net (Postfix) with ESMTP for ; Fri, 8 Oct 2010 21:44:05 +0200 (CEST) In-Reply-To: <90D46F76-AE5F-4A42-9FDC-8FAA3CE91EEF@awi.de> X-Mailer: Apple Mail (2.936) X-Bayes-Prob: 0.0001 (Score 0, tokens from: @@RPTN) X-CanIt-Geo: ip=87.230.77.106; country=DE; region=07; city=Host; latitude=51.6500; longitude=6.1833; http://maps.google.com/maps?q=51.6500,6.1833&z=6 X-CanItPRO-Stream: uu:ntg-context@ntg.nl (inherits from uu:default, base:default) X-Canit-Stats-ID: 04DgjI6eQ - f71518a968c1 - 20101008 X-Scanned-By: CanIt (www . roaringpenguin . com) on 195.169.124.155 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:62468 Archived-At: Ok, the failures were the same with fcgi and gunicorn app servers. But it _works_ with django's dev server (which you must not use in production due to memory/security holes etc.). While ConTeXt runs it looks like: 5852 25767 TS 21 18:04 pts/0 00:00:00 \_ python manage.py runserver 8000 1477 5852 TS 23 18:07 pts/0 00:00:03 \_ /var/www/ cerebrale/bin/python manage.py runserver 8000 3395 1477 TS 22 18:08 pts/0 00:00:00 \_ /bin/sh -c date "+%Y-%m-%d %H:%M:%S" && cd /var/www/.../_textemp && /var/opt/ context/tex/texmf-linux-64/bin/context --purgeall --batchmode -- result="/var/www/... 3397 3395 TS 22 18:08 pts/0 00:00:00 \_ /bin/ sh /var/opt/context/tex/texmf-linux-64/bin/context --purgeall -- batchmode --result=/var/www/... 3398 3397 TS 15 18:08 pts/0 00:00:00 \_ texlua /var/opt/context/tex/texmf-linux-64/bin/mtxrun --script context --purgeall --batchmode --result=/var/www/... 3400 3398 TS 21 18:08 pts/0 00:00:00 \_ luatex --interaction=batchmode --fmt=/var/opt/context/tex/texmf- cache/.../cont-en --lua=/var/opt/context/tex... TeX completes fast, and everything seems well afterwards. But I started that app server from an active shell. Maybe that's the difference? Right, if I start gunicorn manually, it also works. So, the culprit seems to be the automatic background start of the app server via daemontools. I'll have to test other means of starting and supervising the processes - e.g. runit or supervisor. Since I like Python and don't want to replace "init" yet, I try the latter first. Some hours later: YES IT WORKS with supervisor so far! Thank you all for your patience, ideas and help! Greetlings from Lake Constance! Hraban --- http://www.fiee.net/texnique/ http://wiki.contextgarden.net https://www.cacert.org (I'm an assurer) ___________________________________________________________________________________ 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 ___________________________________________________________________________________