From owner-freebsd-hackers@freebsd.org Fri Sep 21 14:21:52 2018 Return-Path: Delivered-To: freebsd-hackers@mailman.ysv.freebsd.org Received: from mx1.freebsd.org (mx1.freebsd.org [IPv6:2610:1c1:1:606c::19:1]) by mailman.ysv.freebsd.org (Postfix) with ESMTP id 7262E109BB33 for ; Fri, 21 Sep 2018 14:21:52 +0000 (UTC) (envelope-from rwmaillists@googlemail.com) Received: from mail-wm1-x336.google.com (mail-wm1-x336.google.com [IPv6:2a00:1450:4864:20::336]) (using TLSv1.2 with cipher ECDHE-RSA-AES128-GCM-SHA256 (128/128 bits)) (Client CN "smtp.gmail.com", Issuer "Google Internet Authority G3" (verified OK)) by mx1.freebsd.org (Postfix) with ESMTPS id 029458157D for ; Fri, 21 Sep 2018 14:21:51 +0000 (UTC) (envelope-from rwmaillists@googlemail.com) Received: by mail-wm1-x336.google.com with SMTP id n11-v6so3477180wmc.2 for ; Fri, 21 Sep 2018 07:21:51 -0700 (PDT) X-Google-DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=1e100.net; s=20161025; h=x-gm-message-state:date:from:to:subject:message-id:in-reply-to :references:mime-version:content-transfer-encoding; bh=uCtHD0uoKCMKHXRGwF/db9p/xyWx76ksQQ9+gOEbIhI=; b=dJzIQMtelDdCmTiO4OGfKmfWqX4xojNKGTA3iEQT85APH816dg6m4Zt0cxqGi9uWbz bW3SAv4P6JYvDOlRoEM9QBwH/HjSR9gTNVMFt4Vn5qrPtZEDYpFyNMtypQn8GypyXy1q yJy6T4fpncYJqBveCwHhLqGAcqWt+6r2vwFK0KC4kYI6i6ZZ+vAOlVjrRx65DQ5ymdSQ JwsR3qnFp0zvI5F7W74eTn+TJUtHHZ2oD6S68/kr5buBrPG/Op2PJi+I+9q9eBJfkpWF tReLtXDQPa9wEqTDKXqrMJRyln5IYNFODIPt02nvf6RNO3S0XTXGyxNsbvU5CoZ1Swo9 G1bg== X-Gm-Message-State: APzg51B82nVPtxQOj1DWhVUmQ9Yi7Ayjve+3HtdsXQuU4+aGDga/OsLn 4rYWIxRjIhSzwRKBmwtn7B4iP/nO X-Google-Smtp-Source: ACcGV602kLbJqREGTBqjaYwdURcVS5nJXQ0rjFmpHb1zs/xJ4lAHG4bhbXDt5Fx/Qbj9voL4yGEDyw== X-Received: by 2002:a1c:ba46:: with SMTP id k67-v6mr7110655wmf.37.1537539710534; Fri, 21 Sep 2018 07:21:50 -0700 (PDT) Received: from gumby.homeunix.com ([2.125.48.184]) by smtp.gmail.com with ESMTPSA id y5-v6sm31124184wrd.5.2018.09.21.07.21.49 for (version=TLS1_2 cipher=ECDHE-RSA-CHACHA20-POLY1305 bits=256/256); Fri, 21 Sep 2018 07:21:50 -0700 (PDT) Date: Fri, 21 Sep 2018 15:21:48 +0100 From: RW To: freebsd-hackers@freebsd.org Subject: Re: Can't get pidfile to work in rc script Message-ID: <20180921152148.562c2771@gumby.homeunix.com> In-Reply-To: References: X-Mailer: Claws Mail 3.16.0 (GTK+ 2.24.32; amd64-portbld-freebsd11.1) MIME-Version: 1.0 Content-Type: text/plain; charset=US-ASCII Content-Transfer-Encoding: 7bit X-BeenThere: freebsd-hackers@freebsd.org X-Mailman-Version: 2.1.27 Precedence: list List-Id: Technical Discussions relating to FreeBSD List-Unsubscribe: , List-Archive: List-Post: List-Help: List-Subscribe: , X-List-Received-Date: Fri, 21 Sep 2018 14:21:52 -0000 On Thu, 20 Sep 2018 20:57:09 -0700 Lee Brown wrote: > I'm trying to get 2 separate sshd's running. I've created > /etc/rc.d/sshd_alternate but it always uses /var/run/sshd.pid and not > /var/run/sshd_alternate.pid. I tried > > sshd_alternate_pidfile="${pidfile}" Usually the pid file specified in an rc file is telling the script what the daemon is using. sshd doesn't seem to have a direct way of setting the pid file path, I think you would have to create an alternate sshd_config and pass that as an argument to sshd.