1838378 Members
4293 Online
110125 Solutions
New Discussion

Re: Double-Side Printing

 
SOLVED
Go to solution
david_252
Frequent Advisor

Double-Side Printing

Team:

I have the foll. questions on lp.

1. Is there an option in "lp" to make duplex printing possible?
2.Is there any other command (line enscript) which has this capability
3.how to make double-sided printing in Unix possible?

Thanks

David.
10 REPLIES 10
Pete Randall
Outstanding Contributor

Re: Double-Side Printing

David,

The lp command is "lp -o double file_name".



Pete

Pete
Armin Feller
Honored Contributor

Re: Double-Side Printing

Most printer options are not options to the actual lp command but options passed from the lp command to the interface script for the specific print queue. The options are specific to the actual script used. Most HP scripts use the options -oduplex or -odouble to specify double sided printing. Single sided printing can usually be specified with -osimplex.
david_252
Frequent Advisor

Re: Double-Side Printing

Hi:

Can you pl. explain what you mean by double_filename?

Thanks

David.
Pete Randall
Outstanding Contributor
Solution

Re: Double-Side Printing

David,

I meant "-o double" is the option requesting double sided printing, and "file_name" is the file you're trying to print.


Pete

Pete
Armin Feller
Honored Contributor

Re: Double-Side Printing

# lp -o double -d

e.g.
if you want to print the file /tmp/testprint to the printer HPLJ8000

# lp -o double -dHPLJ8000 /tmp/testprint
rmueller58
Valued Contributor

Re: Double-Side Printing

Depends....

If you are using the hppi (jetadmin) utility you can general setup your queues with the
"-o duplex" option depending on the printer..


If you are using lpadmin it is a whole different scenario. Some printers don't play well on UX I prefer using jetadmin It makes life simpler..

lp -d -oc (compressed) -oduplex

other features

-olandscape

-ovsi7.27 (for ideal vertical line spacing on portrait letter)

-ovsi5.45 (for ideal vertical line spacing on landscape letter)


Bill Hassell
Honored Contributor

Re: Double-Side Printing

Note that while the vast majority of Unix commands take options followed by parameters, the lp command does not understand some of the options if they have value separated from the option. It is a good idea to always specify - options with no space:

lp -dprinter_name -od -olandscape some_file_to_print

Note that -oduplex can be abbreviated -od. Now all of this assumes that the printer you have has been matched with an appropriate model script. HP-UX only supplies model-specific scripts for HP printers. To see a short list of the options that a script supports, you can print an option page:

lp -dprinter -ooptions /etc/issue

That's correct: -ooptions will print an extra page with the details. For serial/parallel printers connected directly to your HP-UX box, there are no man pages for the printer scripts so use -ooptions to show a quick list. For HP printers connected using HP's JetDirect interface card, there are man pages for the model scripts. man on the following scripts: net_lj3plus.1 net_lj3x.1 net_lj4550.1 net_lj4x.1 net_lj5x.1 net_lj8150.1 net_ljc
olor.1 net_ljx000.1

Now all of this is meaningless if the printer is NOT connected to the HP-UX box but on some non-HP-UX server. In that case, there are no -o options and very little control over the printed output.


Bill Hassell, sysadmin
david_252
Frequent Advisor

Re: Double-Side Printing

Hi:

How do I find my interface script and how do I find its available options?

Thanks

David.
rmueller58
Valued Contributor

Re: Double-Side Printing

/opt/hpnpl/sh/

man
dumbplot net_dsnj net_lj3plus net_ljcolor
dumbplot_printer net_genericpcl3printer net_lj3x net_ljx000
dumbplot_printer_cr net_genericplotter net_lj4x topcl
hpnp.model net_genericprinter net_lj5x tops

IF you are using Jetdirect


for other model scripts see

/var/spool/lp/model

Bill Hassell
Honored Contributor

Re: Double-Side Printing

For the collection of direct-connect model scripts, look in /usr/lib/lp/model. For JetDirect, the man pages will work. To see what model script was setup for your printer, look in /etc/lp/interface. The files in that directory are copies of the model or template scripts, renamed to point to each printer. If the script is for rlp (remote lp) then there will be just a few cryptic options.


Bill Hassell, sysadmin