From owner-freebsd-questions@freebsd.org Tue Jan 30 22:34:16 2018 Return-Path: Delivered-To: freebsd-questions@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 85E23EC3AE4 for ; Tue, 30 Jan 2018 22:34:16 +0000 (UTC) (envelope-from drosih@rpi.edu) Received: from smtp9.server.rpi.edu (smtp9.server.rpi.edu [128.113.2.229]) (using TLSv1.2 with cipher ECDHE-RSA-AES256-GCM-SHA384 (256/256 bits)) (Client CN "canit.localdomain", Issuer "canit.localdomain" (not verified)) by mx1.freebsd.org (Postfix) with ESMTPS id 3269A85971 for ; Tue, 30 Jan 2018 22:34:15 +0000 (UTC) (envelope-from drosih@rpi.edu) Received: from smtp-auth1.server.rpi.edu (smtp-auth1.server.rpi.edu [128.113.2.231]) by smtp9.server.rpi.edu (8.14.4/8.14.4/Debian-8+deb8u2) with ESMTP id w0UMYDWQ020364 (version=TLSv1/SSLv3 cipher=ECDHE-RSA-AES256-GCM-SHA384 bits=256 verify=NOT); Tue, 30 Jan 2018 17:34:14 -0500 Received: from smtp-auth1.server.rpi.edu (localhost [127.0.0.1]) by smtp-auth1.server.rpi.edu (Postfix) with ESMTP id B45DB58019; Tue, 30 Jan 2018 17:34:13 -0500 (EST) Received: from [172.16.67.1] (gilead-qc124.netel.rpi.edu [128.113.124.17]) (using TLSv1 with cipher ECDHE-RSA-AES256-SHA (256/256 bits)) (No client certificate requested) (Authenticated sender: drosih) by smtp-auth1.server.rpi.edu (Postfix) with ESMTPSA id A6FB458018; Tue, 30 Jan 2018 17:34:13 -0500 (EST) From: "Garance A Drosehn" To: byrnejb@harte-lyne.ca Cc: freebsd-questions@freebsd.org Subject: Re: LPD listen directive? Date: Tue, 30 Jan 2018 17:34:13 -0500 X-Mailer: MailMate (1.10r5443) Message-ID: <0F811690-40FD-45F6-AAD7-BD24E1016DFF@rpi.edu> In-Reply-To: <870deecf052d36d03aae9613410b38ba.squirrel@webmail.harte-lyne.ca> References: <870deecf052d36d03aae9613410b38ba.squirrel@webmail.harte-lyne.ca> MIME-Version: 1.0 X-Virus-Scanned: ClamAV using ClamSMTP X-Bayes-Prob: 0.0001 (Score 0, tokens from: outgoing, @@RPTN) X-Spam-Score: 0.00 () [Hold at 10.10] X-CanIt-Incident-Id: 02V4KydH9 X-CanIt-Geo: ip=128.113.124.17; country=US; region=New York; city=Troy; latitude=42.7495; longitude=-73.5951; http://maps.google.com/maps?q=42.7495,-73.5951&z=6 X-CanItPRO-Stream: outgoing X-Canit-Stats-ID: Bayes signature not available X-Scanned-By: CanIt (www . roaringpenguin . com) on 128.113.2.229 X-BeenThere: freebsd-questions@freebsd.org X-Mailman-Version: 2.1.25 Precedence: list List-Id: User questions List-Unsubscribe: , List-Archive: List-Post: List-Help: List-Subscribe: , X-List-Received-Date: Tue, 30 Jan 2018 22:34:16 -0000 On 30 Jan 2018, at 16:48, James B. Byrne via freebsd-questions wrote: > Can lpd be configured such that it listens only on specific IP > addresses? If so where and how is it done? We are running lpd and > cups on the same host. Cups is configured to only listen on the > loopback address. But lpd is listening on all available addresses. > > netstat -a | grep LISTEN > tcp4 0 0 192.168.216.44.ssh *.* LISTEN > tcp4 0 0 localhost.ipp *.* LISTEN > tcp6 0 0 localhost.ipp *.* LISTEN > tcp4 0 0 *.printer *.* LISTEN > tcp6 0 0 *.printer *.* LISTEN The man page for 'lpd' describes a few options which might help you, depending on what you want. '-s' means that lpd won't be listening anywhere (however printing for all users on the localhost should still work fine). '-4' means it listens only on IPv4 addresses, and '-6' means it listens only on IPv6 addresses. Unless you're doing something odd, you would only need 'lpd' listening on localhost if you have printcap entries which point at rm=localhost . I haven't done much with CUPS, but IIRC it needs to be listening on localhost or printing doesn't work for anyone. -- Garance Alistair Drosehn = drosih@rpi.edu Senior Systems Programmer or gad@FreeBSD.org Rensselaer Polytechnic Institute; Troy, NY; USA