Tag Info

Hot answers tagged

29

Short answer: NO, unless you really need it and you really know what you are doing. WMF 3.0 is known to be not compatible at all with Exchange Server (both 2007 and 2010), at least until further updates are released for these products; also, although this is not yet officially documented, it has been found to wreak havoc on SharePoint 2010, and to break ...


16

In PowerShell: Get-WMIObject Win32_OptionalFeature | where Name -eq 'Server-Gui-Shell' | Select InstallState returns 1 on a full server and 2 on a server core install. Edit: While my answer above is correct, there are two problems with it: When using this command on a workstation, it returns nothing, so you have to add an extra check for this. It is ...


11

The following works on Window 2003 R2 SP 2, Windows Server 2012 R2 Add the user(s) in question to the Performance Monitor Users group Under Services and Applications, bring up the properties dialog of WMI Control (or run wmimgmt.msc). In the Security tab, highlight Root/CIMV2, click Security; add Performance Monitor Users and enable the options : Enable ...


10

No, I just got bit by this over the weekend in the middle of Exchange 2010 updates. Using the tips at this blog, I uninstalled the package in order to bring my Exchange environment back online. It seems fairly clear that this isn't really an applicable update to most environments.


9

Get-WmiObject -Query "Select OperatingSystemSKU from Win32_OperatingSystem" You'll need to convert the response to Hex to compare: 0C Datacenter (core installation) 27 Server Datacenter without Hyper-V (core installation) 0E Server Enterprise (core installation) 29 Server Enterprise without Hyper-V (core installation) 2A Microsoft Hyper-V Server 0D ...


8

Man, I can hardly imagine how many things in your environment must be broken if remote WMI can't be used, even from domain controllers, SCCM servers, etc. Sounds painful. But anyway, According to this article: http://technet.microsoft.com/en-us/library/cc782152(v=WS.10).aspx No it doesn't rely on WMI. As long as the Group Policy client can access Sysvol, ...


7

The data is in the SAM but it doesn't appear to be publicly documented by Microsoft and I'm not finding an official API to retrieve it. I can see, looking at the source code for the chntpw utility that the value is stored in the "F" registry key for each account. Quoth the source code: #define USER_F_PATH "\\SAM\\Domains\\Account\\Users\\%08X\\F" struct ...


7

I believe WMI service is enabled on most Windows Servers (as well as Desktops) by default. http://blogs.technet.com/b/josebda/archive/2007/08/08/comparing-default-services-on-windows-server-2003-r2-and-windows-server-2008-core-and-full.aspx However, you may need to configure your default Windows Firewall rules to allow this service to be queried remotely ...


6

WMIDiag is a good place to start. WMI Diagnosis Utility http://technet.microsoft.com/en-us/library/ff404265.aspx WMIDiag download http://www.microsoft.com/download/en/details.aspx?displaylang=en&id=7684


6

The Process Queue Length count from the System performance counter object is: Processor Queue Length is the number of threads in the processor queue[...] This value is available in WMI via Win32_PerfFormattedData_PerfOS_System.


6

The type of tool you're looking for is called an Application Repackaging tool. The process would include capturing an installation (take a machine snapshot, run your installation and make customisations, then run a second snapshot to calculate the differences) then compiling the captured data into MSI format. The following are some free tools to perform ...


6

There is another way to get at the information, and that's through WMI. An enterprising soul has put together a PowerShell script that gathers this information: http://gallery.technet.microsoft.com/scriptcenter/dac62790-219d-4325-a57b-e79c2aa6b58e No indication of whether or not is faster than dfsrdiag, but I suspect it just might be. The WMI root is ...


6

I was able to at least bring back the servers to a working state by re-registering all DLLs and recompiling all .mof and .mfl files under C:\Windows\System32\wbem, as documented here. I can't be 100% sure that the systems are fully working as they should, but at least now they are not failing miserably. However, it still doesn't make any sense at all for ...


5

Yes it is possible... http://technet.microsoft.com/en-us/library/hh831755.aspx Do a: Get-Command *-*firewall* to see various commands available as well.


5

I've installed it on dozens of servers and never had a problem with it. But none of them had Exchange, Sharepoint, SBS or SCCM. Mostly IIS and SQL only. I use a lot of PowerShell and love Version 3. I don't think there is a way to get PowerShell 3 without Windows Management Framework 3.0. So I guess it depends what else is on your servers.


5

Microsoft discontinued the MDAC object set as 2005, and supported OSes as of XP (even server 2003 does not fully support MDAC, particularly WMI ODBC is not supported). Windows Vista and newer OSes only support WinDAC, which does not offer WMI via ODBC. Side note: WMI isn't always the best interface to poke at, parts of it are terribly broken and even doing ...


5

As the GUI is just a feature, you can query the list of installed features Just testing this in powershell on a server here worked well enough: Dump a list of features to grab the name Get-WmiObject Win32_OptionalFeature > features.txt Searching the text of features.txt tells me that the feature is named 'Server-Gui-Mgmt' (other features may be ...


5

One I wrote to help a colleague, who RDPd to a server, opened Event Viewer, looked through it for errors. Then repeated for the other 3 servers... every day. ' ' WMI script to read all eventlog errors generated since last time this script was run. ' This script reads a datetime value from a file (EventView_date.txt) and uses it to ' construct a WMI query ...


5

The SYSTEM variables are those stored in: HKEY_LOCAL_MACHINE\SYSTEM\CurrentControlSet\Control\Session Manager\Environment The <DEFAULT> variables are those stored in: HKEY_USERS\.DEFAULT\Environment The .DEFAULT user is not the default settings that are created when a user's profile is created for the first time. Rather, .DEFAULT is the ...


5

Here's some sample code I used in a previous script... Dim myIPAddress : myIPAddress = "" Dim objWMIService : Set objWMIService = GetObject("winmgmts:{impersonationLevel=impersonate}!\\.\root\cimv2") Dim colAdapters : Set colAdapters = objWMIService.ExecQuery("Select IPAddress from Win32_NetworkAdapterConfiguration Where IPEnabled = True") Dim objAdapter ...


5

I think WMIC commands can be run from a single line which should make it easier to add to a batch file. And by adding /nointeractive then it should disable prompting as well. Try something like this: wmic product where name="software" call uninstall /nointeractive


5

SNMP for getting data (you can script data gathering and attach it to an OID) for hosts in foo bar baz; do ssh root@$host some-script; done puppet, bcfg, cfengine, etc... (many of these include components for getting data about systems, as well)


5

First of all, enable File Auditing in Administrative Tools -> Local Security Policy -> Local Policies -> Audit Policy -> Audit Object Access. Here, you want to enable both Failure & Success After that, right-click the folder where the folders will be created and go to Advanced in the Properties. There you'll have a tab Auditing. Add it for all users ...


5

You may also need to set the ACL's for the object you are trying to query. See http://msdn.microsoft.com/en-us/library/aa374872%28v=vs.85%29.aspx I've had to do this in the past for access to MS services, event logs, etc. EDIT: In a nutshell, you may need to set ACL's for the WMI objects you are trying to access, using an administrative account, before ...


4

or just do somethig like this at an elevated prompt wmic os


4

Processors these days are fairly intelligent about what's required from them, especially in laptops. Just because a processor is 1.83Ghz, it might decide to save power (and heat) by running at a lower clock speed if the extra power is not required. You can see this difference by going to your Windows Task manager. It's clearer in Vista and Windows 7, but ...


4

There is a script given away by Microsoft's Product Support Services team that's specifically designed to spot and diagnose corrupted WMI databases, the WMI Diagnostics Utility. More info on how to use this at Troubleshooting WMI With WMIDiag. Unfortunately I'm not too sure how useful this is going to be for you if you want to run this at the start of ...


4

I found the answer myself after digging around some more. The directory C:\Windows\System32\LogFiles\WMI\RtBackup stores ETW trace files (extension .etl) for real time event trace sessions. Looking into the RtBackup directory is a little difficult because by default only System has permissions, but my application SetACL Studio can display the contents ...


4

This is a truly great question, and it's a shame it has not gotten more love! My basic theory of bottleneck analysis is to treat the system as a box with 4 sorts of finite resources: processor, memory, disk, and network. So I want to get basic numbers for each of these to determine the health of the box. I want numbers that are easy to interpret: high is ...


4

I wouldn't recomend using wmic for this, (although you could use a for lop in a batch file) , as it's far easier in powershell (which is the way the question is tagged). Off the top of my head I'd do this: clear-Host $File = "Machines.txt" get-Content $File | foreach-object { $uname = (get-wmiobject win32_computersystem -computername $_).username ; $os = ...



Only top voted, non community-wiki answers of a minimum length are eligible