From owner-freebsd-questions Thu Mar 13 23:47:23 2003 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 D10FE37B401 for ; Thu, 13 Mar 2003 23:47:21 -0800 (PST) Received: from smtp.infracaninophile.co.uk (ns0.infracaninophile.co.uk [81.2.69.218]) by mx1.FreeBSD.org (Postfix) with ESMTP id E9E2743FCB for ; Thu, 13 Mar 2003 23:47:19 -0800 (PST) (envelope-from m.seaman@infracaninophile.co.uk) Received: from happy-idiot-talk.infracaninophile.co.uk (localhost [127.0.0.1]) by smtp.infracaninophile.co.uk (8.12.8/8.12.8) with ESMTP id h2E7lFgb087321 (version=TLSv1/SSLv3 cipher=DHE-RSA-AES256-SHA bits=256 verify=NO); Fri, 14 Mar 2003 07:47:15 GMT (envelope-from matthew@happy-idiot-talk.infracaninophile.co.uk) Received: (from matthew@localhost) by happy-idiot-talk.infracaninophile.co.uk (8.12.8/8.12.8/Submit) id h2E7lF3w087320; Fri, 14 Mar 2003 07:47:15 GMT Date: Fri, 14 Mar 2003 07:47:15 +0000 From: Matthew Seaman To: Vijay.Singh@nokia.com Cc: questions@FreeBSD.ORG Subject: Re: init and process restart Message-ID: <20030314074715.GA86998@happy-idiot-talk.infracaninophi> Mail-Followup-To: Matthew Seaman , Vijay.Singh@nokia.com, questions@FreeBSD.ORG References: <4D7B558499107545BB45044C63822DDE01AF2A38@mvebe001.americas.nokia.com> Mime-Version: 1.0 Content-Type: text/plain; charset=us-ascii Content-Disposition: inline In-Reply-To: <4D7B558499107545BB45044C63822DDE01AF2A38@mvebe001.americas.nokia.com> User-Agent: Mutt/1.5.3i X-Spam-Status: No, hits=-29.3 required=5.0 tests=EMAIL_ATTRIBUTION,IN_REP_TO,REFERENCES,REPLY_WITH_QUOTES, USER_AGENT_MUTT version=2.50 X-Spam-Checker-Version: SpamAssassin 2.50 (1.173-2003-02-20-exp) Sender: owner-freebsd-questions@FreeBSD.ORG Precedence: bulk List-ID: List-Archive: (Web Archive) List-Help: (List Instructions) List-Subscribe: List-Unsubscribe: X-Loop: FreeBSD.ORG On Thu, Mar 13, 2003 at 02:52:42PM -0800, Vijay.Singh@nokia.com wrote: > Hi. Is it possible to use init to restart some user critical processes if they die. Has any work been done in this area. Please CC me. You mean in the same way that you can use /etc/inittab on SysV style machines? It's possible to do under *BSD, although not exactly equivalent, by editing /etc/ttys. Note that there's * No concept of run-levels under BSD. Your process will be started on bootup by init as soon as the machine goes multiuser and continue running until init (and the machine) shuts down. * The process has to be associated with a tty. Furthermore, it will prevent you running getty(8) on that tty, thus blocking it as a place for users to login. You should also consider Dan Bernstein's daemontools package, available in ports as sysutils/daemontools: http://pobox.com/~djb/daemontools.html specifically the supervise and svc programs. Cheers, Matthew -- Dr Matthew J Seaman MA, D.Phil. 26 The Paddocks Savill Way PGP: http://www.infracaninophile.co.uk/pgpkey Marlow Tel: +44 1628 476614 Bucks., SL7 1TH UK To Unsubscribe: send mail to majordomo@FreeBSD.org with "unsubscribe freebsd-questions" in the body of the message