Problem: VMware Tools on Windows Server 2016

Checking on vSphere my new Windows Server 2016 VM, I noticed that there was a warning regarding VMware Tools not installed. This was not true because VMware Tools was installed on vm but checking the services, only “VMware Alias Manager and Ticket Service” was there!.

I uninstalled VMware Tools, restarted the VM and reinstalled VMware Tools right-clicking “Setup64.exe” and selecting “Run as Admin”.

Now I have all the VMware services installed and the warning is gone on vSphere.

Advertisements

ERROR: Task scheduler service is not available

On Windows Server 2016 creating a new task on scheduler I stumbled on this strange error: “Task scheduler service is not available. Task scheduler will try to reconnect to it.”

Task scheduler service seemed running fine (at least for other tasks :-)). After some troubleshooting I discovered that the problem was the Network condition Setting:

SchedulerTask_Network

If I define this condition, the task stop running with the error above.

Error: DCDIAG report “Invalid service startup type: NtFrs”

On a new Windows 2012 R2 Domain Controller on a 2008 forest level with SYSVOL already migrated to DFS, I had this error running DCDIAG:

Starting test: Services
Invalid service startup type: NtFrs on DCO01, current value
DISABLED, expected value AUTO_START
NtFrs Service is stopped on [DCO01]

Starting test: VerifyReferences
Some objects relating to the DC DCO01 have problems:
[1] Problem: Missing Expected Value
Base Object:
CN=DCO01,OU=Domain Controllers,DC=mydomain,DC=local
Base Object Description: “DC Account Object”
Value Object Attribute Name: frsComputerReferenceBL
Value Object Description: “SYSVOL FRS Member Object”
Recommended Action: See Knowledge Base Article: Q312862
……………………. DCO01 failed test VerifyReferences

Every thing is working fine (at least on my DC), it’s only an incorrect error detection from DCDIAG: https://support.microsoft.com/en-us/help/3110032/dcdiag-verifyreferences-test-fails-when-you-use-dfsr-to-replicate-sysvol

On the DC with this issue I had DCDIAG.EXE version 6.3.9600.16384
Updating it with KB2919355 the DCDIAG version jumped to 6.3.9600.17031

How to Disable Network Card from CMD

If you need to disable a NIC from command line on windows this is the path:

WMI:

wmic nic get name, index

Check then index of the NIC you want to disable and run:

wmic path win32_networkadapter where index=[NIC number] call disable

…change the [NIC Number] with the index of the wanted network card.

Now in the control panel, you should see that the desired network connection is now disabled.

To enable it again:

wmic path win32_networkadapter where index=[NIC number] call enable

If you what to disable some type of devices (like WiFi), type this command to check the NetConnectionID attribute:

wmic nic get name, index, NetConnectionID

WMI_NIC

and disable it selecting by NetConnectionID:

wmic path win32_networkadapter where 'NetConnectionID like "%Wi-Fi%" ' call disable

or

wmic path win32_networkadapter where NetConnectionID="Wi-Fi" call disable

All these tasks can be done with netsh or powershell.

Netsh:

netsh interface show interface
netsh interface set interface "Wi-Fi" disabled

Powershell:

Get-NetAdapter
Get-NetAdapter -Name wi-fi | Disable-NetAdapter -Confirm:$false

How to – Disable Windows Search Backoff

Indexer Backoff is used to slow down background indexing activity when the system load is high. This means that your stuff will be indexing slow on certain condition.

There is a GPO or a reg key to disable this.
For do it via registry:

reg add "HKLM\SOFTWARE\Policies\Microsoft\Windows\Windows Search" /v DisableBackoff /t REG_DWORD /d 1 && net stop "Windows Search" && net start "Windows Search"

For do this via local GPO look at:

Computer Configuration > Administrative Templates > Windows Components > Search

 

Problem: Windows defender do not start

On my machine :-( Windows Defender stop working and on Event log I found this:

Activation of app Microsoft.Windows.SecHealthUI_cw5n1h2txyewy!SecHealthUI failed with error: The remote procedure call failed. See the Microsoft-Windows-TWinUI/Operational log for additional information

I started my troubleshooting running System File Checker.
Open CMD as Administrator:

sfc /scannow

The results of SFC can be these:
– Windows did not find any integrity violations (a good thing)
– Windows Resource Protection found corrupt files and repaired them (a good thing)
– Windows Resource Protection found corrupt files but was unable to fix some (or all) of them (not a good thing)

I was on third option :-(
If you get this message like me, run DISM as described below:

DISM /Online /Cleanup-Image /RestoreHealth

If the repair is successful you may want to re-run SFC just to check.

Unfortunately I get the error message “cannot find source files”.
Windows Installation ISO is then necessary (same build of installed OS). Mount the ISO file and rerun the command specifying  where it is located with the below command:

DISM /Online /Cleanup-Image /RestoreHealth /source:X:\Sources\Install.wim

Where “X” is the drive letter where the ISO is located.