06 October 2008

Query Criterion Values

String Values

You must specify the exact string that the query will use to evaluate the expression — do not use quotation marks unless they are part of the string. For relational operators that perform LIKE comparisons ("is like" or "is not like"), you can use wildcard characters within the string. You can use the following wildcards.

Wildcard Description

%

Any string of zero or more characters

_ (underscore)

Any single character

[]

Any single character within the range or set (for example [a-f] or [abcdef])

[^]

Any single character not within the specified range (for example [^a-f] or [^abcdef])

Date and Time Values

You must enter a date that the query can use to evaluate the expression. This value must be entered according to the units that are specified by the date and time operator. For example, if you use the "year is after" operator, you would enter the year by using four digits (for example, 2002).

When you write queries by using Configuration Manager 2007 Query Builder, you can express the date and time in any valid SQL format. For more information, see the SQL Server documentation.

Query Criterion Values

String Values

You must specify the exact string that the query will use to evaluate the expression — do not use quotation marks unless they are part of the string. For relational operators that perform LIKE comparisons ("is like" or "is not like"), you can use wildcard characters within the string. You can use the following wildcards.

Wildcard Description

%

Any string of zero or more characters

_ (underscore)

Any single character

[]

Any single character within the range or set (for example [a-f] or [abcdef])

[^]

Any single character not within the specified range (for example [^a-f] or [^abcdef])

Date and Time Values

You must enter a date that the query can use to evaluate the expression. This value must be entered according to the units that are specified by the date and time operator. For example, if you use the "year is after" operator, you would enter the year by using four digits (for example, 2002).

When you write queries by using Configuration Manager 2007 Query Builder, you can express the date and time in any valid SQL format. For more information, see the SQL Server documentation.

29 September 2008

Prerequisites for Asset Intelligence :- SMS_def.mof 9 Modification Prerequisites for Asset Intelligence

Prerequisites for Asset Intelligence
 

The Asset Intelligence feature in Configuration Manager 2007 has both external dependencies and dependencies within the product that should be considered when implementing Asset Intelligence or attempting to view Asset Intelligence report information.

The prerequisites for Asset Intelligence in Configuration Manager 2007 include the following:

  • Client agent prerequisites
  • Hardware inventory file modification prerequisites
  • Site maintenance task prerequisites
  • Windows event log setting prerequisites

Client Agent Prerequisites

The Asset Intelligence reports depend on client information obtained through client hardware and software inventory reports.

To obtain the information necessary for all Asset Intelligence reports, the following client agents must be enabled:

  • Hardware inventory client agent
  • Software metering client agent

Hardware Inventory Client Agent Dependencies

To collect inventory data required for some Asset Intelligence reports, the hardware inventory client agent must be enabled. In addition, some hardware inventory reporting classes must be enabled in the SMS_DEF.mof file on the primary site server computer.

For information about enabling the Hardware Inventory Client Agent, see How to Configure Hardware Inventory for a Site.

Software Metering Client Agent Dependencies

A number of Asset Intelligence software reports depend on the software metering client agent for data. For information about enabling the software metering client agent, see How to Configure Software Inventory for a Site.

The following Asset Intelligence reports depend on the software metering client agent to provide data:

  • Software 07A - Recently Used Executables by Number of Computers
  • Software 07B - Computers that Recently Used a Specified Executable
  • Software 07C - Recently Used Executables on a Specific Computer
  • Software 08A - Recently Used Executables by Number of Users
  • Software 08B - Users that Recently Used a Specified Executable
  • Software 08C - Recently Used Executables by a Specified User

Hardware Inventory File Modification Prerequisites

Important file modification prerequisites apply to the Configuration.mof file and to the SMS_def.mof file.

For more information about the Configuration.mof file, see About MOF Files Used by Hardware Inventory.

For more information about editing the Configuration.mof file, see How to Extend Hardware Inventory Using the Configuration.mof File.

Configuration.mof File Modification Prerequisites

Client Access License (CAL) data collection must be enabled in the Configuration.mof hardware inventory data class file to provide data for the Asset Intelligence Client Access License reports. To enable CAL data collection, the Configuration.mof file must be edited and associated maintenance tasks must be enabled. In addition, computer security policies must be configured to audit Success logon events. For more information about enabling success event logging, see How to Enable Success Logon Event Logging.

For more information about Asset Intelligence CAL data reports, see About Client Access License Reports .

For more information about the maintenance tasks that must be enabled to support the Asset Intelligence CAL reports, see the "Site Maintenance Task Prerequisites" section in this topic.

To enable data collection for CAL data, the CCM_CALTrackConfig WMI data class must be edited in the Configuration.mof file to configure the following required settings.

Note
The Configuration.mof file is located on the primary site server computer in the <ConfigMgr installation directory> \ Inboxes \ clifiles.src \ hinv directory.

CALCollectionType

The CALCollectionType parameter controls whether CALs are tracked for devices, users, or both. To enable CAL data collection, the CALCollectionType parameter value must be changed from the default value of 0 to a value that specifies the type of data to be collected. The CALCollectionType parameter can be set to one of the values described in the following table.

Parameter Setting Setting Description

0

Data collection disabled

1

User CAL collection only

2

Device CAL collection only

3

All CAL collection enabled

Note
If you want to enable CAL data collection on more than one Configuration Manager 2007 or Configuration Manager 2007 SP1 primary site, the Configuration.mof file for each site must be edited.

CALCollectionFrequencyDays

A single server can be accessed regularly by thousands of users and devices. Creating a record in the Configuration Manager site database for each connection could result in high network bandwidth usage. Polling for which users or devices access the server on a weekly basis is adequate for tracking CAL usage. The CALCollectionFrequencyDays parameter value controls the frequency, in days, of CAL data collection. The default value is 7 days, but a value between 0 and 90 days can be specified. Setting this parameter to 0 causes polling to be run based on the CALCollectionFrequencyMinutes parameter.

CALCollectionFrequencyMinutes

When the CALCollectionFrequencyDays parameter setting is set to 0, polling occurs based on the CALCollectionFrequencyMinutes parameter setting. The CALCollectionFrequencyMinutes parameter setting controls the frequency, in minutes, of CAL data collection. A value between 1 and 1,440 minutes can be specified.

Note
Polling for CAL information too frequently in large sites can result in a significant network impact.

CALCollectionTimeWindow

Current Microsoft licensing models allow for CALs to be reassigned every 90 days. The CALCollectionTimeWindow parameter reflects this licensing model. If the model is changed, this parameter can be adjusted to agree with the new licensing model. The default is 90 days, but a value between 1 and 365 days can be specified.

CALSupportedWindowsVersions

To limit polling to servers, this parameter lists the operating system versions that are polled for client access information. This parameter setting should not be modified. Modification of this setting will result in inaccurate CAL counts. The default value is "5.0,5.2,6.0."

SMS_def.mof Modification Prerequisites

The following hardware inventory reporting classes in the SMS_def.mof file can be enabled to support Asset Intelligence reporting requirements:

Note
The SMS_def.mof file is located on the primary site server computer at <ConfigMgr installation directory> \ Inboxes \ clifiles.src \ hinv directory.

  1. SMS_SystemConsoleUsage
  2. SMS_SystemConsoleUser
  3. SMS_InstalledSoftware
  4. SMS_AutoStartSoftware
  5. SMS_BrowserHelperObject
  6. SMS_InstalledExecutable
  7. SMS_SoftwareShortcut
  8. SoftwareLicensingService
  9. SoftwareLicensingProduct


    For more information about hardware inventory reporting classes used by Asset Intelligence, see Hardware Inventory Reporting Classes Required for Asset Intelligence Reports.

Site Maintenance Task Prerequisites

Two site maintenance tasks are associated with CAL information stored in the site database:

  • Delete Aged Client Access License Data Properties
  • Summarize Client Access License Weekly Usage Data

For information about enabling and scheduling site maintenance tasks, see How To Schedule a Site Maintenance Task

Delete Aged Client Access License Data

The Delete Aged Client Access License Data maintenance task is not necessary for data collection, but it should be enabled to prevent the accumulation of unnecessary data stored in the site database. The purpose of this task is to periodically delete aged CAL data from the site database that is no longer needed.

For more information, see Delete Aged Client Access License Data Task Overview.

Summarize Client Access License Weekly Usage Data

The Summarize Client Access License Weekly Usage Data task establishes summaries of usage over time and directly supports the Asset Intelligence license management report: License 11A - Historical Client Access License (CAL) Utilization.

The CAL data that is collected from client hardware inventory reports represents a single computer at a single point in time. To have meaningful reports, it is necessary to periodically gather these points together into summaries that are stored and used for the purpose of tracking usage trends over time.

For more information, see Summarize Client Access License Weekly Usage Data Task Overview.

Windows Event Log Setting Prerequisites

Four Asset Intelligence reports display information gathered from the Windows security event logs on client computers. If the security event log settings are not set correctly, these reports will contain no data, even if the appropriate hardware inventory reporting class is enabled.

The following Asset Intelligence reports rely on collected Windows security event log information:

  • Hardware 3A - Primary Computer Users
  • Hardware 3B - Computers for a Specific Primary Console User
  • Hardware 4A - Shared (Multi-user) Computers
  • Hardware 5A - Console Users on a Specific Computer

To enable the hardware inventory client agent to inventory the information required to support these reports, you must first modify the Windows security event log settings on clients to log all Success logon events, as well as enable the SMS_SystemConsoleUser SMS_def.mof reporting class. For more information about modifying security event log settings to log all Success logon events, see How to Enable Success Logon Event Logging.

Note
The SMS_SystemConsoleUser SMS_def.mof reporting class will retain successful logon data for only the previous 90 days of the security event log, regardless of the length of the log. If the security event log has fewer than 90 days of data, the entire log is read.

Prerequisites for Asset Intelligence :- SMS_def.mof 9 Modification Prerequisites for Asset Intelligence

Prerequisites for Asset Intelligence
 

The Asset Intelligence feature in Configuration Manager 2007 has both external dependencies and dependencies within the product that should be considered when implementing Asset Intelligence or attempting to view Asset Intelligence report information.

The prerequisites for Asset Intelligence in Configuration Manager 2007 include the following:

  • Client agent prerequisites
  • Hardware inventory file modification prerequisites
  • Site maintenance task prerequisites
  • Windows event log setting prerequisites

Client Agent Prerequisites

The Asset Intelligence reports depend on client information obtained through client hardware and software inventory reports.

To obtain the information necessary for all Asset Intelligence reports, the following client agents must be enabled:

  • Hardware inventory client agent
  • Software metering client agent

Hardware Inventory Client Agent Dependencies

To collect inventory data required for some Asset Intelligence reports, the hardware inventory client agent must be enabled. In addition, some hardware inventory reporting classes must be enabled in the SMS_DEF.mof file on the primary site server computer.

For information about enabling the Hardware Inventory Client Agent, see How to Configure Hardware Inventory for a Site.

Software Metering Client Agent Dependencies

A number of Asset Intelligence software reports depend on the software metering client agent for data. For information about enabling the software metering client agent, see How to Configure Software Inventory for a Site.

The following Asset Intelligence reports depend on the software metering client agent to provide data:

  • Software 07A - Recently Used Executables by Number of Computers
  • Software 07B - Computers that Recently Used a Specified Executable
  • Software 07C - Recently Used Executables on a Specific Computer
  • Software 08A - Recently Used Executables by Number of Users
  • Software 08B - Users that Recently Used a Specified Executable
  • Software 08C - Recently Used Executables by a Specified User

Hardware Inventory File Modification Prerequisites

Important file modification prerequisites apply to the Configuration.mof file and to the SMS_def.mof file.

For more information about the Configuration.mof file, see About MOF Files Used by Hardware Inventory.

For more information about editing the Configuration.mof file, see How to Extend Hardware Inventory Using the Configuration.mof File.

Configuration.mof File Modification Prerequisites

Client Access License (CAL) data collection must be enabled in the Configuration.mof hardware inventory data class file to provide data for the Asset Intelligence Client Access License reports. To enable CAL data collection, the Configuration.mof file must be edited and associated maintenance tasks must be enabled. In addition, computer security policies must be configured to audit Success logon events. For more information about enabling success event logging, see How to Enable Success Logon Event Logging.

For more information about Asset Intelligence CAL data reports, see About Client Access License Reports .

For more information about the maintenance tasks that must be enabled to support the Asset Intelligence CAL reports, see the "Site Maintenance Task Prerequisites" section in this topic.

To enable data collection for CAL data, the CCM_CALTrackConfig WMI data class must be edited in the Configuration.mof file to configure the following required settings.

Note
The Configuration.mof file is located on the primary site server computer in the <ConfigMgr installation directory> \ Inboxes \ clifiles.src \ hinv directory.

CALCollectionType

The CALCollectionType parameter controls whether CALs are tracked for devices, users, or both. To enable CAL data collection, the CALCollectionType parameter value must be changed from the default value of 0 to a value that specifies the type of data to be collected. The CALCollectionType parameter can be set to one of the values described in the following table.

Parameter Setting Setting Description

0

Data collection disabled

1

User CAL collection only

2

Device CAL collection only

3

All CAL collection enabled

Note
If you want to enable CAL data collection on more than one Configuration Manager 2007 or Configuration Manager 2007 SP1 primary site, the Configuration.mof file for each site must be edited.

CALCollectionFrequencyDays

A single server can be accessed regularly by thousands of users and devices. Creating a record in the Configuration Manager site database for each connection could result in high network bandwidth usage. Polling for which users or devices access the server on a weekly basis is adequate for tracking CAL usage. The CALCollectionFrequencyDays parameter value controls the frequency, in days, of CAL data collection. The default value is 7 days, but a value between 0 and 90 days can be specified. Setting this parameter to 0 causes polling to be run based on the CALCollectionFrequencyMinutes parameter.

CALCollectionFrequencyMinutes

When the CALCollectionFrequencyDays parameter setting is set to 0, polling occurs based on the CALCollectionFrequencyMinutes parameter setting. The CALCollectionFrequencyMinutes parameter setting controls the frequency, in minutes, of CAL data collection. A value between 1 and 1,440 minutes can be specified.

Note
Polling for CAL information too frequently in large sites can result in a significant network impact.

CALCollectionTimeWindow

Current Microsoft licensing models allow for CALs to be reassigned every 90 days. The CALCollectionTimeWindow parameter reflects this licensing model. If the model is changed, this parameter can be adjusted to agree with the new licensing model. The default is 90 days, but a value between 1 and 365 days can be specified.

CALSupportedWindowsVersions

To limit polling to servers, this parameter lists the operating system versions that are polled for client access information. This parameter setting should not be modified. Modification of this setting will result in inaccurate CAL counts. The default value is "5.0,5.2,6.0."

SMS_def.mof Modification Prerequisites

The following hardware inventory reporting classes in the SMS_def.mof file can be enabled to support Asset Intelligence reporting requirements:

Note
The SMS_def.mof file is located on the primary site server computer at <ConfigMgr installation directory> \ Inboxes \ clifiles.src \ hinv directory.

  1. SMS_SystemConsoleUsage
  2. SMS_SystemConsoleUser
  3. SMS_InstalledSoftware
  4. SMS_AutoStartSoftware
  5. SMS_BrowserHelperObject
  6. SMS_InstalledExecutable
  7. SMS_SoftwareShortcut
  8. SoftwareLicensingService
  9. SoftwareLicensingProduct


    For more information about hardware inventory reporting classes used by Asset Intelligence, see Hardware Inventory Reporting Classes Required for Asset Intelligence Reports.

Site Maintenance Task Prerequisites

Two site maintenance tasks are associated with CAL information stored in the site database:

  • Delete Aged Client Access License Data Properties
  • Summarize Client Access License Weekly Usage Data

For information about enabling and scheduling site maintenance tasks, see How To Schedule a Site Maintenance Task

Delete Aged Client Access License Data

The Delete Aged Client Access License Data maintenance task is not necessary for data collection, but it should be enabled to prevent the accumulation of unnecessary data stored in the site database. The purpose of this task is to periodically delete aged CAL data from the site database that is no longer needed.

For more information, see Delete Aged Client Access License Data Task Overview.

Summarize Client Access License Weekly Usage Data

The Summarize Client Access License Weekly Usage Data task establishes summaries of usage over time and directly supports the Asset Intelligence license management report: License 11A - Historical Client Access License (CAL) Utilization.

The CAL data that is collected from client hardware inventory reports represents a single computer at a single point in time. To have meaningful reports, it is necessary to periodically gather these points together into summaries that are stored and used for the purpose of tracking usage trends over time.

For more information, see Summarize Client Access License Weekly Usage Data Task Overview.

Windows Event Log Setting Prerequisites

Four Asset Intelligence reports display information gathered from the Windows security event logs on client computers. If the security event log settings are not set correctly, these reports will contain no data, even if the appropriate hardware inventory reporting class is enabled.

The following Asset Intelligence reports rely on collected Windows security event log information:

  • Hardware 3A - Primary Computer Users
  • Hardware 3B - Computers for a Specific Primary Console User
  • Hardware 4A - Shared (Multi-user) Computers
  • Hardware 5A - Console Users on a Specific Computer

To enable the hardware inventory client agent to inventory the information required to support these reports, you must first modify the Windows security event log settings on clients to log all Success logon events, as well as enable the SMS_SystemConsoleUser SMS_def.mof reporting class. For more information about modifying security event log settings to log all Success logon events, see How to Enable Success Logon Event Logging.

Note
The SMS_SystemConsoleUser SMS_def.mof reporting class will retain successful logon data for only the previous 90 days of the security event log, regardless of the length of the log. If the security event log has fewer than 90 days of data, the entire log is read.

25 September 2008

Disk Space Threshold Registry Key


Disk SpaceThreshold

By default Windows sends an administrative alert when the amount of free space remaining on a hard disk drive falls below 10 percent. This percentage can be configured using this setting.

Open your registry and find the key below.

Create a new DWORD value called "DiskSpaceThreshold" and set it to the percentage of free disk space remaining before an alert is sent.

Restart Windows for the change to take effect.

 

Registry Settings
System Key: [HKEY_LOCAL_MACHINE\System\CurrentControlSet\Services\LanmanServer\
Parameters]
Value Name: DiskSpaceThreshold
Data Type: REG_DWORD (DWORD Value)
Value Data: 0 - 99 percent (Default is 10)

 

Disk Space Threshold Registry Key


Disk SpaceThreshold

By default Windows sends an administrative alert when the amount of free space remaining on a hard disk drive falls below 10 percent. This percentage can be configured using this setting.

Open your registry and find the key below.

Create a new DWORD value called "DiskSpaceThreshold" and set it to the percentage of free disk space remaining before an alert is sent.

Restart Windows for the change to take effect.

 

Registry Settings
System Key: [HKEY_LOCAL_MACHINE\System\CurrentControlSet\Services\LanmanServer\
Parameters]
Value Name: DiskSpaceThreshold
Data Type: REG_DWORD (DWORD Value)
Value Data: 0 - 99 percent (Default is 10)

 

22 September 2008

Configuring SLP / MP in WINS


Configuring SLP in WINS

To manually configure the SMS 2003 Server Locator Point (SLP) server in WINS, type the following from a command prompt:

C:\>netsh <enter>
NETSH>wins <enter>
WINS>server <enter>
WINS SERVER>add name Name=SMS_SLP endchar=1A rectype=0 ip={xxx.xxx.xxx.xxx}
(NOTE: Replace x's with IP address of server acting as SLP)

Command completed successfully.
(This will appear if you used the proper syntax.)

This can also be configured in one simple command (all on one line) as follows:
wins server \\SERVERNAME add name Name=SMS_SLP endchar=1a rectype=0 ip={xxx.xxx.xxx.xxx}

To verify the SLP entry in WINS:

WINS SERVER>show name Name=SMS_SLP endchar=1A

Name : SMS_SLP [1Ah]
NodeType : 1
State : ACTIVE
Expiration Date : Infinite
Type of Rec : UNIQUE
Version No : 0 1bc1
RecordType : STATIC
IP Address : xxx.xxx.xxx.xxx
Command completed successfully.

Configuring MP in WINS
To manually configure the SMS 2003 Management Point (MP) in WINS, type:

WINS SERVER>add name Name=SMS_MP endchar=1A rectype=0 ip={xxx.xxx.xxx.xxx}
(NOTE: Replace x's with IP address of server acting as SLP)

Command completed successfully.
(This will appear if you used the proper syntax.)

To verify the MP entry in WINS:
WINS SERVER>show name Name=SMS_MP endchar=1A

Name : SMS_MP [1Ah]
NodeType : 1
State : ACTIVE
Expiration Date : Infinite
Type of Rec : UNIQUE
Version No : 0 1bc2
RecordType : STATIC
IP Address : xxx.xxx.xxx.xxx
Command completed successfully.

When finished, type:
WINS SERVER> exit <enter>
C:\>

Everything was going really well with the newest version of SMS 2003, including an average software distribution success rate of more than 95%. About a month later, when hardware became available, another primary site was configured at our Disaster Recovery location, including a separate server to act as a Central Site for both primary sites.

Problems Arise
From this point, strange things began to happen. Some of our SMS 2003 Advanced Clients were not even receiving configured advertisements and our success rate dipped as low as 60% successful.

Thanks to Michael Niehaus's expertise, the syntax for configuring a Management Point in WINS is slightly different if all the SMS sites in the hierarchy share the same WINS database!!!

Configure Multiple MPs in one WINS Database
To configure multiple SMS 2003 Management Points (MP) in WINS that share the same database, follow this syntax:

add name Name=MP_<sitecode> endchar=1A rectype=0 ip={xxx.xxx.xxx.xxx}
(NOTE: Replace x's with IP address of server acting as SLP)

To verify the MP entry in WINS:

show name Name=MP_<sitecode> endchar=1A

Enjoy,
Paddy

Configuring SLP / MP in WINS


Configuring SLP in WINS

To manually configure the SMS 2003 Server Locator Point (SLP) server in WINS, type the following from a command prompt:

C:\>netsh <enter>
NETSH>wins <enter>
WINS>server <enter>
WINS SERVER>add name Name=SMS_SLP endchar=1A rectype=0 ip={xxx.xxx.xxx.xxx}
(NOTE: Replace x's with IP address of server acting as SLP)

Command completed successfully.
(This will appear if you used the proper syntax.)

This can also be configured in one simple command (all on one line) as follows:
wins server \\SERVERNAME add name Name=SMS_SLP endchar=1a rectype=0 ip={xxx.xxx.xxx.xxx}

To verify the SLP entry in WINS:

WINS SERVER>show name Name=SMS_SLP endchar=1A

Name : SMS_SLP [1Ah]
NodeType : 1
State : ACTIVE
Expiration Date : Infinite
Type of Rec : UNIQUE
Version No : 0 1bc1
RecordType : STATIC
IP Address : xxx.xxx.xxx.xxx
Command completed successfully.

Configuring MP in WINS
To manually configure the SMS 2003 Management Point (MP) in WINS, type:

WINS SERVER>add name Name=SMS_MP endchar=1A rectype=0 ip={xxx.xxx.xxx.xxx}
(NOTE: Replace x's with IP address of server acting as SLP)

Command completed successfully.
(This will appear if you used the proper syntax.)

To verify the MP entry in WINS:
WINS SERVER>show name Name=SMS_MP endchar=1A

Name : SMS_MP [1Ah]
NodeType : 1
State : ACTIVE
Expiration Date : Infinite
Type of Rec : UNIQUE
Version No : 0 1bc2
RecordType : STATIC
IP Address : xxx.xxx.xxx.xxx
Command completed successfully.

When finished, type:
WINS SERVER> exit <enter>
C:\>

Everything was going really well with the newest version of SMS 2003, including an average software distribution success rate of more than 95%. About a month later, when hardware became available, another primary site was configured at our Disaster Recovery location, including a separate server to act as a Central Site for both primary sites.

Problems Arise
From this point, strange things began to happen. Some of our SMS 2003 Advanced Clients were not even receiving configured advertisements and our success rate dipped as low as 60% successful.

Thanks to Michael Niehaus's expertise, the syntax for configuring a Management Point in WINS is slightly different if all the SMS sites in the hierarchy share the same WINS database!!!

Configure Multiple MPs in one WINS Database
To configure multiple SMS 2003 Management Points (MP) in WINS that share the same database, follow this syntax:

add name Name=MP_<sitecode> endchar=1A rectype=0 ip={xxx.xxx.xxx.xxx}
(NOTE: Replace x's with IP address of server acting as SLP)

To verify the MP entry in WINS:

show name Name=MP_<sitecode> endchar=1A

Enjoy,
Paddy

16 September 2008

WScript.Echo "Computer connecting error: " & strComputer

WScript.Echo "Computer connecting error: " & strComputer
 
This is the code to get the output in vbscript with computername

WScript.Echo "Computer connecting error: " & strComputer

WScript.Echo "Computer connecting error: " & strComputer
 
This is the code to get the output in vbscript with computername