From owner-freebsd-questions@FreeBSD.ORG Sat Apr 8 20:01:35 2006 Return-Path: X-Original-To: freebsd-questions@freebsd.org 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 8DE2316A400 for ; Sat, 8 Apr 2006 20:01:35 +0000 (UTC) (envelope-from bill@celestial.com) Received: from mail.mi.celestial.com (dagney.celestial.com [192.136.111.7]) by mx1.FreeBSD.org (Postfix) with ESMTP id 3F0B643D46 for ; Sat, 8 Apr 2006 20:01:35 +0000 (GMT) (envelope-from bill@celestial.com) Received: from localhost (localhost [127.0.0.1]) by mail.mi.celestial.com (Postfix) with ESMTP id 8186271FB4; Sat, 8 Apr 2006 13:01:34 -0700 (PDT) Received: from mail.mi.celestial.com ([127.0.0.1]) by localhost (alexis.mi.celestial.com [127.0.0.1]) (amavisd-new, port 10024) with LMTP id 60560-06-2; Sat, 8 Apr 2006 13:01:33 -0700 (PDT) Received: by mail.mi.celestial.com (Postfix, from userid 203) id 9E62171AB7; Sat, 8 Apr 2006 13:01:33 -0700 (PDT) Date: Sat, 8 Apr 2006 13:01:33 -0700 From: Bill Campbell To: freebsd-questions@freebsd.org Message-ID: <20060408200133.GA67999@alexis.mi.celestial.com> Mail-Followup-To: freebsd-questions@freebsd.org References: <00ef01c65b44$64654520$0200a8c0@satellite> Mime-Version: 1.0 Content-Type: text/plain; charset=us-ascii Content-Disposition: inline In-Reply-To: <00ef01c65b44$64654520$0200a8c0@satellite> User-Agent: Mutt/1.4.2.1i X-Virus-Scanned: amavisd-new at mi.celestial.com Subject: Re: FreeBSD6 or samba, printing blank end page X-BeenThere: freebsd-questions@freebsd.org X-Mailman-Version: 2.1.5 Precedence: list Reply-To: freebsd@celestial.com List-Id: User questions List-Unsubscribe: , List-Archive: List-Post: List-Help: List-Subscribe: , X-List-Received-Date: Sat, 08 Apr 2006 20:01:35 -0000 On Sat, Apr 08, 2006, Dave wrote: >Hello, > I've got a Freebsd6 print server that has two printers attached to it, >both hp models one a deskjet the other a laserjet. Both are exhibiting the >same behavior, whenever i print something from a windows box, xp in this >case, the windows boxes use windows printer drivers and samba3 for this, >the document i want is printed and removed from the unix print queue no >problem. The issue, minor though annoying, is at the end of every document >the printer ejects the last page as it should, but then i get one blank >page spat out of the printers. I am unsure how to debug this, if it's >samba, or freebsd or the unix script i am using for unix to talk to the >printer. Any help appreciated. My config is below. Typically this is caused by printer output that's padded with blank lines to fill the page size which causes an automatic page feed from the printer. The printer interface then sends a form feed character to eject the last page which is blank. My solution for this, which goes back over 20 years to Tandy Xenix systems, it to use a printer interface script/filter that (a) strips all trailing blank lines from the output, and (b) sends an appropriate printer sequence to eject the last page. The printer sequence for many dot-matrix printers is FF (octal 013, hex 0xb). The sequence for HP laser printers is E which is really a reset command, but it will print a page if there's anything it the printer's buffer. Bill -- INTERNET: bill@Celestial.COM Bill Campbell; Celestial Software LLC URL: http://www.celestial.com/ PO Box 820; 6641 E. Mercer Way FAX: (206) 232-9186 Mercer Island, WA 98040-0820; (206) 236-1676 ``It wasn't raining when Noah built the ark.''