Posts Tagged ‘windows’

No 

Yes

Reg key in a handy commandlet to disable the new menu and use classic;

reg.exe add “HKCU\Software\Classes\CLSID\{86ca1aa0-34aa-4e8b-a509-50c905bae2a2}\InprocServer32” /f /ve

Then just restart explorer.exe

To bring it back run;

reg.exe delete “HKCU\Software\Classes\CLSID\{86ca1aa0-34aa-4e8b-a509-50c905bae2a2}” /f

 

GD Star Rating
loading...
GD Star Rating
loading...

Recently we had moved some onpremise Server 2016 machines to Azure using ASR. When trying to activate them using the Microsoft steps

  • cscript c:\windows\system32\slmgr.vbs /dlv
  • cscript c:\windows\system32\slmgr.vbs /ipk WC2BQ-8NRM3-FDDYY-2BFGV-KHKQY
  • cscript c:\windows\system32\slmgr.vbs /ato

It did not work, we had to use Automatic Virtual Machine Activation (AVMA)

  1. slmgr /ipk C3RCX-M6NRP-6CXC9-TW2F2-4RHYD
    
GD Star Rating
loading...
GD Star Rating
loading...

Recently we had a Mac not be able to access a Windows Samba (SMB) Share

Thinking a windows update could have caused some issue, we tested another Mac but it worked fine 

OS X Mavericks 10.9 brings a change of SMB2 instead of SMB1 , which can be disabled with the below command 

echo "[default]" >> ~/Library/Preferences/nsmb.conf; echo "smb_neg=smb1_only" >> ~/Library/Preferences/nsmb.conf

This still didn’t work so we reverted back to SMB2 with the below

rm ~/Library/Preferences/nsmb.conf

I used Telnet to make sure there wasn’t a network issue on port 445 ( Open Terminal , enter Telnet and open IP 445) which worked

I installed a trial of this on the Windows File Server which creates an AFP share , which worked by is 1000$!

https://www.acronis.com/en-au/mobility/mac-windows-compatibility/

We upgraded the Mac to the latest OS 10.14 ( for free )  and it solved the issues

GD Star Rating
loading...
GD Star Rating
loading...

Recently at a site we had machines starting using high CPU of the SVCHost process, this process is used by lots of services to access the network , however, as soon as stopping the Windows Update Service CPU came back down to normal

I had seen this before at another site and the issue was due to not enough CPU ( only one was flatlining the CPU )  , however increasing the CPU and memory still did not fix this

Then after some recent updates, the servers would no Windows Update anymore , they would just sit on “Checking for Windows Updates”. I couldn’t install updates Via powershell 

A server running Windows Server 2012 R2 on the same network updated fine!

I tried the normal fix of Wiping these : 

C:\Windows\SoftwareDistribution

HKEY_LOCAL_MACHINE\SOFTWARE\Policies\Microsoft\Windows\WindowsUpdate

HKEY_LOCAL_MACHINE\SOFTWARE\Microsoft\Windows\CurrentVersion\WindowsUpdate

However to no avail.

 

I checked the Windows Update Log : C:\Windows\WindowsUpdate.log

2019-04-23 14:09:51:839 5080 ab8 CltUI FATAL: CNetworkCostChangeHandler::RegisterForCostChangeNotifications: CoCreateInstance failed with error 80004002
2019-04-23 14:09:51:839 5080 ab8 CltUI WARNING: RegisterNetworkCostChangeNotification: Error 80004002

 

I then found an article to Remove the Desktop Experience Feature ( which had been installed to Disk Cleanup the servers ) 


After this I did this again and could windows update again

C:\Windows\SoftwareDistribution

HKEY_LOCAL_MACHINE\SOFTWARE\Policies\Microsoft\Windows\WindowsUpdate

HKEY_LOCAL_MACHINE\SOFTWARE\Microsoft\Windows\CurrentVersion\WindowsUpdate

 

Check also for Dual Scanning

 

In an elevated powershell prompt:

  • Get-WindowsUpdateLogThis will produce a log file on the desktop giving verbose detail on all of the windows update tasks performed recently.
  • (New-Object -ComObject “Microsoft.Update.ServiceManager”).Services | Select-Object Name, IsDefaultAUServiceThis will output all configured update sources, along with the default.If dual scanning is active, and the workstation is not checking in with WSUS, you might see Windows Update as the default, and WSUS as not default.
  • (New-Object -ComObject Microsoft.Update.AutoUpdate).DetectNow()This will trigger the computer to check in with the WSUS server – BUT if there are no new reports to add, it won’t send anything. If that is the case, then:
  • $updateSession = new-object -com “Microsoft.Update.Session”; $updates=$updateSession.CreateupdateSearcher().Search($criteria).UpdatesThis will force a status to be returned at next check in

Extra GPO settings to prevent Dual Scanning from hijacking the GPO and making the workstations go rogue – take note of setting the alternate download server to your WSUS server:

**Computer Configuration > Policies > Administrative Templates > System > Device Installation

Specify the search server for device driver source locations

Set to “Enabled”Select search order: “Do not search Windows Update”

Specify the search server for device driver updates

Set to “Enabled”Select Update Server: “Search Managed Server”

Computer Configuration > Policies > Administrative Templates > System > Internet Communication Management > Internet Communication Settings

Turn off access to all Windows Update features (In Microsoftspeak that means their online server, not ‘make so it can’t get updates’)

Set to “Enabled”

Turn off access to the Store

Set to “Enabled”

Computer Configuration > Policies > Administrative Templates > Windows Components > Windows Update

Do not allow update deferral policies to cause scans against Windows Update

Set to “Enabled”

No auto-restart with logged on users for scheduled automatic updates installations

Set to “Enabled”

Specify intranet Microsoft update service location (note that the alternate download server is also set to our own WSUS server)

Set to “Enabled”Set the intranet update service for detecting updates: [http://[YOUR%20SERVER]:8530]http://[YOUR SERVER]:8530Set the intranet statistics server:[http://[YOUR%20SERVER]:8530]http://[YOUR SERVER]:8530Set the alternate download server: [http://[YOUR%20SERVER]:8530]http://[YOUR SERVER]:8530Uncheck the box Download files with no Url in the metadata if alternate download server is set

 

GD Star Rating
loading...
GD Star Rating
loading...

All organizations should be using service accounts for Specific Tasks and Services, however, some legacy systems might not be. This script will search all servers listed in servers.txt and come back with any results with the username you search

#run this script as administrator
#create a servers.txt for all the servers you want to query
$Servers = Get-Content servers.txt
#add * infront and behind username for wildcard
$user = "*administrator*"

$findings = foreach ($computername in $Servers){

    $schtask = schtasks.exe /query /s $computername /V /FO CSV | ConvertFrom-Csv | Where { $_."Run As User" -like $user} | Select TaskName
    if ($schtask) {Write-Host "`nTask" + $computername + $schtask }
   
    $displayname = Get-WmiObject -class win32_service -computername $computername |where-object startname -like $user | Select displayname
    if ($displayname){Write-Host "`nService" + $computername + $displayname }
   
}

 

There’s a free tool with PDQ Inventory for Services

GD Star Rating
loading...
GD Star Rating
loading...

Great a Computer Configuration Group Policy Object for Windows Firewall per below

Whitelist the below files Inbound and Outbound

C:\program files\mimecast\mimecast windows service\msddsk.exe ( 32 bit ) 

C:\program files (x86)\mimecast\mimecast windows service\msddsk.exe  ( 64 bit ) 

GD Star Rating
loading...
GD Star Rating
loading...
<#
.SYNOPSIS
Install Desktop Experience for servers for disk cleanup.
#>


# V2 admin check
If (-NOT ([Security.Principal.WindowsPrincipal] [Security.Principal.WindowsIdentity]::GetCurrent()).IsInRole([Security.Principal.WindowsBuiltInRole] "Administrator"))
{
    Write-Warning "Please run this script as an Administrator!"
    Exit 1
}

[version]$OSVersion = [Environment]::OSVersion.Version

#check OS version
If ($OSVersion -gt "6.2") {
#server 2012 and above
   Install-WindowsFeature -Name Desktop-Experience
} ElseIf ($OSVersion -gt "6.1") {
#server 2008r2 and above
    Add-WindowsFeature -Name Desktop-Experience
} ElseIf ($OSVersion -gt "6.0") {
#server 2008 and above
    servermanagercmd.exe -install Desktop-Experience
} Else {
    write-host 'What OS Is this?'
}
GD Star Rating
loading...
GD Star Rating
loading...