How can I list print queues per server via power shell script

Hello,
we are managing many print servers on our domain environment,  now for auditing purpose I need to report print queues per server,  and it seems bit difficult task doing it via GUI in print management view, could someone help me with script which
gets me the no. of print queues on each print server.
Also I need to list all the print drivers installed on each print servers. 
I tried to list the drivers " Get-WmiObject win32_printerDriver -filter " but this will get me complete information about the driver, I need to list only the driver name (-filter) either _RELPATH or _PATH
dibu

You can also use WMI like this:
(get-WmiObject win32_printer -computer ws702).count
I don't understand what you mean by list only.  Just select what you need.
See: http://technet.microsoft.com/en-us/scriptcenter/dd742419
That will give you some basic background on how to use PowerShell to get the properties of objects.
¯\_(ツ)_/¯

Similar Messages

  • IIS Issue:when trying to download code from AWS S3 and deploy in IIS server using Power Shell script while Windows startup Default Application pool is not started.

    Hi,
    I am trying to launch Amazon EC2 windows server 2008 R2 instance using AWS Auto Scaling feature. I have used cusmized AMI in Autoscaling Launch configuration to launch an instance.I have placed Power Shell script in AMI. 
    The responsibility of script is to download code from AWS S3 and deploy in IIS server while windows startup first time.
    When i check status, IIS is started succesfully. But default Application pool is not started.
    To resolve this issue i have written one scheduled script. It helps to start the application pool if any application pool is in stopped state.
    After this Application pool is started but i am not able to communicate with IIS server through browser.  
    Please help any one to resolve this issue.
    Thanks in advance

    Hi Vchreddy,
    For the IIS issue, we recommend you can post in IIS forum for more effective support:
    http://forums.iis.net/
    Thanks for your understanding.

  • How can i pass parameter values from html to a shell script

    Hi Guys...
    I had a requirement where i need to execute a sql statement and print the output in HTML page. This report has parameters to enter. So i created a HTML form which accepts parameters. When the submit button is pressed, the action tag in the form invokes unix shell script file. It will open sqlplus and run the sql script file .sql and print the output in the HTML page.
    sql script contains the query and some set options which prints the output in HTML page. Like "SET MARKUP HTML ON"... The query has some parameters like "select * from emp where empno = &&empnumber. I will use the same name "empnumber" while created the HTML parameter form like " <input type = "text" name="empnumber" size="10" align="left">.
    user sees this parameter form and enters some value in to that empno text box.
    My question is how can i catch these parameter values in a shell script and pass it to the sql script to execute it.
    Help Appreciated
    Thanx

    This is a A Bad Idea (tm). This type of CGI processing is old and were (and still is) full of security holes. Very easy to inject stuff (Unix commands and SQL) into it.. To get those parameters into SQL*Plus requires using Unix shell commands to process it - and something like a backquote allows all kinds of nasty stuff to be injected. The Unix shell was never designed to be used as a secure CGI environment.
    There are far better and far superior alternatives. Perl (with Perl_DBI) and PHP (using Zend Core for Oracle) come to mind as web scripting languages.
    Even easier is using HTMLDB. Very few moving parts. Is free. Supports Oracle 9.2 and 10G.

  • How can i call a Stored Procedure procedure from Unix shell script

    Hi All,
    I want to call a Strored PL-SQL Procedure through Unix shell script.
    Can any body help me with this.
    Regards,
    Saurabh

    I prefer a seperate script like the other poster mentioned. However, most shells can use a 'here' document as well ...
    sqlplus uid/pwd <<END
    exec myproc
    exit
    ENDRichard

  • How to add Sucessfull AD attribute modificatin output in power shell script

    Import-Csv -Path 'C:\script\Users.csv' | ForEach-Object {
    $HomeDirectory = "\\server\Home$\" + $_.SamAccountName
    Set-ADUser -Identity $_.SamaccountName -homedirectory $HomeDirectory -homedrive H:
    How to add "Write host" if AD user attribute sucessfully modified

    Hi Subramanya Raja,
    Thanks for your posting.
    Please also try this script:
    Import-Csv -Path 'C:\script\Users.csv' | ForEach-Object {
    $HomeDirectory = "\\server\Home$\" + $_.SamAccountName
    Set-ADUser -Identity $_.SamaccountName -homedirectory $HomeDirectory -homedrive H:
    #Determine if command was successful
    if (!$?)#Add failed
    "An error has occurred."}
    Else #Add succeeded
    "set homedirectory to " + $_.SamaccountName + " successfully."}
    For the detailed information about Error checking in PowerShell, please refer to this article:
    http://www.leadfollowmove.com/archives/powershell/error-checking-in-powershell
    I hope this helps.
    We
    are trying to better understand customer views on social support experience, so your participation in this
    interview project would be greatly appreciated if you have time.
    Thanks for helping make community forums a great place.

  • My setup: iMac hardline to Canon i960 printer. Issue: endless printing of the same document. The printer window states that the pinter is in use and there is nothing listed in the Print Queue.  How can I stop printing the document?

    My setup: iMac hardline to Canon i960 printer. Issue: endless printing of the same document. The printer window states that the pinter is in use and there is nothing listed in the Print Queue.  How can I stop printing the document?

    Soution: Delete the printer and add the same printer back in, therefore creating a new print queue.

  • How can I delete printed job list Delete jobs grayed

    How can I delete printed job list Delete jobs grayed

    Apple lets you see a list of what is printed out but there is no way to erase the list and mine is two years of all that printed out. I want to erase it but there is no place to get rid of the list or the items on it. Epson said it was an Apple problem. Apple doesn't seem to know the answer. You can only delete jobs when it is not grayed out and it is usually for those you have not printed . I am hoping someone can figure it out.

  • How can I clean up queue one-time on Sun Java system messaging 6.3

    Hi,
    <address>Our Email server have a problem, When I run _./imsimta qm directory tcp_local_, There are about 5 Millions of messages in the queue.</address>
    Now our Email server send messages very slowly, how can I clean up queue one-time?
    the command _./imsimta qclean_ is very slowly.
    What can I do to prevent this problem?
    our Email server version is :
    Sun Java(tm) System Messaging Server 6.3-6.03 (built Mar 14 2008; 32bit)
    libimta.so 6.3-6.03 (built 17:12:37, Mar 14 2008; 32bit)
    SunOS email-1 5.10 Generic_120011-14 sun4u sparc SUNW,Sun-Fire-V890
    Thank you !

    If you have more than 100,000 messages in the queue, then look at the MAX_MESSAGES parameter in [the job_controller.cnf file|http://wikis.sun.com/display/CommSuite/Job+Controller+Configuration+File]. If the parameter is not specified, it defaults to 100000. If you have more than that number of messages in the channel queues, it will take a long time for new/legitimate messages to be sent because job_controller is only considering the first 100,000 messages in the queue.
    If you get into the "imsimta qm" command do do "sum -database", it will show a summary of what job_controller has in its internal cache and therefore what job_controller is working on. If you compare that to "sum -directory" you will probably see a difference.
    If these are all legitimate messages, you need to increase MAX_MESSAGES, cnbuild, and restart job_controller.
    If they are not, then preventing this in the future will require determining how they got into your queue and correcting that.
    As for removing them, the "imsimta qm" commands allow you to select messages by various criteria and then you can "return" or "delete" them. But yes, that will take a long time if there are many messages because it is a single threaded process and it needs to open and examine each message. You may be able to accomplish the task more quickly with a shell script that works on individual channel queue subdirectories and then run multiple copies of that script in parallel. After you have cleaned out the queue, restart job_controller.
    Also, you might want to consider [the subdirs channel keyword|http://msg.wikidoc.info/index.php/Subdirs_and_nosubdirs_Channel_Options].

  • How can I list all the domains configured for Weblogic Servers?

    How can I list all the domains configured for Weblogic Servers?
    I saw a note, which says the following:
    "WebLogic Server does not support multi-domain interaction using either the Administration Console, the weblogic.Admin utility, or WebLogic Ant tasks. This restriction does not, however, explicitly preclude a user written Java application from accessing multiple domains simultaneously."
    In my case, I just want to list all the domains, is that possible by using any scripts?
    Thanks
    AJ

    If you use WLS Node Manager and the Config Wizard was used to create the domains, then the list of domains should be in a location like this:
    <MIDDLEWARE_HOME>\wlserver_10.3\common\nodemanager\nodemanager.domains
    Enterprise Manager Grid Control also has support for multi-domain management of WLS in a console.

  • HT1893 How can I still print using a 'hp designjet 120nr (C7791B)' with OS X 10.8.3?

    How can I still print using a 'hp designjet 120nr (C7791B)' with OS X 10.8.3? I cannot get the drivers to work?

    bdmorgan wrote:
    Thank you once again Matthew. I understand the importance of being thourough and followed your instruction exactly. I really thought that this would solve it and was ready to click 'This solved my question'. However I still have the same print options as before, no 'A1 on the roll'.
    Although, when I copied:
    'sudo pkgutil --forget org.linuxprinting.foomatic-rip'
    into Terminal it did say somehting along the lines of 'nothing found' (sorry I didnt copy the text). Could this be part of the issue?
    In this case the instructions were incorrect.  I forgot that the uninstaller would run that command.  The reason for that command was to let the system know that foomatic-rip 4.0.6 had been removed.  I am sure that you were able to then install foomatic-rip version 3.43.2.15.  There are two ways to confirm that the older version is now installed.  First, if you can print at all, it is present.  You could also copy and paste the following command in the Terminal.  It should respond with the version that is installed:
    pkgutil --pkg-info org.linuxprinting.foomatic-rip | grep version
    Do I need to change the PPD at all?
    There is no need to change the PPD.  PPDs are reflective of the software (drivers) that are called from the PPD.  You can put anything you want in the PPD.  If that capability is not in the driver, having it in the PPD won't make it work.
    Setting a job to print from A1 Roll Paper is a two step process.  First you select the Paper Size which is A1.
    Then look under the pop up menu below Paper Size for an item called Paper Feed.
    Select Paper Feed.  Then you will be able to select where/how the paper is being fed to the printer.  This is where you can choose Roll Paper (Cut) or Roll Paper (No Cut) among other choices.
    Other drivers may have A1 Roll Paper listed under Paper Size.  Perhaps that is how the HP driver was.  There would still have had to be a place, then to check whether or not you wanted the paper to be cut and/or whether you were feeding sheets of paper from one of the other paths.
    Let us know if you can find all the options now and that you are able to keep your normal workflow.

  • How can we update data in LDAP server using PL/SQL.

    Hi,
    How can we update data in LDAP server using PL/SQL program.
    Is there any sample code for refrence.
    Thanks,
    Tarun

    Hi Justin,
    Thanks for your help. You got my correct requirements.
    Tim's example returning all the attributes of current user which is admin user. Please correct me if I am wrong.
    I have the following information:
    the admin user and password,server info , port and ldap_base for admin.
    I have uid and password for regular user, I am trying find the ldap_base for regular user, which may be different from adminuser.
    Please help me.
    Thanks,
    Edited by: james. on Jan 12, 2009 5:39 PM

  • How can I list the songs in an album in iTunes without having to do it one by one? Some albums are not numbered.

    How can I list the songs in an album in iTunes without having to do it one by one? Some albums are not numbered or they show 1. 1. 1. 1. 1. 1. 1.

    Poor metadata needs to be corrected if the album is to display properly in iTunes. iTunes sees an "album" as any collection of tracks with the same Album title and the same Album Artist (or Artist if Album Artist isn't set). Each track of the album should have distinct Track V of W and Disc X of Y vaules. W,X,Y are optional, but X may be needed for multi disc albums.
    See Gropuing tracks into albums for details.
    tt2

  • Hi,how can i transport objects from one server to other like (Dev To Qty)

    Hi Sir/madam,
       Can u explain how can i transport objects from one server to other like (Development To Quality To Production).
    Regards,
    Vishali.

    Hi Vishali,
    Step 1: Collect all Transports(with Packages) in Transports Tab(RSA1)- CTO
    Step 2: Release the subrequests first and then the main request by pressing Truck button
    Step 3: STMS or Customized transactions
    Object Collection In Transports:
    The respective Transports should have the following objects:
    1. Base Objects -
    a. Info Area
    b. Info object catalogs
    c. Info Objects
    2. Info Providers u2013
    a. Info Cubes
    b. Multi Providers
    c. Info Sets
    d. Data Store Objects
    e. Info Cube Aggregates
    3. Transfer Rules u2013
    a. Application Components
    b. Communication Structure
    c. Data Source replica
    d. Info Packages
    e. Transfer Rules
    f. Transformations
    g. Info Source Transaction data
    h. Transfer Structure
    i. Data sources (Active version)
    j. Routines & BW Formulas used in the Transfer routines
    k. Extract Structures
    l. (Note) If the transfer structures and related objects are being transferred without preceding
    Base Objects transport (e.g. while fixing an error) it is safer to transport the related Info
    Objects as well.
    4. Update Rules u2013
    a. Update rules
    b. Routines and formulas used in Update rules
    c. DTPs
    5. Process Chains u2013
    a. Process Chains
    b. Process Chain Starter
    c. Process Variants
    d. Event u2013 Administration Chains
    6. Report Objects u2013
    a. Reports
    b. Report Objects
    c. Web Templates
    Regards,
    Suman

  • How can I connect to a windows server from a mac book pro

    How can I connect to a windows server from a mac book pre?

    I have a Dell Power Edge T110 ii in the office that has files and software I need to access when away from the office, when I am on the road I use a mac book pro and an iPad.
    I am sorry if I am being a bit vague but this is all new to me, I have tried 3 IT guys but they can not find a way.
    Any help is greatly appeciated.

  • How can I find out the mail server from email address?

    Hi:
    How can I find out the mail server from email address?
    for example: If I know the email address is [email protected],
    how to find the pop3 and smtp mail server?
    THANK YOU

    You can't tell by the email address since you can pretty much put whatever you want in there (especially if the SMTP server is not filtering anything).
    The header may be able to tell you something. There is a Received header value which looks like it has the routing information although I am not sure if this is a complete trace or just the last hop the message took.
    Sean

Maybe you are looking for

  • CS2- Adobe Updater won't start

    I have Photoshop CS2 and have recently started to use it after a long hiatus.  When I start it, I get a message that Adobe Updater would not start, and something (the updater?) should be reinstalled.  CS2 seems to be working perfectly.  What should I

  • How do I set this up.. a background image in a flash drive as its opened

    Hi.. For a birthday present I want to give my friend 2 tracks and a folder.. I want the background to be an image and the 2 files and the one folder to line up as shown in the pic attached.. I have managed to make the flashdrive be an custom icon and

  • Table name for the desc for marine pollutant HISubsMP in dangerous goods

    Hi All, I want the table name where the description of the marine pollutant gets stored in hazrd inducer substance. HISubsMP   CUST-100000000000262    (CONTAINS MARINE POLLUTANT) I want to fetch the 3rd descrition. in which table it is stored.? Thank

  • How to handle producer not registered/down using Interceptor in wsrp

    Hi , I have to handle a Scenario in wsrp where if producer is down or not responding then i have to show a error message on consumer .For that i want to use a Interceptor . can you provide me some step for proceeding. thanks in advance

  • How to add buttons to a standart program

    Hi experts, It is easy to add a button in a call screen. But i want to add a button in a standart program which doesnt call a screen. For example an alv report. But i want the button near the exit, back buttons. not in the alv. I searched standart pr