From owner-freebsd-questions Wed Apr 22 14:47:26 1998 Return-Path: Received: (from majordom@localhost) by hub.freebsd.org (8.8.8/8.8.8) id OAA09108 for freebsd-questions-outgoing; Wed, 22 Apr 1998 14:47:26 -0700 (PDT) (envelope-from owner-freebsd-questions@FreeBSD.ORG) Received: from mail.iconz.co.nz (mail.iconz.co.nz [202.14.100.36]) by hub.freebsd.org (8.8.8/8.8.8) with ESMTP id VAA09066 for ; Wed, 22 Apr 1998 21:47:19 GMT (envelope-from jonc@pinnacle.co.nz) Received: from news.iconz.co.nz (status.gen.nz [202.14.100.1]) by mail.iconz.co.nz (8.8.7/8.8.7) with ESMTP id JAA196060893281609; Thu, 23 Apr 1998 09:46:49 +1200 (NZST) Received: (from uucp@localhost) by news.iconz.co.nz (8.8.5/8.8.5) with UUCP id JAA20454; Thu, 23 Apr 1998 09:49:57 +1200 Received: from tui.pinnacle.co.nz (tui.pinnacle.co.nz [202.37.163.3]) by kakapo.pinnacle.co.nz (8.8.8/8.8.8) with ESMTP id JAA09046; Thu, 23 Apr 1998 09:34:45 +1200 (NZST) Received: from localhost (jonc@localhost) by tui.pinnacle.co.nz (8.8.8/8.8.8) with SMTP id JAA09010; Thu, 23 Apr 1998 09:34:44 +1200 (NZST) X-Authentication-Warning: tui.pinnacle.co.nz: jonc owned process doing -bs Date: Thu, 23 Apr 1998 09:34:44 +1200 (NZST) From: Jonathan Chen To: Robert Beer cc: freebsd-questions@FreeBSD.ORG Subject: Re: 2.2.5 Printing Problem In-Reply-To: Message-ID: MIME-Version: 1.0 Content-Type: TEXT/PLAIN; charset=US-ASCII Sender: owner-freebsd-questions@FreeBSD.ORG Precedence: bulk X-Loop: FreeBSD.ORG On Wed, 22 Apr 1998, Robert Beer wrote: > A user is trying to print a large Postscript file to a JetDirect remote > queue from a 2.2.5R system with the lpd patch installed. The file just > stops printing and lpq gives this error: > > HostName: Warning: no daemon present > > I have been able to print the file after raising the ct value. In watching > with tcpdump during a test with a lower ct value printing stopped very > close to that time. Data was continuously sent until the ct time was > execeeded. Any suggestions? Did you apply that patch which Joerg submitted? -- Jonathan Chen Once is dumb luck. Twice is coincidence. Three times and Somebody Is Trying To Tell You Something. --------------------forwarded mail----------------------------------- When merging the new `ct' printcap functionality into 2.2-stable right before 2.2.5-RELEASE was due, it's now apparent that I didn't test it enough before. :-( I've introduced a fatal bug that causes all the lpd children sending jobs to remote printers to be killed after the `ct' timeout, even in case the connection came up properly. For small jobs, you won't notice this immediately (the default timeout is 120 seconds, and modern printers can print a lot within this time), but large jobs will ultimately be aborted then. Sorry for the inconvenience. For those of you who do need to operate on remote printers, please either do upgrade to the latest 2.2-stable, or apply the patch below, rebuild and reinstall your lpd. Sorry again, Joerg Index: src/usr.sbin/lpr/common_source/displayq.c =================================================================== RCS file: /home/ncvs/src/usr.sbin/lpr/common_source/displayq.c,v retrieving revision 1.4.2.5 retrieving revision 1.4.2.6 diff -u -u -r1.4.2.5 -r1.4.2.6 --- displayq.c 1997/10/15 12:25:35 1.4.2.5 +++ displayq.c 1997/11/07 13:20:29 1.4.2.6 @@ -242,6 +242,7 @@ savealrm = signal(SIGALRM, alarmhandler); alarm(CT); fd = getport(RM, 0); + alarm(0); (void)signal(SIGALRM, savealrm); if (fd < 0) { if (from != host) Index: src/usr.sbin/lpr/lpd/printjob.c =================================================================== RCS file: /home/ncvs/src/usr.sbin/lpr/lpd/printjob.c,v retrieving revision 1.11.2.3 retrieving revision 1.11.2.4 diff -u -u -r1.11.2.3 -r1.11.2.4 --- printjob.c 1997/10/15 09:56:00 1.11.2.3 +++ printjob.c 1997/11/07 13:20:37 1.11.2.4 @@ -1474,6 +1474,7 @@ savealrm = signal(SIGALRM, alarmhandler); alarm(CT); pfd = getport(cp, port); + alarm(0); (void)signal(SIGALRM, savealrm); if (pfd < 0 && errno == ECONNREFUSED) resp = 1; @@ -1541,6 +1542,7 @@ savealrm = signal(SIGALRM, alarmhandler); alarm(CT); pfd = getport(RM, 0); + alarm(0); (void)signal(SIGALRM, savealrm); if (pfd >= 0) { (void) snprintf(line, sizeof(line), "\2%s\n", RP); To Unsubscribe: send mail to majordomo@FreeBSD.org with "unsubscribe freebsd-questions" in the body of the message