- Community Home
- >
- Servers and Operating Systems
- >
- Operating Systems
- >
- Operating System - HP-UX
- >
- I need to change the ESC CODES sent to an HP Laser...
Operating System - HP-UX
1753964
Members
7301
Online
108811
Solutions
Forums
Categories
Company
Local Language
back
Forums
Discussions
Forums
- Data Protection and Retention
- Entry Storage Systems
- Legacy
- Midrange and Enterprise Storage
- Storage Networking
- HPE Nimble Storage
Discussions
Discussions
Discussions
Forums
Discussions
back
Discussion Boards
Discussion Boards
Discussion Boards
Discussion Boards
- BladeSystem Infrastructure and Application Solutions
- Appliance Servers
- Alpha Servers
- BackOffice Products
- Internet Products
- HPE 9000 and HPE e3000 Servers
- Networking
- Netservers
- Secure OS Software for Linux
- Server Management (Insight Manager 7)
- Windows Server 2003
- Operating System - Tru64 Unix
- ProLiant Deployment and Provisioning
- Linux-Based Community / Regional
- Microsoft System Center Integration
Discussion Boards
Discussion Boards
Discussion Boards
Discussion Boards
Discussion Boards
Discussion Boards
Discussion Boards
Discussion Boards
Discussion Boards
Discussion Boards
Discussion Boards
Discussion Boards
Discussion Boards
Discussion Boards
Discussion Boards
Discussion Boards
Discussion Boards
Discussion Boards
Discussion Boards
Blogs
Information
Community
Resources
Community Language
Language
Forums
Blogs
Topic Options
- Subscribe to RSS Feed
- Mark Topic as New
- Mark Topic as Read
- Float this Topic for Current User
- Bookmark
- Subscribe
- Printer Friendly Page
- Mark as New
- Bookmark
- Subscribe
- Mute
- Subscribe to RSS Feed
- Permalink
- Report Inappropriate Content
01-22-2009 05:38 PM
01-22-2009 05:38 PM
I need to change the ESC CODES sent to an HP Laser jet printer when printing in postscript
Ok, I've determined that when doing postscript, the -otray... doesn't work. I've been at this for 3 days now! I know that at the end of 2006, I found a generic article for Unix systems on how to change the destination tray sent to a printer. It was an issue of change the numbers (oddly enough) that were assigned to the HP trays (8,4,2,1 etc). I could have sworn that I made the changes in /etc/ or in /dev. From what I can tell and my current testing - it was NOT in either /etc/lp/interface/ and NOT in /etc/lp/interface/model.orig/.
I tested this by adding a NEW printer to the system, (using hppi) and comparing the files from the printer that works, and the printer that doesn't. They are EXACTLY the same. And yet - If I print to two printers that are EXACTLY the same using the two defined printers, I get different tray results. Which is what I expected, because I had to go to some different place to make the changes. If I take the two printers and swap them out (they are both the exact same model), then the problem doesn't travel with the printer, it stays with the IP address of the "new" printer, even if I swap old with new by rolling old printer to new location, and plugging in, swapping IP addresses hard coded into the printer, and doing the same with the other. In other words, an even swap. And still, the printer which is now defined as the "OLD" one can print to the right tray, and the old one sitting in the "NEW" one's slot cannot.
So, it's definitely sitting at the OS level. And it's not the command line option from "lp", and its not in the two interface files under /etc/lp/interface and /etc/lp/interface/model.orig (they are exactly the same for both printers, except for the names of the respective printers of course).
The file being printed comes from oracle which is using the lp command with the "-oraw" option. The result is the same if I use the "-ops" option. Either way, it works the same - great for the old defined printer, bad for the new. Keep in mind that if you use either of those, the rest of your "suggestions" for printing are ignored, and the commands come from the postscript file itself.
I know to the day when I created the printers, and have verified this via my old electronic appointments calendar in which the tech rep was here on site, and it agrees with his old electronic calendar (Palm Pilot). The only files I can find changed within that very week are, sadly the two files previously mentioned in /etc/lp/interface and model.orig! Which means that the other files I've touched in the system have been touched afterwards, I guess!
I've researched tons of articles on ITRC and also the internet in general, and I can't make any headway. I also scoured all I could find in /opt/hpnpl/sh as well as the scripts in /opt/hpnpl/admin/printers - both printers are using "10.cfg" from here. Once again, everything the same... sigh.
Can anyone tell me what else controls printer trays (attributes) besides /etc/lp/interface and model.orig and /opt/hpnpl/admin/printers/xxx.cfg files?
I know that I've seen it/did it before. I remember it WASN'T an HP document that I used, and that I seem to remember it was more of a general UNIX reference sheet for lp. Sun or IBM possibly, I'm thinking Sun right now, but that may not be right.
Any help appreciated.
I tested this by adding a NEW printer to the system, (using hppi) and comparing the files from the printer that works, and the printer that doesn't. They are EXACTLY the same. And yet - If I print to two printers that are EXACTLY the same using the two defined printers, I get different tray results. Which is what I expected, because I had to go to some different place to make the changes. If I take the two printers and swap them out (they are both the exact same model), then the problem doesn't travel with the printer, it stays with the IP address of the "new" printer, even if I swap old with new by rolling old printer to new location, and plugging in, swapping IP addresses hard coded into the printer, and doing the same with the other. In other words, an even swap. And still, the printer which is now defined as the "OLD" one can print to the right tray, and the old one sitting in the "NEW" one's slot cannot.
So, it's definitely sitting at the OS level. And it's not the command line option from "lp", and its not in the two interface files under /etc/lp/interface and /etc/lp/interface/model.orig (they are exactly the same for both printers, except for the names of the respective printers of course).
The file being printed comes from oracle which is using the lp command with the "-oraw" option. The result is the same if I use the "-ops" option. Either way, it works the same - great for the old defined printer, bad for the new. Keep in mind that if you use either of those, the rest of your "suggestions" for printing are ignored, and the commands come from the postscript file itself.
I know to the day when I created the printers, and have verified this via my old electronic appointments calendar in which the tech rep was here on site, and it agrees with his old electronic calendar (Palm Pilot). The only files I can find changed within that very week are, sadly the two files previously mentioned in /etc/lp/interface and model.orig! Which means that the other files I've touched in the system have been touched afterwards, I guess!
I've researched tons of articles on ITRC and also the internet in general, and I can't make any headway. I also scoured all I could find in /opt/hpnpl/sh as well as the scripts in /opt/hpnpl/admin/printers - both printers are using "10.cfg" from here. Once again, everything the same... sigh.
Can anyone tell me what else controls printer trays (attributes) besides /etc/lp/interface and model.orig and /opt/hpnpl/admin/printers/xxx.cfg files?
I know that I've seen it/did it before. I remember it WASN'T an HP document that I used, and that I seem to remember it was more of a general UNIX reference sheet for lp. Sun or IBM possibly, I'm thinking Sun right now, but that may not be right.
Any help appreciated.
We are the people our parents warned us about --Jimmy Buffett
1 REPLY 1
- Mark as New
- Bookmark
- Subscribe
- Mute
- Subscribe to RSS Feed
- Permalink
- Report Inappropriate Content
01-22-2009 08:26 PM
01-22-2009 08:26 PM
Re: I need to change the ESC CODES sent to an HP Laser jet printer when printing in postscript
The problem is not in HP-UX, or even in lp. The problem is Postscript. This is a standalone page definition language and HP-UX provides very minimal support to set options in Postscript. All of this is controlled in the printer's script in the Postscript section. Postscript requires (very wordy) commands to be inserted at the right location to control printer hardware whereas PCL printing (and the PJL language that controls HP printer hardware) is much simpler to adjust. Note also that all HP printers are NOT the same and are NOT guaranteed to produce the same results. The reality is that newer printers are becoming less compatible with older models.
There is only one location that can modify the code generated from Oracle and that is the model.orig script for the printer. You'll need to look at the Postscript section of the script to see what actually works (most -o options will not work as there is not equivalent way to modify Postscript code). You can certainly modify the script -- I would suggest getting a Postscript level 1 or level 3 manual and customize the printer script.
Bill Hassell, sysadmin
There is only one location that can modify the code generated from Oracle and that is the model.orig script for the printer. You'll need to look at the Postscript section of the script to see what actually works (most -o options will not work as there is not equivalent way to modify Postscript code). You can certainly modify the script -- I would suggest getting a Postscript level 1 or level 3 manual and customize the printer script.
Bill Hassell, sysadmin
The opinions expressed above are the personal opinions of the authors, not of Hewlett Packard Enterprise. By using this site, you accept the Terms of Use and Rules of Participation.
News and Events
Support
© Copyright 2024 Hewlett Packard Enterprise Development LP