Description
Storage resource management (SRM) is a key storage management activity focused on ensuring that important storage devices, such as disks, are formatted and installed with appropriate DHCP systems. In addition, SRM includes using management technologies to monitor storage resources to ensure that they meet availability, capacity, and performance requirements.
Purpose
This task ensures that the DHCP logging facility will have sufficient space to create new log entries and that the DHCP database can grow as appropriate.
Windows Server 2003 DHCP server performs disk checks at regular intervals to ensure the ongoing availability of server disk space and to ensure that the current audit log file does not become too large or that log file growth is not occurring too rapidly.
The DHCP server performs a full disk check whenever either of the following conditions occurs:
Each time a disk check is completed, the DHCP service checks to see if the server disk space is full. If the disk is full, the DHCP server closes the current file and ignores further requests to log audit events either until midnight or until disk status is improved and the disk is no longer full.
Regularly review the available space on the system partition of the DHCP server. If disk space is less then 20 MB, the DHCP server will log an entry and then close the audit log until disk space is made.
The script below illustrates the displaying of resource information similar to Procedure 1 above. This script does not continuously collect and store formatted performance information, but serves as a sample base for writing an operations script that may be integrated with an enterprise management package.
1. Copy and paste the script to Notepad.exe and save to a file such as “DhcpChkSpace.vbs.”
2. Run the script by typing the following command:
cscript //nologo DHCPChkSpace.vbs
Script listing for multiple server checks:
rem – DHCP Check Disk Space for Log and DB Drive ---------------------
On Error Resume Next
rem ---------------------------------------------------------------------------------
rem -- List all DHCP Servers in the strDHCPServer array in quotes
rem -- and separated by commas. use "." for localsystem.
rem --
rem -- Example:
rem -- strDHCPServer=array("dhcpsvr01","dchpsvr02","192.168.23.21")
rem --
arrDHCPSvr = array( ".","dhcpsvr01")
rem ---------------------------------------------------------------------------------
For Each strComputer in arrDHCPsvr
Set objWMIService = GetObject("winmgmts:\\" & strComputer & "\root\cimv2")
Set colItems = objWMIService.ExecQuery("Select * from Win32_LogicalDisk",,48)
For Each objItem in colItems
Wscript.Echo "DeviceID: " & objItem.DeviceID
Wscript.Echo "FreeSpace: " & objItem.FreeSpace
Wscript.Echo "VolumeName: " & objItem.VolumeName
Next
Next
rem – END OF SCRIPT --
Script listing for single server with specific drive check:
rem – DHCP Check Disk Space for Log and DB Drive ----------------
On Error Resume Next
rem – Replace “.” with the DHCP server’s hostname or IP.
strComputer="."
Set objWMIService = GetObject("winmgmts:\\" & strComputer & "\root\cimv2")
rem – Replace ‘c:’ with the DHCP server’s appropriate log and db drive
rem --
Set colItems = objWMIService.Get("Win32_LogicalDisk.DeviceID='c:'")
Wscript.Echo "DeviceID: " & colItems.DeviceID
Wscript.Echo "FreeSpace: " & colItems.FreeSpace
Wscript.Echo "VolumeName: " & colItems.VolumeName
rem – END OF SCRIPT --
Dependencies
None
Technology Required
Operating Quadrant | Service Monitoring and Control SMF | Infrastructure Role Cluster | Daily |