Thanks ... I think :) The beer sounds like a great idea ! Any stouts on tap ?
With respect to the "status" problem below I had tacked this problem onto
my pclbanner post of Jun 29 at ~15:31. I include it again below :
I also attempted removing the ",status@" ifhp entry to see what would happen.
(remember I have a HP 8000 connected - parallel - to a ExtendNet SX 2811C)
deslz:\
:lp=deslz%9100:\
:sd=/usr/spool/lpd/deslz:\
:mx#0:\
:bp=/usr/libexec/filters/pclbanner:\
:ifhp=model=hp8000,status@\
:if=/usr/libexec/filters/ifhp:
An lpr(using the perl pclbanner:) to deslz hangs for a couple of minutes and
then completes properly. The pagecount information in the status file is correct.
What can I do to keep the pagecount but get rid of the hang ? The relevant lines
from the status file are given below :
using model 'hp8000' at 14:26:34.177
pagecount using 'pjl info pagecount' at 14:26:34.178
setting up printer at 14:26:34.178
getting sync using 'pjl echo' at 14:26:34.178
sync done at 14:28:16.912
pagecounter 91804 at 14:28:16.912
pagecounter 91804 at 14:28:16.912
sending job file at 14:28:16.913
starting transfer at 14:28:16.913
file program = '/usr/bin/file -' at 14:28:16.913
started FILE_UTIL- '/usr/bin/file -' at 14:28:16.913
file information = 'ascii_text' at 14:28:16.933
initial job type 'ascii_text' at 14:28:16.934
decoded job type 'PCL' at 14:28:16.934
job type 'PCL' at 14:28:16.934
transferring 208 bytes at 14:28:16.934
3 percent done at 14:28:16.935
100 percent done at 14:28:16.935
finished writing file, cleaning up at 14:28:16.935
sent job file at 14:28:16.935
getting end using 'pjl job/eoj' at 14:28:16.935
end of job detected at 14:28:47.492
pagecounter 91806 at 14:28:47.992
pagecounter 91806, pages 2 at 14:28:47.992
done at 14:28:47.992
[EMAIL PROTECTED] wrote:
>
> Mr. David Kerr is hereby awarded 'The La Jolla Conch for Clever Shell Script
>Debugging'
>
> He can collect his prize at the Karl Strauss Brewery in La Jolla,
> as well as a Free Lunch.
>
> Patrick ("Bring a wet suit, a surf board, and life insurance") Powell
>
> > From [EMAIL PROTECTED] Thu Jul 6 13:50:20 2000
> > Date: Thu, 06 Jul 2000 15:08:38 -0400
> > From: David Livingstone <[EMAIL PROTECTED]>
> > To: [EMAIL PROTECTED], David Kerr Livingstone <[EMAIL PROTECTED]>
> > Subject: Re: [Fwd: LPRng: pclbanner problems from LPRng-3.6.14-1]
> >
> >
> > I'm using the default sh for redhat which is bash-1.14.7-22 ie /bin/sh is a link
> > to /bin/bash.
> >
> > Yes "sh pclbanner > /tmp/out" works - however no options are given.
> > I dug into this today and have found the following :
> >
> > - psbanner and pclbanner both have the same error at line 50 and 22
> > respectively :
> >
> > vAlue=`expr "$1" : '-.\(.*\)`;
>
> Yup. Right you are.
> >
> > is missing a ' and should read :
> >
> > vAlue=`expr "$1" : '-.\(.*\)'`;
> >
> > without the ' bash: unexpected EOF while looking for `'' is
> > returned.
> >
> > - all of the "test" expressions in pclbanner are missing spaces around
> > the oerators - the single test expression in psbanner is okay.
>
> Strange, the BSD test did not whinge on this, but the RedHat Linux
> did.
>
> >
> > - for example line 27 of pclbanner is given as :
> >
> > if test "X$vAlue"="X" ; then shift; vAlue=$1; fi;
> >
> > This "always" evaluates to true because = is not interpreted as a
> > an operator. This should read :
> >
> > if test "X$vAlue" = "X" ; then shift; vAlue=$1; fi;
> >
> > - There are six instances in pclbanner like this.
> >
> > - With the above changes pclbanner no correctly outputs the Title, Printer,
> > Host, User, Class, Jobid, Date, Queue, Printed at etc.
> >
> > However even with the above corrections pclbanner registers the following error
> > in the status.deslz file while interpreting the PRINTCAP_ENTRY :
> >
> > BANNER: /usr/libexec/filters/pclbanner: mx#0=1: command not found at
>2000-07-06-11:31:34.713 ## identifier=root@sccode+159 number=159 process=30162
> >
> > As recorded
> > in /tmp/before(debug file from pclbanner) the PRINTCAP_ENTRY is :
> > PRINTCAP_ENTRY=deslz
> > :bp=/usr/libexec/filters/pclbanner
> > :if=/usr/libexec/filters/ifhp
> > :ifhp=model=hp8000,status@
> > :lp=deslz%9100
> > :mx#0
> > :sd=/usr/spool/lpd/deslz
> >
> > I followed the logic and yes :
> >
> > vAr=`expr "$iI" : " *\:\([^=][^=]*\)=.*"`;
> > vAlue=`expr "$iI" : " *\:[^=][^=]*=\(.*\)"`;
> > if test "X$vAr" = "X" ; then
> > vAr=`expr "$iI" : " *:\(.*\)@"`;
> > vAlue=0;
> > fi
> > if test "X$vAr" = "X" ; then
> > vAr=`expr "$iI" : " *:\(.*\)"`;
> > vAlue=1;
> > fi
> > if test "X$vAr" != "X" ; then
> > eval $vAr='$vAlue';
> > #setvar $vAr "$vAlue"
> > fi
> > will give this result - I presume you should account for the "#" character
> > when parsing the line ?
> >
> > A couple of questions :
> > - how did this ever work in your setup ?
>
> used BSD /bin/sh (Bourne shell) and BSD test
>
> > - what shell are you using ?
>
> /bin/sh
>
> > - did you see the last question I had in my past posting on the use
> > of status@ ?
>
> No... what was it?
>
> >
> > Thanks as always.
> >
> > [EMAIL PROTECTED] wrote:
> > >
> > > > From [EMAIL PROTECTED] Fri Jun 30 14:37:42 2000
> > > > Date: Fri, 30 Jun 2000 16:01:01 -0400
> > > > From: David Livingstone <[EMAIL PROTECTED]>
> > > > To: [EMAIL PROTECTED]
> > > > Subject: Re: [Fwd: LPRng: pclbanner problems from LPRng-3.6.14-1]
> > > >
> > > >
> > > > Further to my own post :
> > > >
> > > > - the psbanner(sh version) in 3.6.19 exhibits the same problem. The perl
> > > > version from 3.6.13 works correctly. I can send whatever debug output
> > > > is needed.
> > > > - the symbolic link problem does not occur when installing 3.6.18 and
> > > > upgrading(freshen) to 3.6.19.
> > > >
> > >
> > > I just had a horrible thought. What shell are you using?
> > > Look and see what the pclbanner has for the #!/bin/sh value
> > > at the start. You may need to specify the shell you want to use.
> > >
> > > If this is not the problem, please do:
> > >
> > > sh psbanner >/tmp/out
> > >
> > > (note that there are no options).
> > >
> > > does this work? Does the /tmp/out get a file?
> > >
>
> Patrick Powell Astart Technologies,
> [EMAIL PROTECTED] 9475 Chesapeake Drive, Suite D,
> Network and System San Diego, CA 92123
> Consulting 858-874-6543 FAX 858-279-8424
> LPRng - Print Spooler (http://www.astart.com)
>
> -----------------------------------------------------------------------------
> If you need help, send email to [EMAIL PROTECTED] (or lprng-requests
> or lprng-digest-requests) with the word 'help' in the body. For the impatient,
> to subscribe to a list with name LIST, send mail to [EMAIL PROTECTED]
> with: | example:
> subscribe LIST <mailaddr> | subscribe lprng-digest [EMAIL PROTECTED]
> unsubscribe LIST <mailaddr> | unsubscribe lprng [EMAIL PROTECTED]
>
> If you have major problems, send email to [EMAIL PROTECTED] with the word
> LPRNGLIST in the SUBJECT line.
> -----------------------------------------------------------------------------
-----------------------------------------------------------------------------
If you need help, send email to [EMAIL PROTECTED] (or lprng-requests
or lprng-digest-requests) with the word 'help' in the body. For the impatient,
to subscribe to a list with name LIST, send mail to [EMAIL PROTECTED]
with: | example:
subscribe LIST <mailaddr> | subscribe lprng-digest [EMAIL PROTECTED]
unsubscribe LIST <mailaddr> | unsubscribe lprng [EMAIL PROTECTED]
If you have major problems, send email to [EMAIL PROTECTED] with the word
LPRNGLIST in the SUBJECT line.
-----------------------------------------------------------------------------