Solved

Printers - lpstat

Posted on 1997-01-24
1
504 Views
Last Modified: 2013-12-26
I need a small script for AIX that will look at the status of all the spooled printers and if any of them are down it will bring them back up. I imagine this can be done with lpstat and qadm but I am not a programmer so I am not sure how to write the script. If anyone could help me with this I would sure appreaciate it...
0
Comment
Question by:homerb
1 Comment
 
LVL 1

Accepted Solution

by:
marc123096 earned 50 total points
ID: 1292252
The answer is in the question!
lpstat |grep DOWN |grep -v grep |cut -1 |enq -U
that's will lookup wich queue is down and then bring it up
If you want to use qadm instead of "enq" have a look to both man pages
0

Featured Post

Gigs: Get Your Project Delivered by an Expert

Select from freelancers specializing in everything from database administration to programming, who have proven themselves as experts in their field. Hire the best, collaborate easily, pay securely and get projects done right.

Question has a verified solution.

If you are experiencing a similar issue, please ask a related question

Suggested Solutions

Title # Comments Views Activity
method notes when mouse over in eclipse 5 86
Hibernate methods 2 71
wordcount challenge 11 121
Change to event 1 112
Introduction: Load and Save to file, Document-View interaction inside the SDI. Continuing from the second article about sudoku.   Open the project in visual studio. From the class view select CSudokuDoc and double click to open the header …
Have you tried to learn about Unicode, UTF-8, and multibyte text encoding and all the articles are just too "academic" or too technical? This article aims to make the whole topic easy for just about anyone to understand.
This video will show you how to get GIT to work in Eclipse.   It will walk you through how to install the EGit plugin in eclipse and how to checkout an existing repository.
The Email Laundry PDF encryption service allows companies to send confidential encrypted  emails to anybody. The PDF document can also contain attachments that are embedded in the encrypted PDF. The password is randomly generated by The Email Laundr…

776 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