NETWORK PRINTER INVENTORY IN SYSTEM CENTRE CONFIGURATION MANAGER (SCCM 2012).
SCCM HW inventory agent runs as the ‘SYSTEM’ and cannot see the end-users network drives and printers. The following two step process will help circumvent the above stated limitation.
1) CREATE HKEY_LOCAL_MACHINE\SOFTWARE\SCCMINVENTORY\NETWORKPRINTERS PATH IN THE REGISTRY.
Create a SCCM package.
The package should run as administrator.
The package should run whether or not a user is logged on.
POWERSHELL PACKAGE 1 (Prerequisite):
if (!(Test-Path HKLM:\SOFTWARE\SCCMINVENTORY)) {new-item HKLM:\SOFTWARE\SCCMINVENTORY -ErrorAction SilentlyContinue}
$perm = get-acl HKLM:\SOFTWARE\SCCMINVENTORY -ErrorAction SilentlyContinue
$rule = New-Object System.Security.AccessControl.RegistryAccessRule("Authenticated Users","FullControl", "ContainerInherit, ObjectInherit", "InheritOnly", "Allow") -ErrorAction SilentlyContinue
$perm.SetAccessRule($rule)
Set-Acl -Path HKLM:\SOFTWARE\SCCMINVENTORY $perm -ErrorAction SilentlyContinue
if (!(Test-Path HKLM:\SOFTWARE\SCCMINVENTORY\NETWORKPRINTERS)) {new-item HKLM:\SOFTWARE\SCCMINVENTORY\NETWORKPRINTERS -ErrorAction SilentlyContinue}
SAVE POWERSHELL FILE AS: PrinterInvRegSetup.ps1
SETUP THE SCCM PACKAGE/PROGRAM WITH COMMAND LINE:
%SYSTEMROOT%\System32\WindowsPowerShell\v1.0\PowerShell.exe -NonInteractive -WindowStyle Hidden -noprofile -ExecutionPolicy Bypass -file .\PrinterInvRegSetup.ps1
2) CAPTURE CURRENT USER’S PRINTERS AND WRITE THOSE ENTRIES TO THE ABOVE CREATED REGISTRY KEYS.
Create a SCCM package
The package should be run only when a user is logged in.
POWERSHELL PACKAGE 2 (Main):
$printers = Get-WMIObject -class Win32_Printer -ErrorAction SilentlyContinue|select-Object -Property ServerName,ShareName,Location,DriverName,PrintProcessor,PortName,Local |Where-Object {$_.Local -ne $true}-ErrorAction SilentlyContinue
ForEach($printer in $printers){
$PServerName= $printer.ServerName -replace ('\\','')
$PShareName = $printer.ShareName
$PLocation = $printer.Location
$PDriverName = $printer.DriverName
$PPrintProcessor = $printer.PrintProcessor
$PPortName = $printer.PortName
if ((Test-Path HKLM:\SOFTWARE\SCCMINVENTORY\NETWORKPRINTERS)) {
if ((Test-Path "HKLM:\SOFTWARE\SCCMINVENTORY\NETWORKPRINTERS\$PShareName on $PServerName")) {
Remove-item "HKLM:\SOFTWARE\SCCMINVENTORY\NETWORKPRINTERS\$PShareName on $PServerName" -Force -ErrorAction SilentlyContinue
New-item "HKLM:\SOFTWARE\SCCMINVENTORY\NETWORKPRINTERS\$PShareName on $PServerName" -ErrorAction SilentlyContinue
New-ItemProperty "HKLM:\SOFTWARE\SCCMINVENTORY\NETWORKPRINTERS\$PShareName on $PServerName" -Name "PrintServer" -Value $PServerName -PropertyType "String" -ErrorAction SilentlyContinue
New-ItemProperty "HKLM:\SOFTWARE\SCCMINVENTORY\NETWORKPRINTERS\$PShareName on $PServerName" -Name "PrinterQueue" -Value $PShareName -PropertyType "String" -ErrorAction SilentlyContinue
New-ItemProperty "HKLM:\SOFTWARE\SCCMINVENTORY\NETWORKPRINTERS\$PShareName on $PServerName" -Name "PrinterLocation" -Value $PLocation -PropertyType "String" -ErrorAction SilentlyContinue
New-ItemProperty "HKLM:\SOFTWARE\SCCMINVENTORY\NETWORKPRINTERS\$PShareName on $PServerName" -Name "PrinterDriver" -Value $PDriverName -PropertyType "String" -ErrorAction SilentlyContinue
New-ItemProperty "HKLM:\SOFTWARE\SCCMINVENTORY\NETWORKPRINTERS\$PShareName on $PServerName" -Name "PrintProcessor" -Value $PPrintProcessor -PropertyType "String" -ErrorAction SilentlyContinue
New-ItemProperty "HKLM:\SOFTWARE\SCCMINVENTORY\NETWORKPRINTERS\$PShareName on $PServerName" -Name "PrinterPortName" -Value $PPortName -PropertyType "String" -ErrorAction SilentlyContinue
New-ItemProperty "HKLM:\SOFTWARE\SCCMINVENTORY\NETWORKPRINTERS\$PShareName on $PServerName" -Name "DateInventoried" -Value $(get-date) -PropertyType "String" -ErrorAction SilentlyContinue
SAVE POWERSHELL FILE AS: NetworkPrinterInventory.ps1
SETUP THE SCCM PACKAGE/PROGRAM WITH COMMAND LINE:
%SYSTEMROOT%\System32\WindowsPowerShell\v1.0\PowerShell.exe -NonInteractive -WindowStyle Hidden -noprofile -ExecutionPolicy Bypass -file .\NetworkPrinterInventory.ps1
3) CREATE A DEPLOYMENT AND SET IT TO ‘RUN ALWAYS’ AND MAKE IT A REQUIREMENT.
Now deploy the second package and set the first package as a prerequisite (Check the box – Always run the prerequisite package)
The deployment should be set to run every 4 hours and ‘Always rerun’. Mark the deployment as required.
4) ADD THE FOLLOWING IN BETWEEN THE EXTENSION SECTION WITHIN YOUR CONFIGURATION.MOF.
//========================
// Added extensions Start
//========================
#pragma namespace ("\\\\.\\root\\cimv2")
#pragma deleteclass("NETWORKPRINTERS", NOFAIL)
[dynamic, provider("RegProv"), ClassContext("Local|HKEY_LOCAL_MACHINE\\SOFTWARE\\SCCMINVENTORY\\NETWORKPRINTERS")]
Class NETWORKPRINTERS
[key] string KeyName;
[PropertyContext("PrintServer")] String PrintServer;
[PropertyContext("PrinterQueue")] String PrinterQueue;
[PropertyContext("PrinterLocation")] String PrinterLocation;
[PropertyContext("PrinterDriver")] String PrinterDriver;
[PropertyContext("PrintProcessor")] String PrintProcessor;
[PropertyContext("PrinterPortName")] String PrinterPortName;
[PropertyContext("DateInventoried")] String DateInventoried;
//========================
// Added extensions end
//========================
5) SAVE THE BELOW DATA INTO A FILE CALLED ‘AWESOME.MOF’.
#pragma namespace (“\\\\.\\root\\cimv2\\SMS”)
#pragma deleteclass(“NETWORKPRINTERS”, NOFAIL)
[SMS_Report(TRUE),SMS_Group_Name("NETWORKPRINTERS"),SMS_Class_ID("NETWORKPRINTERS")]
Class NETWORKPRINTERS: SMS_Class_Template
[SMS_Report(TRUE),key] string KeyName;
[SMS_Report(TRUE)] String PrintServer;
[SMS_Report(TRUE)] String PrinterQueue;
[SMS_Report(TRUE)] String PrinterLocation;
[SMS_Report(TRUE)] String PrinterDriver;
[SMS_Report(TRUE)] String PrintProcessor;
[SMS_Report(TRUE)] String PrinterPortName;
[SMS_Report(TRUE)] String DateInventoried;
6) IMPORT ‘AWESOME.MOF’ INTO SCCM DEFAULT CLIENT SETTINGS.
Either import the above MOF file into the Client Setting/Default Client Settings/Hardware Inventory/Classes/Import. Select the option to import every thing.
Alternatively, if you have compiled the MOF manually on the PC, Add a new reporting class by clicking the ‘Add’ button and connecting to the PC and selecting the WMI class ‘NETWORKPRINTERS‘
and that is it. The SCCM resource explorer should soon see the Network Printers.
Now, this is a convoluted process but this is the only way I can inventory Network printers. Any ideas or suggestions?
All the other ways are similar because this is a per-user setting.
http://blogs.technet.com/b/breben/archive/2013/08/26/inventory-mapped-drives-in-configmgr-2012.aspx
Juke Chou
TechNet Community Support
Similar Messages
-
SQL Server 2012 deployment with System Center Configuration Manager (SCCM) 2012
hi,
we have tried to deploy the SQL Server 2012 to our development machines with SCCM 2012 without success.
Commandline parameters or Configuration.ini in either case the installation failed without any useful errorlog.
Exists any howto which covers this scenario?
regards
genneHello,
Please see the following article about some requirements for SQL Server instances intended for SCCM 2012:
http://www.sqlcoffee.com/Tips0019.htm
Could please check to see if a Summary.txt log file exists after those installation attempts? The following article may help you locate the file on disk:
http://technet.microsoft.com/en-us/library/ms143702(v=sql.110)
Please share this log file with us, if possible.
Hope this helps.
Regards,
Alberto Morillo
SQLCoffee.com -
How System Centre can manage Azure ?
Hi
How System Centre can manage Azure in better way?
Is there any better tool available in market, which can manage Azure.. ?
Thanks, Kkonly two possibilities i see here
make these VM part of your network so they are visible to the System center, this can be done by creating a vpn or use system center that allow you to manage cloud VMs without having them in vpn, which i believe is called "System
Center Management Pack for Windows Azure"
The System Center Management Pack for Windows Azure enables you to monitor the availability and performance of resources that are running on Windows Azure. The management pack runs on a specified resource pool and then uses various Windows Azure APIs to remotely
discover and collect instrumentation information about a specified Windows Azure resource, such as a Cloud Service, Storage or Virtual Machine. The Management Pack for Windows Azure provides no functionality on import. For each Windows Azure subscription that
contains Azure resources you want to monitor, you must configure discovery and monitoring by first using the Windows Azure wizard in the administration section of the OM Console, then the Windows Azure Monitoring template in the authoring section of the OM
Console.
you can download it from
here
Hope this helps
Please mark as answered if it helped
Vishal Narayan Saxena http://twitter.com/vishalishere http://www.ogleogle.com/vishal/ -
Deploying Office 365 Pro Plus using System Center Configuration Manager 2012 SP1
Hello,
I am trying to deploy Office 365 Pro Plus to my client machines (more than 100) via. System Center Configuration Manager 2012 SP1. It will use one administrator account for installation. But as per the licensing, we can install Office for up to 5 PCs/Macs
and 5 more Windows tablets/iPads with one Office 365 Pro Plus licenses. If this is the case, then I cannot install Office 365 Pro Plus with one admin account to my 100+ machines, as it will violate the licenses of O365 Pro Plus.
So, what is the alternative approach?
Thanks
RajIf this is the case, then I cannot install Office 365 Pro Plus with one admin account to my 100+ machines, as it will violate the licenses of O365 Pro Plus.
Hi,
this is incorrect.
There is no licensing restriction/control for the *installation* account at all, the licensing is related to who is *using* Office365ProPlus *after* installation is performed. This control, is implemented by the Microsoft Account, or OrgID, used to sign-in/activate
to Office365 when *using* Office365ProPlus.
Don
(Please take a moment to "Vote as Helpful" and/or "Mark as Answer", where applicable.
This helps the community, keeps the forums tidy, and recognises useful contributions. Thanks!) -
System centre operation manager 2012 exam paper code
Hi,
Can anyone please let me know what is the System centre operation manager 2012 exam paper code?
Regards,Hi,
What do you mean by Exam paper code?
If you are looking for SCOM learning resource, you may refer to the links below:
https://technet.microsoft.com/en-us/library/hh205987.aspx
http://blogs.technet.com/b/musings_of_a_technical_tam/archive/2012/06/19/system-center-2012-self-study-guides-part-5-operations-manager.aspx
Regards,
Yan Li
Please remember to mark the replies as answers if they help and unmark them if they provide no help. If you have feedback for TechNet Subscriber Support, contact [email protected] -
Cisco IPT and Microsoft System Centre Operations Manager
Hi All
Does anybody used Cisco IPT with System Centre Operations Manager?
Does System Centre Operations Manager supports Cisco CallManager OS and Hardware for monitoring?
Thanks
VKSHi David,
Thanks for your reply. I have gone through the links which you have mentioned. As per the Overview of Operations Manager 2007 R2 section in What's New & Improved in Operations Manager 2007 R2 document it is clearly mentioned the below points:
Delivers monitoring across Windows, Linux and Unix servers–all through a single console.
Extend end to end monitoring of distributed applications to any workload running on Windows, Unix and Linux platforms.
The Cisco Servers are also Windows and Linux Based.
Thanks & Regards,
Vaijanath -
VHD for System Center Configuration Manager 2012 R2
I just downloaded of TechNet the VHD of System Center Configuration Manager 2012 R2. However when you bring it online it is in the domain Conteso. I have searched all over TechNet and the web, but there is no record of the admin password nor is there
any documented instructions with the download.
http://www.microsoft.com/en-us/download/details.aspx?id=40840
Best regards,
Dave Clauson
Partner Online Technical Community
We hope you get value from our new forums platform! Tell us what you think:
http://social.microsoft.com/Forums/en-US/partnerfdbk/threads
This posting is provided "AS IS" with no warranties, and confers no rightsHi,
I think you should find the password for Windows Server 2012 R2. Please try
R2Preview!
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. -
Microsoft System Center Configuration Manager 2012 R2 Reports
Hi ;
I can't run any reports on microsoft system center configuration manager 2012 R2. I see " No items found " when i click reports on microsoft System Center Configuration manager 2012 Console.But i access all reports by internet Explorer. End of
all , i don't have any problem with queries.I am waiting for your helps.
Sincerely yours ,Hi,
It sounds like this should be the solution for you, changing the account for the SRS service.
http://blog.coretech.dk/rja/no-srs-reports-showing-up-in-sccm-console/
Regards,
Jörgen
-- My System Center blog ccmexec.com -- Twitter
@ccmexec -
System center configuration manager book
Any good books on system center configuration manager.
How about this book from amazon.
http://www.amazon.com/System-Center-Configuration-Manager-Unleashed/dp/0672337150/ref=sr_1_3?s=books&ie=UTF8&qid=1410477862&sr=1-3&keywords=system+center+configuration+manager+2012+r2
any help or suggestions are appreciated.
ThanksHi,
Please refer to the link below:
http://social.technet.microsoft.com/Search/en-US/Technet?query=SCCM%20BOOK&beta=0&ac=4
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. -
Workgroup Client Installation & configuration in SCCM 2012
Hi,
i have an internal domain named ECC-OCT.local which has internal IP 10.0.8.45 and SCCM server IP 10.0.8.47.
i have been installed SCCM Client Agent on a workgroup server manually but the site code not approved
(why ?).
Keep in mind that the DNS for the workgroup server was my public DNS Server which configured to hold secondary zone
for internal domain ECC-OCT.local.
If i assigned the 3rd dns server (on network card configuration) to ip 10.0.8.45 , the site code retrieved successfully.
what can i do to solve this issue?Hi,
Based on your description, I recommend you check the MP record in DNS:
The SRV record must has been registered in DNS.
SRV record is published in DNS
Also, you can edit the LMHOSTS and HOSTS files on each client for the site code retrieve.
Managing System Center Configuration Manager clients in a workgroup
http://blogs.technet.com/b/configurationmgr/archive/2010/03/01/managing-system-center-configuration-manager-clients-in-a-workgroup.aspx
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. -
I have an HPLJ 1102W and I want to use it as a wired printer on my LAN. The trouble is, the easy setup utility is geared toward wireless networking and the ethernet interface will not get a DHCP address from the LAN. In order to get an IP address, I have to go through the wireless networking configuration settings. Can anyone point me in the right direction on how to use this printer as a wired network printer?
thanks,Hi,
The HP LaserJet P1102w provide USB or wireless network interface only.
the product do not include any ethernet card, as you may also find by its spesification System Requirements below:
http://h10025.www1.hp.com/ewfrf/wc/document?docname=c01999607&tmp_task=prodinfoCategory&cc=us&dlc=en...
Connectivity: Hi-Speed 2.0 USB port / Wireless 802.11 B/G (P1102w only)
Regards,
Shlomi
Say thanks by clicking the Kudos thumb up in the post.
If my post resolve your problem please mark it as an Accepted Solution -
How to install System Centre Service Manager Console on any PC
Hi, I'm new to the forum, and am trying to get SCSM installed into the organisation for Servicedesk purposes.
According to several pieces of documentation, I should be able to "manually install the Service Manager console as a stand-alone piece on a computer". However, I am unable to find any documentation or instructions on how to install a fat console on a PC.
Can someone help me with the instructions.
I understand that future versions could well include an Analyst Webportal, which hopefully will mature the Analyst environment significantly (currently with CR support on portal only, and having to use console is far from ideal.)We had created a SCCM package to deploy SCSM 2010 SP1 console to user's PC. I also found someone post the following URL for SCSM 2012:
Service Manager Console Installation via Configuration Manager
http://blogs.technet.com/b/servicemanager/archive/2012/04/05/service-manager-console-installation-via-configuration-manager.aspx -
Why SQL services is dont start in configuration manager studio 2012
I finished installing SQL server Management Studio 2012 and that of configuration management studio.
When I wanted to log in did not find server name, and I tried <pc name>\SQLEXpress, still did not work.
So checked configuration management studio and I noticed that usually we see arrow type button (like "play " button) on the picture of CPU beside word- SQL server services on configuration management studio, was not seen.
is it the reason why it SSMS don't find Server name?
I freshly install SSMS, did I miss to install something?
Please help... ThanksAlso, did you install Express edition, if so, Express edition does not have sql Server agent service but you will see that in the configuration manager with Stop button kind of thing and you cannot start that,o do not worry about it
A more appropriate description would be
Express edition has SQL Server agent code inbuilt but is disabled by edition restriction. It is there because when you upgrade SQL Express to Enterprise or Standard Upgrade just need to enable that code to bring Agent services it saves itself from hassle
of writing a code for agent.
Please mark this reply as answer if it solved your issue or vote as helpful if it helped so that other forum members can benefit from it.
My TechNet Wiki Articles -
Support for Internet based client Management - SCCM 2012
Hi There,
My Company wants to go for Internet based client Management in SCCM 2012 SP1 R2 and here is the design I'm proposing. I'm getting a bit confused at one point and need suggestion....
Everything would work on HTTPS ( PKI Certificate based )... LAN and Internet.
1 Primary ( with non-client facing roles installed ) on LAN with two site systems.
- One Site System configured for INTRANET support only with MP, DP and SUP -> To support LAN users ( Allow
Intranet-only connections )
- One Site System configured for INTERNET support only with MP, DP and SUP -> To support Internet users ( Allow
Internet-only connections )
The INTERNET facing site system is in DMZ network connected to parent Primary via Firewall.
We want internet clients to talk to ONLY DMZ SCCM Site System and no connection to corporate LAN. We cannot open any ports for internet based clients to LAN.
If this is the supported scenario, then why we need to put the Internet FQDN in the Primary server Site System property. This server would not be available to internet. It should only be my DMZ SCCM server client should connect for MP, DP and SUP and only
this DMZ server should be accessible to client over internet.
Also, what least ports should be opened between :
- Parent Primary and its internet facing site system kept in DMZ
- DMZ Site system and internet clients.
Thanks in advance for your suggestions.
SamThe FQDN has only to be specified on the Internet facing site system. You can leave this field blank on the primary site Server.
Ports to Open:
Internet --> DMZ Site Server:
TCP Port 443
TCP Port 80, if Fallback Status Point is installed
DMZ Site Server --> Primary Site:
TCP 135, 49152-65535
TCP 445
TCP 135, 24158 (fixed with
http://msdn.microsoft.com/en-us/library/bb219447(v=vs.85).aspx )
TCP 80, 443
If you have some other roles installed, please consult this page:
http://technet.microsoft.com/en-us/library/hh427328.aspx
Cheers,
Thomas Kurth
Netree AG, System Engineer
Blog:
http://netecm.netree.ch/blog | Twitter:
| LinkedIn:
| Xing:
Note: Posts are provided “AS IS” without warranty of any kind, either expressed or implied, including but not limited to the implied warranties of merchantability and/or fitness for a particular purpose. -
Manage SCCM 2012 clients in DMZ (OS Deploy, Windows updates) via DP/MP
Hi,
We ’d like to manage (=OS Deploy, Packages,Windows updates) Windows clients (Windows 2008/2012 R2 servers for now, about 20 of them) in a DMZ (= different domain).
There is this article
https://nikifoster.wordpress.com/2011/01/31/installing-configmgr-clients-on-servers-in-a-dmz/ which explains what to do … in 2011. Since then lots of things are changed I guess
Before I dive in, I’d need to have an overview + do some administrative tasks (like asking for firewall accesses).
Current setup DMZ:
Our SCCM 2012 R2 server is on a Windows 2008 R2 OS
Client communication is done via HTTP (not HTTPS)
An extra physical Distribution point is setup (only DP, nothing more) in our current domain
A new Windows 2012 server is setup in the DMZ which should host the DP and probably management point (since it should manage the clients over there)
There are clients in DMZ that are currenlty managed by SCCM 2007 but
this server will be phased out, these client have:
Correct sccm functionality
Correct DNS resolution
My steps/questions, please comment:
Add the DMZ ip range to SCCM 2012 boundary as “DMZ”
Add the network access account to be able to deploy as well clients as distribution point in DMZ
In the DMZ accesses on firewall for server VLAN have to be asked
When we have a distribution point and communication is “HTTP only” then http (port 80) from DMZ to sccm server should suffice, correct? Or are
extra firewall openings needed for management point access/packages and windows updates sync?
Now the sccm clients will be deployed to the servers in DMZ: deploy SCCM clients to hosts in DMZ, how this should be done: we connect a console to the SCCM-server in the DMZ then deploy the discovered clients?
OS Deploy should be made available, but no dhcp is available in DMZ and it is not an option either, therefore we would boot from an ISO then enter an ip (or pre-enter it so there is already filled in an ip?). So tasksequences/deployments
for servers in DMZ, where are they configured/deployed then? Via console access on DMZ management point or can we deploy on our domain SCCM management point (not in DMZ) and it will be synced to the DMZ management point? Not clear
Selective sync of software to this distribution point (howto? not sure), we don’t need any Windows 8 software/drivers to be synced.
Thanks for your input!
J.
Jan HoedtNo comment;
I think you mean the client push installation account and the site system installation account;
More ports are required, see site server > distribution point and distribution point > management point from the provided link;
The console will always be connected to your primary site server. The client will be pushed from the primary site server and it will provide the initial files. The other files will be downloaded from the local distribution point;
The task sequence deployment will be just like a normal taks sequence deployment. The only difference is the location of the server;
Only the content that's distributed to the distribution point in the DMZ will be available on that distribution point.
My Blog: http://www.petervanderwoude.nl/
Follow me on twitter: pvanderwoude
Maybe you are looking for
-
Photoshop cs3 quits unexpectedly
photoshop cs3 is quitting when i open images. if the images are over 500MB and i don't wait for the preview to open before opening it crashes immiadiatly. if i wait it doesn't crash straight away, but after opening two or three images it crashes. i
-
Getting the expression used in the procedure(query)
I am workng with MS Access 2000. I have procedure(query) by the name BILL, created on a table Order Details as: SELECT [UnitPrice], [Quantity], [UnitPrice]*[Quantity] AS BillValue FROM [Order Details]; The dbmd.getColumns(null, null, "BILL", "%") giv
-
ICR field assignment process 003 debits/credits indicator
Hello experts, I'm currently implementing ICR processes 001 - 003 for a client. For process 002, I defined a special field assignment using the SL-funtionality. For process 003 no field assignment has to be configured, nevertheless I'm missing the va
-
Hi, I need to do the following: Using the general structure interface, display the u2018implementationu2019 structure (object type u201899u2019 and evaluation path u2018BZ99u2019) from root object u201800-XYZ Implementationsu2019. But I do not have t
-
Vender master default settings in SPRO ?
Hello, Where can we configure the vender master default values in SPRO please tell me the path. regards rk