From owner-freebsd-questions@FreeBSD.ORG Sat Jan 27 20:07:40 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 54E4016A402 for ; Sat, 27 Jan 2007 20:07:40 +0000 (UTC) (envelope-from admin2@enabled.com) Received: from typhoon.enabled.com (typhoon.enabled.com [216.218.220.21]) by mx1.freebsd.org (Postfix) with ESMTP id 4611713C48D for ; Sat, 27 Jan 2007 20:07:40 +0000 (UTC) (envelope-from admin2@enabled.com) Received: from [172.23.10.40] (nat-service4.juniper.net [66.129.225.151]) (authenticated bits=0) by typhoon.enabled.com (8.13.8/8.13.8) with ESMTP id l0RK8E8i038471 (version=TLSv1/SSLv3 cipher=DHE-RSA-AES256-SHA bits=256 verify=NO) for ; Sat, 27 Jan 2007 12:08:15 -0800 (PST) (envelope-from admin2@enabled.com) Message-ID: <45BBB105.4010800@enabled.com> Date: Sat, 27 Jan 2007 12:07:33 -0800 From: Noah User-Agent: Thunderbird 1.5.0.9 (Macintosh/20061207) MIME-Version: 1.0 To: freebsd-questions@freebsd.org Content-Type: text/plain; charset=ISO-8859-1; format=flowed Content-Transfer-Encoding: 7bit Subject: sshd never restarts 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: Sat, 27 Jan 2007 20:07:40 -0000 Hi there, FreeBSD 4.9 openssh-3.6.1_6 so I have a script /usr/local/etc/rc.d/sshd.sh that I use to restart sshd but sshd most of the time never comes back. there is nothing relevant that makes it to /var/log/messages if I start sshd manually with /usr/local/etc/rc.d/sshd.sh there are no error messages. My /etc/ssh/sshd_config configuration is fine and has no errors. how can I assure that sshd restarts each time? when I am remote to the machine. I am locked out of it. --- snip --- # cat /usr/local/etc/rc.d/sshd.sh #!/bin/sh # # $FreeBSD: ports/security/openssh/files/sshd.in,v 1.1 2006/06/09 21:54:03 pav Exp $ # # PROVIDE: sshd # REQUIRE: NETWORKING SERVERS USR # BEFORE: LOGIN # # Add the following lines to /etc/rc.conf to enable sshd # # sshd_enable (bool): Set to "NO" by default # Set it to "YES" to enable sshd . /usr/local/etc/rc.subr name="sshd" rcvar=${name}_enable load_rc_config ${name} : ${sshd_enable="NO"} : ${sshd_pidfile="/var/run/sshd.pid"} command="/usr/local/sbin/${name}" run_rc_command "$1" # grep ssh /etc/rc.conf sshd_enable="YES" ---- snip ---