- Community Home
- >
- Servers and Operating Systems
- >
- Operating Systems
- >
- Operating System - HP-UX
- >
- cancel lp requests as non root
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
10-15-2001 09:38 AM
10-15-2001 09:38 AM
I have a script that checks for print requests and prompts for the deletion of the job and then is supposed to delete the print job, but it is not working.
here is my script:
echo "Cancel print jobs"
echo "here are the print jobs, please pick one!"
lpstat -o
echo "Enter job name and number exactly as listed above that you want to canc
el"
read $lpans
echo "About to remove print request" $lpans
echo ""
echo "if you are positive that you want to delete this print, please enter Y"
read $lpans1
if $lpans1 = "Y"
then
cancel $lpans
else
echo " pausing 5 "
sleep 5
fi
Suggestions appreciated.
Solved! Go to Solution.
- Mark as New
- Bookmark
- Subscribe
- Mute
- Subscribe to RSS Feed
- Permalink
- Report Inappropriate Content
10-15-2001 09:43 AM
10-15-2001 09:43 AM
Re: cancel lp requests as non root
Since you indicate that you are not 'root' you must have constructed the print queue to allow 'cancel' by anyone if you want a user, other than the owner/initiator to be able to cancel.
Regards!
...JRF...
- Mark as New
- Bookmark
- Subscribe
- Mute
- Subscribe to RSS Feed
- Permalink
- Report Inappropriate Content
10-15-2001 09:46 AM
10-15-2001 09:46 AM
Re: cancel lp requests as non root
Yes, as non root. I can cancel the print as myself, nickd but I want to do it through a script so that my co-workers can take care of the mundane unix stuff like cancelling print req's that go astray.
That is why I attached my script.
thanks,
- Mark as New
- Bookmark
- Subscribe
- Mute
- Subscribe to RSS Feed
- Permalink
- Report Inappropriate Content
10-15-2001 09:46 AM
- Mark as New
- Bookmark
- Subscribe
- Mute
- Subscribe to RSS Feed
- Permalink
- Report Inappropriate Content
10-15-2001 09:52 AM
10-15-2001 09:52 AM
Re: cancel lp requests as non root
If you are not root then you have to setup lpqueue as that other user can cancel jobs.
If you have use option -orc in lanadmin while setup only user can cancel his/her own request. Default is not to restrict cancel command.
Sachin
- Mark as New
- Bookmark
- Subscribe
- Mute
- Subscribe to RSS Feed
- Permalink
- Report Inappropriate Content
10-15-2001 09:56 AM
10-15-2001 09:56 AM
Re: cancel lp requests as non root
Thanks to all who replied.
call closed.
- Mark as New
- Bookmark
- Subscribe
- Mute
- Subscribe to RSS Feed
- Permalink
- Report Inappropriate Content
10-16-2001 09:11 AM
10-16-2001 09:11 AM
Re: cancel lp requests as non root
echo "Enter printer name"
read lpname
echo "Cancel print jobs"
echo "here are the print jobs, please pick one!"
lpstat $lpname
echo "Enter job name and number exactly as listed above that you want to canc
el"
read lpans
echo "About to remove print request" $lpans
echo ""
echo "if you are positive that you want to delete this print, please enter y"
read lpans1
if [ $lpans1 = "y" ]
then
cancel $lpans
else
echo " pausing 5 "
sleep 5
fi