Backtrack:  
 
showing all posts
edited by on September 11th 2015, at 10:39
This is a very crude script to defrag (using eseutil) Exchange mailbox databases.

The script takes the database name as a mandatory parameter. It then dismounts the database, checks whether the database state has been shutdown cleanly, performs the defrag, verifies the state again, and finally, mounts it again.

Note that this is an offline process. The specified mailbox database will be offline, meaning that all mailboxes in the database will not be accessible until the process has been completed.

Use with caution!
This script has not been tested extensively and does not account for everything that can go wrong. I merely provide it as a good starting point to extend the script to somethin  ...
edited by on September 11th 2015, at 10:32

You can redirect the output of a Powershell script to a file. This is called transcribing, and is very useful if you have some Powershell scripts as scheduled tasks and wish to log its output.

$ErrorActionPreference="SilentlyContinue"
Stop-Transcript | out-null
$ErrorActionPreference = "Continue"
Start-Transcript -Path "C:\transcript.log" -Append
#
# My script code goes here...
#
Stop-Transcript
edited by on September 11th 2015, at 10:15

There are two methods to specifically target 32-bit or 64-bit OS'es in group policies.

WMI filter

  • For x64 (64-bit):
    • Namespace: root\CIMv2
    • Query: SELECT * FROM Win32_Processor WHERE AddressWidth = '64'
  • For x86 (32-bit):
    • Namespace: root\CIMv2
    • Query: SELECT * FROM Win32_Processor WHERE AddressWidth = '32'

Environment variable

Another method is to check the value of the %Processor_Architecture% variable:

  • For x64 (64-bit): %Processor_Architecture% is AMD64
  • For x86 (32-bit): %Processor_Architecture% is x86
edited by on September 10th 2015, at 14:04
By default, Adobe Acrobat Reader DC is set to automatically download and install updates, and the ability to disable or configure automatic updates has been removed. But you can still configure/disable this through the registry in the following key:

Windows x86 (32-bit): HKEY_LOCAL_MACHINE\SOFTWARE\Adobe\Adobe ARM\Legacy\product name\product version

Windows x64 (64-bit): HKEY_LOCAL_MACHINE\SOFTWARE\Wow6432Node\Adobe\Adobe ARM\Legacy\product name\product version

Replace product name and product version accordingly. For example: Reader\{AC76BA86-7AD7-1043-7B44-AC0F074E4100}

Under the key, set the Mode DWORD value to one of the following:

0: Do not download or install updates automaticall  ...
edited by on September 10th 2015, at 13:10
Installation of certain Windows updates may fail to complete. Although the installation itself succeeds, the configuration part does not complete, and the changes are reverted, causing all updates to fail. When looking at the update history (Windows Update → View update history), the updates have failed with error code 0x800F0922:



The following updates are known to be affected by this, but there are probably others as well.

Windows 8/Server 2012: KB2756872, KB2770917, KB2955163

Windows 8.1/Server 2012 R2: KB2919355

The affected updates fail to install because the System Reserved partition (not the C:-drive) is full or nearly full.

In my case, a log file in the System Volume Infor  ...
edited by on September 10th 2015, at 11:30
If you are running a non-en-US Windows 10, and wish to install Remote Server Administration Tools for Windows 10, you may notice the install does not succeed.

The installation of RSAT finishes after about 5-10 seconds, claiming it has been installed successfully. However, the RSAT tools are nowhere to be found, and update history does not show KB2693643 to be installed.

Attempting to install RSAT through Dism.exe fails with error : 0x800f081e

Dism.exe /Online /Add-Package /PackagePath:WindowsTH-KB2693643-x64.cabDeployment Image Servicing and Management toolVersion: 10.0.10240.16384Image Version: 10.0.10240.16384Processing 1 of 1 - Adding package Microsoft-Windows-RemoteServerAdministrati  ...
edited by on September 9th 2015, at 11:43
RSAT for...Fully supported server OSDownload
Windows 102012 R2 and belowDownload
Windows 8.1 2012 R2 and belowDownload
Windows 8 2012 and below Download
Windows 7 SP12008 R2Download

A newer RSAT version is always backwards compatible with older server OS versions. For example, all Windows versions from 2012 R2 and below are fully supported by RSAT for Windows 10.

Older RSAT versions can manage newer server OS versions, but only features that are also present in older OS versions can be managed properly. For example, RSAT for Windows 7 partially supports 2012 R2: features that are present on 2008 R2 can be managed, but features unique to 2012 or 2012 R2 cannot).

edited by on September 9th 2015, at 10:50

The Handpresso, a handheld espresso machine, for use on the road.

This should be standard issue in every corporate car...

If you want it, you can purchase it here

edited by on September 8th 2015, at 11:20
When installing a lot of Windows updates, or a few very large updates (such as a service pack or KB2919355), the updates may fail and the system may revert the changes. If that happens, check the Windows Update history (Windows Update → View update history), and view the details of the failed updates.



If the error code is 0x800F0922, verify whether there's still enough free disk space available on the system drive (C:-drive). If the volume is almost full, there may be enough to download updates, but not enough to actually install them. Aside of the downloaded packages, the unpacking and installation of updates, additional space is needed for system restore points and the old versions  ...
edited by on September 8th 2015, at 09:44
If Windows Update mysteriously fails to install updates, it may become necessary to completely clear the Windows Update cache. This resets the state of updates, removes downloaded files and requires Windows Update to completely re-analyze your system to figure out what updates are required.

The procedure is non-invasive and can be performed on workstations and servers alike and without downtime.

Open an elevated command prompt.

Stop the Windows Update service: net stop wuauserv



Remove the SoftwareDistribution folder, containing the complete cache and downloads: From the command prompt: cd /d %windir%rd /s SoftwareDistribution

Or, remove the folder through Windows Explorer.

Start the   ...
edited by on September 4th 2015, at 13:57

The Microsoft File Checksum Integrity Verifier (fciv.exe) is a command line tool you can use to calculate MD5 and SHA1 hashes for files.

http://www.microsoft.com/download/details.aspx?id=11533

It is a suitable alternative to linux's md5sum, and eliminates the need for third party tools or Cygwin.

edited by on September 4th 2015, at 12:04
If your management servers have their System Center Data Access Service (SDK/DAS service) running as a domain service account, you may get the following error each time the management server(s) or SDK/DAS service is restarted, even though all SPNs are correctly registered:

Alert Description
Source: Data Access Service - SCOM01.contoso.com
Full Path Name: SCOM01.contoso.comData Access Service - SCOM01.contoso.com
Alert Rule: Data Access Service SPN Registration
Created: 26/08/2015 15:43:06

The System Center Data Access service failed to register an SPN. A domain admin needs to add MSOMSdkSvc/SCOM01 and MSOMSdkSvc/SCOM01.contoso.com to the servicePrincipalName of CN=SCOM01,OU=Users,DC=co  ...
edited by on September 4th 2015, at 11:23
You may encounter the following alert if SCOM's System Center Data Access Service is (re)started:

Alert Description
Source: Data Access Service - SCOM01.contoso.com
Full Path Name: SCOM01.contoso.com\Data Access Service - SCOM01.contoso.com
Alert Rule: Data Access Service SPN Registration
Created: 26/08/2015 15:43:06

The System Center Data Access service failed to register an SPN. A domain admin needs to add MSOMSdkSvc/SCOM01 and MSOMSdkSvc/SCOM01.contoso.com to the servicePrincipalName of CN=S_scom_das,OU=Users,DC=contoso,DC=com

This alert is logged if the required SPNs for the SDK/DAS service (OMSDK service) are not present, and the account running the service is unable to create th  ...
edited by on September 4th 2015, at 09:25
Often overlooked during the installation of a Microsoft SQL Server is the creating of the required Service Principal Name(s) (SPN) to enable authentication through Kerberos. SCOM highlights this oversight nicely with this warning:

Alert Description
SQL Server cannot authenticate using Kerberos because the Service Principal Name (SPN) is missing, misplaced, or duplicated.
Service Account: CONTOSO\s_clsql_sqlsrv_de
Missing SPNs: MSSQLSvc/CLSQL01.contoso.com:MSSQL, MSSQLSvc/CLSQL01.contoso.com:1433
Misplaced SPNs:
Duplicate SPNs:

The solution is simple: create the SPNs. All the info you need is actually in the alert's description. Use the information to create the SPNs.

Log on to a domain   ...
edited by on September 3rd 2015, at 14:08
The internal health monitoring system may report Unhealthy, and an error similar to the following is reported by SCOM:

Alert: {2} Resolution state: New
Alert: {2}
Source: EXCH02 - Compliance
Path: EXCH02.contoso.com;EXCH02.contoso.com
Last modified by: System
Last modified time: 9/3/2015 11:43:37 AM Alert description: EMSMDB.DoRpc(Logon) step of ComplianceOutlookLogonToArchiveRpcCtpProbe/EXCHDB03 has failed against EXCH02.contoso.com proxying to Unknown for HealthMailbox8414258ad6574db1ad62eb67e94b9d6d@contoso.com.
Latency: 00:00:00.9250000
ActivityContext:
.
.
.
Details:
Error: Error returned in LogonCallResult. Error code = WrongServer (0x00000478)
Log: RpcProxy connectivity verification  ...
edited by on September 3rd 2015, at 11:05
Run the following T-SQL statements.

Show a list of longest running SPIDs on a SQL Server:

select P.spid, right(convert(varchar, dateadd(ms, datediff(ms, P.last_batch, getdate()), '1900-01-01'), 121), 12) as 'batch_duration', P.program_name, P.hostname, P.loginamefrom master.dbo.sysprocesses Pwhere P.spid > 50and P.status not in ('background', 'sleeping')and P.cmd not in ('AWAITING COMMAND' ,'MIRROR HANDLER' ,'LAZY WRITER' ,'CHECKPOINT SLEEP' ,'RA MANAGER')order by batch_duration desc

To retrieve the SQL for a specific SPID:

declare @spid int, @stmt_start int, @s  ...
edited by on September 3rd 2015, at 10:58
If you have configured Blackberry Enterprise Server to use EWS for calendar access and free/busy information lookup, you may encounter the following errors in the logs of the BES server:

BES01_CALH_01_<date>.log
[20751] (03/26 00:03:31.030):{0x1CE4} {TestUser@example.com} WSUser::SetUser - Failed to create EWS::Service: HRESULT 80040154, EWS.DLL possibly not registered or mismatched in version

BES01_MAGT_01_<date>.log
[30000] (08/31 17:19:04.565):{0x24C} {Agent Startup}-CalHelperController::InitializeEws- COM Exception: Code = 80004003, WCode = 0000, Code meaning = Invalid pointer, Source = <none>
[30000] (08/31 17:19:04.565):{0x24C} {Agent Startup}-CalHelperController::I  ...
edited by on September 3rd 2015, at 10:48
When running Blackberry Enterprise Server (BES) 5.0.4 in an environment with users whose mailboxes are located on Exchange 2013 servers, you may encounter the following problem: certain, but not all users lose their connectivity on their mobile devices. They can no longer send or receive e-mail, calendar, contacts.

When looking at the event viewer, an application crash is logged:

Event 1000 Application Error
Faulting application name: BlackBerryAgent.exe, version: 5.0.4.17, time stamp: 0x502e604b
Faulting module name: exmapi32.dll, version: 6.5.8320.0, time stamp: 0x517e1c40
Exception code: 0xc0000005
Fault offset: 0x00010188
Faulting process id: 0x1fbc
Faulting application start time: 0x0  ...
edited by on September 2nd 2015, at 17:02
Exchange 2013 uses Managed Availability to monitor its own health. One part of this monitoring is achieved through the use of synthetic transactions, mimicking regular user activity, such as accessing mailboxes, send/receive e-mail, etc. For this to work properly, the monitoring system uses so-called Health Mailboxes. These are just regular mailboxes (with a regular AD account), but are created automatically and used for the sole purpose of health monitoring. Depending on the CU-version of Exchange 2013, these are created for every database on every CAS (or just one per CAS and one per database, starting from CU6).

Sometimes, these mailboxes may become corrupt or unusable, in which case the  ...
edited by on September 2nd 2015, at 16:29
If you notice that SCOM is not properly discovering services on a particular server (e.g. it does not detect the presence of Exchange), you can resolve this by clearing the cache of the agent on the server. This will trigger a new full discovery, and the agent should now be able to detect the new services:

Log on the server of which services are not discovered properly.

Stop the agent (System Center Management service): net stop HealthService



Delete the contents of the Health Service State folder, located in the installation folder of the agent.
(default location: %PROGRAMFILES%\System Center Operations Manager\Agent).

Start the agent again (System Center Management service): net start  ...
showing all posts