Tag: Winteladmin

VMware Tools is no more depended on vSphere/Esxi release.

VMware tools 10.0.0 is now no more dependent on vSphere release/Esxi builds. I think this is the first time when VMware released VMware Tools separately. As per release note its backward compatible, compatible with Esxi 5.0 and also compatible with Workstation 12.0 and VMware Fusion 8.0. It will allow to get the latest new features and enhancements made to the VMware tools faster to the customers.

You can download and install the latest version of VMware Tools from Here.

Thanks,
WintelAdmin

Filed under: VMware (ESX / vSphere), Windows(2003/2008/2012)Tagged with: , , , , , , , , , , , ,

RDP Error – The connection cannot be completed because the remote computer that was reached is not the one you specified. This could be caused by an outdated entry in the DNS cache. Try using the IP address of the computer instead of the name.

Unable to connect to the Remote Desktop. Server operating system is Windows Server 2012 Standard R2. When we try to RDP, we get the below error message:

The connection cannot be completed because the remote computer that was reached is not the one you specified. This could be caused by an outdated entry in the DNS cache. Try using the IP address of the computer instead of the name.

There was two server with same configuration and setting but one of connecting to RDP with AD authentication whereas the other was not working. One was physical and the other was virtual hosted on an ESX host.
RDP on physical was good and the issue was with the virtual host. It was confirmed that the issue was due to time latency.
Therefore, this issue was due to the time difference between the virtual machine and the NTP server set on an ESX host.
This issue was later fixed by synchronizing the server time with the ESX host.

Note:
If you do not wish to have auto sync, disable the Windows Time service or block the outbound port 123 on your local firewall.

Thanks,
WintelAdmin

Filed under: Windows(2003/2008/2012)Tagged with: , , , , , , , ,

Windows could not finish configuring the system.

Recently, I was installing Windows 2008 R2 on a HP ProLiant DL380 Gen9 server. Found that the server was throwing an error message stating “Windows could not finish configuring the system.”. When you click on “OK”, servers gets automatic reboot and shows again the same error.

When searched on google, I found that this error message occurs with Windows Server 2008 R2 operating systems if the system contains a registry key that is larger than 8 kilobytes (KB). A Hotfix for this problem is available from Microsoft

KB981542

In my case it was during a clean install of Windows OS, hence it was fixed following the steps listed below:

When you find the error message stating that the “Windows could not finish configuring the system” appears on your screen:

1. Hold down the SHIFT key and press F10 (SHIFT + F10) to open command prompt.
2. At command prompt type: cd oobe (& press Enter).
3. Then type: msoobe (& press Enter).
4. Finally Restart your computer.

You will see your machine back with CTRL+ALT+DEL screen.

Thanks,
WintelAdmin

Filed under: Windows(2003/2008/2012)Tagged with: , , , , , , , , ,

VB Script to collect Windows server hardware details on multiple machines.

VB Script to collect Windows server hardware details. Script will Collect Serial Number, Make, Model, OS, CPU, RAM, Drive details on multiple servers remotely.

Copy below contents and save as filename.vbs and create a machines.txt will all server names one per line.

 

***********************************************************************************************************************

Option Explicit

Const wbemFlagReturnImmediately = &h10
Const wbemFlagForwardOnly = &h20

Const PATH_TO_INPUT = “Machines.txt”
Const PATH_TO_OUTPUT = “MachineInventory.csv”

Dim fso
Set fso = WScript.CreateObject(“Scripting.FileSystemObject”)

Dim shl
Set shl = WScript.CreateObject(“WScript.Shell”)

Dim input
Set input = fso.OpenTextFile(PATH_TO_INPUT)

Dim output
Set output = fso.CreateTextFile(PATH_TO_OUTPUT, True)

output.WriteLine “Hostname,Serial Number,Make,Model,BIOS Version,Operating System,CPU,Memory (MB),Disk Drives”

Dim wmiService
Dim wmiResults

Dim hostname
Dim make
Dim model
Dim biosversion
Dim operatingSystem
Dim serialNumber
Dim cpu
Dim memory
Dim drives

Dim line
Dim exec
Dim pingResults
While Not input.AtEndOfStream
line = input.ReadLine
hostname = “”
make = “”
model = “”
biosversion = “”
operatingSystem = “”
serialNumber = “”
cpu = “”
memory = “”
drives = “”

Set exec = shl.Exec(“ping -n 2 -w 1000 ” & line)
pingResults = LCase(exec.StdOut.ReadAll)

If InStr(pingResults, “reply from”) Then
WScript.Echo “Reply From: ” & line
On Error Resume Next

Set wmiService = GetObject(“winmgmts:\\” & line & “\root\CIMV2”)

If Not Err.Number = 0 Then
output.WriteLine line & “,Error: ” & Err.Description
WScript.Echo line & “,Error: ” & Err.Description
On Error GoTo 0
Else
On Error GoTo 0
hostname = line

Set wmiResults = wmiService.ExecQuery(“SELECT * FROM Win32_BIOS”, “WQL”, wbemFlagReturnImmediately + wbemFlagForwardOnly)

Dim item
For Each item In wmiResults
serialNumber = Trim(item.SerialNumber)
biosversion = Trim(item.SMBIOSBIOSVersion)
Next

Set wmiResults = wmiService.ExecQuery(“SELECT * FROM Win32_ComputerSystem”, “WQL”, wbemFlagReturnImmediately + wbemFlagForwardOnly)

For Each item In wmiResults
make = Trim(item.Manufacturer)
model = Trim(item.Model)
Next

Set wmiResults = wmiService.ExecQuery(“SELECT * FROM Win32_OperatingSystem”, “WQL”, wbemFlagReturnImmediately + wbemFlagForwardOnly)

For Each item In wmiResults
operatingSystem = Trim(item.Name)
operatingSystem = Split(operatingSystem, “|”)(0)
memory = Round(Trim(item.TotalVisibleMemorySize) / 1024, 2)
Next

Set wmiResults = wmiService.ExecQuery(“SELECT * FROM Win32_Processor”, “WQL”, wbemFlagReturnImmediately + wbemFlagForwardOnly)

For Each item In wmiResults
cpu = Trim(item.Name)
Next

Set wmiResults = wmiService.ExecQuery(“SELECT * FROM Win32_LogicalDisk WHERE DriveType=3”, “WQL”, wbemFlagReturnImmediately + wbemFlagForwardOnly)

For Each item In wmiResults
drives = drives & Trim(item.DeviceID) & ” ” & Round(Trim(item.Size) / (1024^2), 2) & “;”
Next

output.WriteLine hostname & “,” & serialNumber & “,” & make & “,” & model & “,” & biosversion & “,” & operatingSystem & “,” & cpu & “,” & memory & “,” & drives
WScript.Echo hostname & “,” & serialNumber & “,” & make & “,” & model & “,” & biosversion & “,” & operatingSystem & “,” & cpu & “,” & memory & “,” & drives
End If
Else
output.WriteLine line & “,No Response”
WScript.Echo line & “,No Response”
End If
Wend

output.Close
input.Close

Set wmiService = Nothing
Set wmiresults = Nothing

***********************************************************************************************************************

 

Thanks,

WintelAdmin

 

Filed under: Scripting (Automation)Tagged with: , , , , , , , , , ,

Windows Server 2008 keeps rebooting to repair mode.

Today, one of the Windows 2008 server was rebooted and the server was not back online after the expected time. When checked the console, server was on to Windows repair mode. On multiple reset and reboot the scenario was same. Server was keep on login to repair mode. Laer, I was success in fixing the issue following the steps listed below:

Booted the server using the DVD or any bootup media.

Run sfc /scannow /offbootdir=f:\ /offwindir=f:\windows

If this does not fix the problem, continue with below steps:

Loaded hive into the registry:

1. Open Registry Editor.
2. Click either the HKEY_USERS key or HKEY_LOCAL_MACHINE key.
3. On the File menu, click Load Hive….
4. Select System file from “c:\windows\system32\config”.
4. Find the hive you want to load and click it.
5. Click Open.
6. Key name as TEST

Checked with the currentcontrolset001

Unloaded the hives

Rebooted the server normally and the issue is fixed.

Thanks,
Winteladmin
Filed under: Windows(2003/2008/2012)Tagged with: , , , , , ,

Powershell Script to start/stop/disable service on multiple remote server

Powershell script to control windows service on multiple remote servers.

Get-content “Filename” | foreach {set-Service -ComputerName $_ -Name “Service Name” -StartupType Disabled -Status Stopped}

Note:
Replace Filename with filename location (Ex C:\hostname.txt).
Add all servers names to filesname (Ex hostname.txt)
Change StartupType as Disabled/Manual/Automatic
Change Status as Stopped/started

-WintelAdmin

Filed under: Scripting (Automation)Tagged with: , , , , , , , ,

Upgrading Windows 2008 R2 editions from the command line without media.

Tested something new with Windows 2008 today. Windows 2008 has an inbuilt utility called the Deployment Image Servicing and Management (DISM) tool which does not require any media to upgrade the edition and just needs a reboot.

this is not possible on a domain controllers and only do upgrades, not downgrades.
Supported Windows 2008 R2 upgrade paths are:

Windows Server 2008 R2 STD -> Windows Server 2008 R2 ENT -> Windows Server 2008 R2 DC
Windows Server 2008 R2 STD Core -> Windows Server 2008 R2 ENT Core -> Windows Server 2008 R2 DC Core
Windows Server 2008 R2 Foundation -> Windows Server 2008 R2 STD

To upgrade, you need to provide a valid 25-character product key for the edition to which you’re upgrading.

To determine the installed edition, run:

DISM /online /Get-CurrentEdition

To check the possible target editions, run:

DISM /online /Get-TargetEditions

Finally, to initiate an upgrade, run:

DISM /online /Set-Edition: /ProductKey:XXXXX-XXXXX-XXXXX-XXXXX-XXXXX

So, for example, to upgrade to Windows Server 2008 R2 Datacenter from a downlevel edition, you would run:

DISM /online /Set-Edition:ServerDatacenter /productkey:ABCDE-ABCDE-ABCDE-ABCDE-ABCDE

After running the /Set-Edition command, DISM will prepare the operating system for the edition servicing operation, then reboot twice while it applies the changes to the operating system. After the final reboot, you’ll be running the new edition!

Thanks,
WintelAdmin

Filed under: Windows(2003/2008/2012)Tagged with: , , , , , , , , ,

Fix RDP on Windows 2003 without reboot.

A very common issue on a daily life of a Windows server administrator is that the users complaining about RDP issue. If the issue is with Windows 2008, that’s fine as we can restart the remote desktop services to fix the issue. But the same issue on Windows 2003 is bit annoying.

However, I have found a solution which works perfect.

The fix: (remotely using command prompt)

tasklist /s \\servername /svc /fi “imagename eq svchost.exe” (locate PID for TermService)
taskkill /s \\servername /pid xxxx (may need /f to force, UAC might give problems as well)
sc \\servername start TermService

The Fix: (local, using command prompt)

tasklist /svc /fi “imagename eq svchost.exe” (locate PID for TermService)
taskkill /pid xxxx (may need /f to force, UAC might give problems as well)
sc \\servername start TermService

Detailed Information:

Open a command prompt
Type in: tasklist /svc /fi “imagename eq svchost.exe”
This will list the different instances of svchost.exe and the associated service and PID
Locate TermService and note the PID for it
Open Task Manager and go to the Processes tab. Then click View > Select Columns and check PID, then click OK
Locate the svchost.exe process with the PID noted in step 4, right click it, select End Process
Open services.msc
Start the Terminal Services service

Thanks,
WintelAdmin

Filed under: Windows(2003/2008/2012)Tagged with: , , , , , , , , ,

VM Tools Update Failure [solved]

During VM Tools update, if you find any issues like unable to remove older version of VMware Tools or error 1714, you can remove old version manually from the registry to resolve the issue:

1. Open the Windows Registry using regedit.
2. Browse to HKLM\Software\Microsoft\Windows\CurrentVersion\uninstall.
Search for the branch with a key named DisplayName and has a value of VMware Tools.
Delete the branch associated with that entry. Do not delete the entire uninstall branch.
3. Browse to HKLM\Software\Classes\Installer\Products.
Search for the branch with the key named ProductName and has a value of VMware Tools.
Delete the branch associated with that entry.
4. Browse to HKEY_CLASSES_ROOT\Installer\Products.
Search for the branch with the key named ProductName and has a value of VMware Tools.
Delete the branch associated with that entry.
5. Browse to HKLM\Software\VMware.
Delete the branch called VMware Tools.
6. Ensure the folder located in %ProgramFiles%VMwareVMware Tools is deleted.
7. Install the new version of VMware Tools.

NOTE: Take the backup of the registry before performing the above steps.

Thanks,
WintelAdmin

Filed under: VMware (ESX / vSphere), Windows(2003/2008/2012)Tagged with: , , , , , , , , , , ,