From owner-freebsd-questions@FreeBSD.ORG Wed Aug 25 13:45:35 2004 Return-Path: Delivered-To: freebsd-questions@freebsd.org Received: from mx1.FreeBSD.org (mx1.freebsd.org [216.136.204.125]) by hub.freebsd.org (Postfix) with ESMTP id 220D216A4CE for ; Wed, 25 Aug 2004 13:45:35 +0000 (GMT) Received: from mail.u4eatech.com (blackhole.u4eatech.com [195.188.241.2]) by mx1.FreeBSD.org (Postfix) with ESMTP id 4AA3343D55 for ; Wed, 25 Aug 2004 13:45:34 +0000 (GMT) (envelope-from richard.williamson@u4eatech.com) Received: by mail.u4eatech.com (Postfix, from userid 503) id B0DE836013B; Wed, 25 Aug 2004 14:45:32 +0100 (BST) Received: from apus.u4eatech.com (apus.degree2.com [172.30.40.129]) (using TLSv1 with cipher DES-CBC3-SHA (168/168 bits)) (No client certificate requested) by mail.u4eatech.com (Postfix) with ESMTP id 5AE8D360125 for ; Wed, 25 Aug 2004 14:45:29 +0100 (BST) Message-Id: <6.1.2.0.2.20040825144401.026fee78@cygnus> X-Sender: richard@cygnus X-Mailer: QUALCOMM Windows Eudora Version 6.1.2.0 Date: Wed, 25 Aug 2004 14:49:07 +0100 To: freebsd-questions@freebsd.org From: "Richard P. Williamson" In-Reply-To: <6.1.2.0.2.20040817153240.027486b8@cygnus> References: <6.1.2.0.2.20040817153240.027486b8@cygnus> Mime-Version: 1.0 Content-Type: text/plain; charset="us-ascii" X-Spam-Checker-Version: SpamAssassin 2.64 (2004-01-11) on mail X-Spam-Level: X-Spam-Status: No, hits=-4.9 required=5.0 tests=BAYES_00 autolearn=ham version=2.64 Subject: Re: using ttys to restart a process X-BeenThere: freebsd-questions@freebsd.org X-Mailman-Version: 2.1.1 Precedence: list List-Id: User questions List-Unsubscribe: , List-Archive: List-Post: List-Help: List-Subscribe: , X-List-Received-Date: Wed, 25 Aug 2004 13:45:35 -0000 Hello, According to ttys(5) and init(8), init will restart a process if it is found in ttys. Accordingly, I've added these two lines to my ttys file: ttyv0 "/bin/stp-server" unknown on ttyv1 "/manager/listener 4553" unknown on The first line appears to result in what I'm looking for, ie the stp-server runs, and if I kill it, the init process restarts it. The second line, however, gives me this message: Aug 25 14:33:38 FFProRDP init: getty repeating too quickly on \ port /dev/ttyv1, sleeping 30 secs What I'm looking for is an idea how to debug why the listener app is choking. /var/log/messages just repeats the 'init: getty' line. TIA, rip At 15:41 17/08/2004. Richard P. Williamson had this to say: >Hello, > >4.10-RELEASE > >According to ttys(5) and init(8), init will restart a process if it >is found in ttys. I can not find, however, an example syntax for >doing just that. > >Say I have a process called /usr/bin/sleeploop > ># is this how it works? >sleeper "/usr/bin/sleeploop -q 3000" none on insecure > >? Then, if I killall -s HUP sleeploop, it should 'magically reappear, >as if by magic', right? > >Loath to have a go on this on the running system, on the off chance >that I end up by breaking the boot sequence. > >TIA, >rip > >_______________________________________________ >freebsd-questions@freebsd.org mailing list >http://lists.freebsd.org/mailman/listinfo/freebsd-questions >To unsubscribe, send any mail to "freebsd-questions-unsubscribe@freebsd.org"