Solved

Print directly to jetdirect attached printer

Posted on 2009-07-01
4
1,037 Views
Last Modified: 2013-11-17
I have about 50 print queues setup on an AIX 5.3 server that attach to hp jetdirect interfaces.

I have a client that would like to print directly to the printer, bypassing the print queue. They print checks which sometimes jam and the print queue drops the job if the printer jams in the middle of printing.

Is there a way to use lp to print directly to the jetdirect interface?  (ie lp -d hp@printer1 outputfile)  Apparently they have avoided this in the past when using serial printers and printing directly to the device file (ie lp -d /dev/lp1 outputfile).
0
Comment
Question by:proservesolutions
  • 2
  • 2
4 Comments
 
LVL 68

Expert Comment

by:woolmilkporc
ID: 24757339
Hi,

which is the client's operating system?

Since the JetDirect cards act as printservers for themselves, it should easily be possible to define a lpr queue which uses the JetDirect as a printer host.

In AIX you would use

  • smitty mkpq ->
  • select 'hpJetDirect' ->
  • select 'Standard processing' if your application generates a suitable format OR
  • select 'Local filtering' if the format should be generated by a local driver ->
  • fill in values for hostname/queue etc. ->
  • Done.
Note that the appropriate hpJetDirect driver software (from AIX standard media) must be installed.

Btw., the above should be exactly the same setup as on your AIX 5.3 server!

wmp



0
 

Author Comment

by:proservesolutions
ID: 24757552
That is how I currently create the printers and queues on the AIX server. Maybe I am just not fully understanding the process.

The application itself resides on the AIX server and the app uses a "link" file to define printing aliases which are choices for the users within the app.

Here is what the app link file looks like:
To print to a queued printer-
alias P9 ">lp -s -dP9 2>/dev/null" "IBM 4226 Purchasing P/O" CR,CPCOLS=132,SPCOLS=132,lock=/tmp/p9.lck

To print direct to a printer-
alias P3 /dev/lp3 "IBM 4226 Computer Room" CR,CPCOLS=132,SPCOLS=132,lock=/tmp/p3.lck

I need to print directly to the jetdirect attached printer to avoid the issues when printing through the queue and the printer jams.
0
 
LVL 68

Accepted Solution

by:
woolmilkporc earned 500 total points
ID: 24757907
OK,

you will notice that in your examples above P9 uses the AIX lp command which works against a queue (and only a queue), whereas P3 is obviously driven by your application, not by an AIX printing interface.

The only interface program that I'm aware of which could (roughly) accomplish what you want is rembak.

It is qdaemon's backend and should normally only be used by qdaemon, but you can try.

The general format is

/usr/lib/lpd/rembak -S [Server] -P [Queue] ... [file]

The [file] parameter is mandatory (no stdin processing), thus your 'alias' method above will not work without generating an intermediate file.

Look at 'man rembak'

rembak works against a queue, but as opposed to the end-user tools, it doesn't use a local queue. It rather connects directly to the remote host's queue.

Chances are that the above will actually work, but operation of rembak by end users is very, very uncommon!

Good luck!

wmp



0
 

Author Closing Comment

by:proservesolutions
ID: 31598896
Thank you for a precise answer. After reading MANY posts on the subject, you provided a very clear precise answer.
0

Featured Post

Do You Know the 4 Main Threat Actor Types?

Do you know the main threat actor types? Most attackers fall into one of four categories, each with their own favored tactics, techniques, and procedures.

Join & Write a Comment

Linux users are sometimes dumbfounded by the severe lack of documentation on a topic. Sometimes, the documentation is copious, but other times, you end up with some obscure "it varies depending on your distribution" over and over when searching for …
Every server (virtual or physical) needs a console: and the console can be provided through hardware directly connected, software for remote connections, local connections, through a KVM, etc. This document explains the different types of consol…
Connecting to an Amazon Linux EC2 Instance from Windows Using PuTTY.
Get a first impression of how PRTG looks and learn how it works.   This video is a short introduction to PRTG, as an initial overview or as a quick start for new PRTG users.

707 members asked questions and received personalized solutions in the past 7 days.

Join the community of 500,000 technology professionals and ask your questions.

Join & Ask a Question

Need Help in Real-Time?

Connect with top rated Experts

12 Experts available now in Live!

Get 1:1 Help Now