SUMMARY: Client printing and Jetadmin on server

From: Gerard Henry (Gerard.Henry@cmi.univ-mrs.fr)
Date: Fri May 05 2000 - 07:45:48 CDT


I wrote:
>something is not correct in my configuration, it seems.
>
>i try to print on HP4000 in duplex mode... it doesn t work for sun clients on my network.

The response was given by Andrew.Scrivner@colorado.edu

It consists to do a hack in file
/etc/lp/interfaces/model.orig/<printer>.
I joined it attached if somebody interested.

-- 
Gerard HENRY

>From - Fri May 5 14:32:19 2000
Return-Path: <Andrew.Scrivner@colorado.edu>
Received: from refuge.Colorado.EDU (root@refuge.Colorado.EDU [128.138.196.2] (may be forged))
          by gyptis.univ-mrs.fr (8.9.1a/jtpda-5.3.1) with ESMTP id UAA20156
          for <Gerard.Henry@cmi.univ-mrs.fr>; Thu, 4 May 2000 20:12:55 +0200 (MET DST)
Received: from refuge.Colorado.EDU (scrivner@localhost [127.0.0.1])
        by refuge.Colorado.EDU (8.9.1a/8.9.3/UnixOps+Hesiod (PDH)) with ESMTP id MAA13745
        for <Gerard.Henry@cmi.univ-mrs.fr>; Thu, 4 May 2000 12:12:49 -0600 (MDT)
Message-Id: <200005041812.MAA13745@refuge.Colorado.EDU>
To: Gerard Henry <Gerard.Henry@gyptis.univ-mrs.fr>
Subject: Re: Client printing and Jetadmin on server
In-reply-to: Your message of Thu, 04 May 2000 18:06:38 +0200
Date: Thu, 04 May 2000 12:12:47 -0600
From: " Andrew Scrivner" <Andrew.Scrivner@colorado.edu>
X-Mozilla-Status: 8011
X-Mozilla-Status2: 00000000
X-UIDL: 5]j!!@'Qe9;]&!!=Z;!!

From: Gerard Henry <Gerard.Henry@cmi.univ-mrs.fr>
--------

>Hello,
>something is not correct in my configuration, it seems.
>
>i try to print on HP4000 in duplex mode.
>
>On my server, i've Jetadmin 6.21, on Solaris 7.
>I have a printer hpduplex defined, and i can print duplex because i
>modified /etc/lp/interfaces/hpduplex.
>
>on a client, i declare hpduplex in /etc/printers.conf.
>But when i print, it is not duplex!
>I look at logs of lpsched,
>
>05/04 17:46:59: Print services started.
> /opt/hpnp/bin/xjjm CLIENT:0 hpduplex-135 &
>/etc/lp/interfaces/model.orig/hpduplex duplexflist='/tmp/Jetadmin.ps'
>/opt/hpnp/bin/hpnpf -j hpduplex-135+henry -w -b20705
>-o/opt/hpnp/tmp/jadump -a1 -x hp -s /var/tmp/hpduplex.log
>
>
>if i try to replace /etc/lp/interfaces/model.orig/hpduplex by
>/etc/lp/interfaces/hpduplex, it doesn t work:
>
>05/04 18:05:02: printer fault. type: write root, status: c
>msg: (hpnpf (read bytes from socket): Connection reset by peer
>
>msg: (exec exit fault)
> /opt/hpnp/tmp/jm.hplatp-136 exists, not bring up Job Monitor.
>/etc/lp/interfaces/model.orig/model.orig/hplatp
>duplexduplexflist='/tmp/Jetadmin.ps'
>
>
>Anybody can't help me?
>
>
        This is an EXPERT hack, follow the instructions precisely and you
        should be fine.

 Creating a simplex/duplex queue:
        -------------------------------
        ***Experts only, this hack only applies to model scripts created
                by HP's jetadmin utility, but _may_ work for others, you
                have been warned.***

        The hack consists of three additions to a Solaris/jetadmin model
        script.
        Your network printer should be set to duplex always. You should
        name your queues something like {printer}1 and {printer}2 . We will
       now hack the model script for {printer}1, to force simplexing.

        A model script is normally quite long, and getting these entries
        placed properly is the key. If you would like a proper example
        please mail scrivner@colorado.edu. Note: Each search string occurs
        _ONCE_ in a model script, so it doesn't matter what type of model
        script you are modifying, just follow the example and you'll do
        fine.
        
        sudo vi /etc/lp/interfaces/model.orig/printer1

        search for setduplexmode in vi: /setduplexmode , you will now
        be looking at a case statement:

- ------First addition to the model_script------
 case "$duplex" in
    simplex) echo "false setduplexmode";;
    vduplex) echo "true setduplexmode"
             echo "false settumble";;
    hduplex) echo "true setduplexmode"
             echo "true settumble";;
  esac
# Add these two lines ( It's our hack give us credit for it! )
# UnixOps's hack to force it to print simplex
echo "false setduplexmode"

# echo "end"

  if [ "$mediasrc" = "6" ]
  then
    echo "90 rotate"
  fi
} # end of Output_PS_Options()

- ----End First part-----------

Now, still in vi, serach for Tumble: /Tumble you will now see another case
statement.

- ------Second addition to the model_script------

 case "$duplex" in
    simplex) echo "/Duplex false";;
    vduplex) echo "/Duplex true"
             echo "/Tumble false";;
    hduplex) echo "/Duplex true"
             echo "/Tumble true";;
  esac

# Add these two lines ( It's our hack give us credit for it! )
# UnixOp's hack part 2
echo "/Duplex false"

  case "$mediatype" in
     def) ;;
     *) echo "/DeferredMediaSelection true /MediaType ($mediatype)" ;;
  esac

  echo ">>setpagedevice"

- ----End Second part-----------

OK, almost done, lastly search for: 033&l2S yes I know it's a weird
        string, but then again, do you speak postscript? Again, this is
        another case statement.

- ------Third, and last, addition to the model_script------
            
           case "$duplex" in
                   simplex) echo "\033&l0S\c";;
                   vduplex) echo "\033&l1S\c";;
                   hduplex) echo "\033&l2S\c";;
               esac
# Add these two lines ( It's our hack give us credit for it! )
# UnixOp's hack part 2
 echo "\033&l0S\c"

# [ Added by Ramki for supporting Deskjet 2000C

                if [ "$PRINTMODEL" = "dj2000c" ]
                then
                        if [ -n "$fgcolor" ]

- ----End Third part-----------



This archive was generated by hypermail 2.1.2 : Fri Sep 28 2001 - 23:14:07 CDT