I know I am not explaining this well - but ultimately I would like to enter a computer number and have it pull up the AD information and then go into DHCP and pull the leases. $obj = New-Object -TypeName psobject -Property $pro ![]() $lease = Get-DhcpServerv4Lease -ComputerName 'XXXXXXX- need to have 2 here if possible XXXX' -ScopeId $scope.ScopeId #write-host "The current scope name is:" $scope.name -ForegroundColor Red powershell instead, there are several customer-shared scripts available. The bit I have start on but I am getting really mixed results $scopes = Get-DhcpServerv4Scope -ComputerName 'XXXXXXX- need to have 2 here if possible XXXX' Check the available OIDs in the DHCP-MIB You will find all the relevant MIB. I also have 2 servers that I need to poll for IP leases. You can do this with the Add-DhcpServerV4Scope cmdlet. Now that the DHCP server is authorized, you’ll need to add a scope. You can view a list of DHCP server that are authorized in AD by running the following command: Get-DhcpServerInDC. ![]() I need to pull it from there for MS Surface device issues. Add-DhcpServerInDC -DNSName -IPAddress 172.16.0.50. ![]() I have a couple of scripts that I use to look up info in AD (one I provide info from the description field the other I enter the computer number) What I would like to take onto those is pulling IP address leases from DHCP. So I have another basic PowerShell thing that I am not quite advanced enough to figure out.
0 Comments
Leave a Reply. |