- Community Home
- >
- Servers and Operating Systems
- >
- Operating Systems
- >
- Operating System - HP-UX
- >
- Forcing an end-of-job formfeed using lp
Categories
Company
Local Language
Forums
Discussions
Forums
- Data Protection and Retention
- Entry Storage Systems
- Legacy
- Midrange and Enterprise Storage
- Storage Networking
- HPE Nimble Storage
Discussions
Forums
Discussions
Discussions
Discussions
Forums
Discussions
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
Discussion Boards
Community
Resources
Forums
Blogs
- 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
02-25-2004 03:56 AM
02-25-2004 03:56 AM
Forcing an end-of-job formfeed using lp
- Mark as New
- Bookmark
- Subscribe
- Mute
- Subscribe to RSS Feed
- Permalink
- Report Inappropriate Content
02-25-2004 04:06 AM
02-25-2004 04:06 AM
Re: Forcing an end-of-job formfeed using lp
Depends on how the printer is defined to the system.
If it's a local or network printer then you can edit the interface file to insert a FF (Dec 12 / hex C / octal 014) after the job is sent.
Look at the /usr/lib/model/dumb file it has it in the
# Print the spooled files
section.
If it's a remote printer, then you'll have to imbed the /014 into the end of the file.
Rgds,
Jeff
- Mark as New
- Bookmark
- Subscribe
- Mute
- Subscribe to RSS Feed
- Permalink
- Report Inappropriate Content
02-25-2004 04:20 AM
02-25-2004 04:20 AM
Re: Forcing an end-of-job formfeed using lp
- Mark as New
- Bookmark
- Subscribe
- Mute
- Subscribe to RSS Feed
- Permalink
- Report Inappropriate Content
02-25-2004 06:13 AM
02-25-2004 06:13 AM
Re: Forcing an end-of-job formfeed using lp
I'll assume that your printer is called "Oki" on the local host. We need to modify /var/spool/lp/interface/Oki and make a few changes. We are also armed with the knowledge that Oki's requests are stored in
/var/spool/lp/request/Oki as "d*RequestNumberLocalHostName"
cd to /var/spool/lp/interface
cp Oki Oki.sav
modify Oki and make these changes just before the rlp command:
DIRNAME=/var/spool/lp/request/${printer}
REQNO=$(echo "${requestid}" | awk -F'-' '{print $NF}')
FNAME=${ls ${DIRNAME}/d*${REQNO}[A-Za-z_]*)
if [[ -f "${FNAME}" ]]
then
chmod 640 ${FNAME}
echo "\f\c" >> ${FNAME}
chmod 440 ${FNAME}
fi
usr/sbin/rlp -I$requestid ....
That should do the trick. Note that we have to briefly write-enable the file before the echo; we then return it to read-only before handing it off to rlp. I do assume that your host name starts with A-Z,a-z, or "_".
- Mark as New
- Bookmark
- Subscribe
- Mute
- Subscribe to RSS Feed
- Permalink
- Report Inappropriate Content
02-25-2004 06:51 AM
02-25-2004 06:51 AM