Logging SMTP Protocol Activity in Exchange 2007 / 2010

Enable protocol logging on a Receive Connector

Set-ReceiveConnector “Connector Name” -ProtocolLoggingLevel verbose

Receive Connector logs default path:

  • Exchange 2010: \Exchange Server\V14\TransportRoles\Logs\ProtocolLog\SmtpReceive
  • Exchange 2007: \Exchange Server\TransportRoles\Logs\ProtocolLog\SmtpReceive

To change:

Set-TransportServer “TRANSPORT SERVER NAME” -ReceiveProtocolLogPath “C:\Directory”

Enable protocol logging on a Send Connector

Set-SendConnector “Send Connector Name” -ProtocolLoggingLevel verbose

Send Connector logs default path:

  • Exchange 2010: \Exchange Server\V14\TransportRoles\Logs\ProtocolLog\SmtpSend
  • Exchange 2007: \Exchange Server\TransportRoles\Logs\ProtocolLog\SmtpSend

To change:

 Set-TransportServer “TRANSPORT SERVER NAME” -SendProtocolLogPath “C:\Directory”

Remove Lync 2010 system from AD (with orphaned servers)

1., Remove the following Groups from Active Directory :

CSAdministrator
CSArchivingAdministrator
CSHelpDesk
CSLocationAdministrator
CSResponseGroupAdministrator
CSServerAdministrator
CSUserAdministrator
CSViewOnlyAdministrator
CSVoiceAdministrator
RTCComponentUniversalServices
RTCHSUniversalServices
RTCProxyUniversalServices
RTCSBAUniversalServices
RTCUniversalConfigReplicator
RTCUniversalGlobalReadOnlyGroup
RTCUniversalGlobalWriteGroup
RTCUniversalReadOnlyAdmins
RTCUniversalSBATechnicians
RTCUniversalServerAdmins
RTCUniversalServerReadOnlyGroup
RTCUniversalUserAdmins
RTCUniversalUserReadOnlyGroup

2., Run ADSIEDIT and connect to the Configuration naming context.  Browse down to Configuration -> Services -> RTC Service and then delete the entire RTC Service container.

3., Also delete the Computer object(s) for any Lync Server you had previously installed.

How to View / Disconnect Remote Desktop Sessions from remote Commandline

I used to receive the maximum number of connections error message when I try to log on to the Windows Server in Windows Remote Desktop.

Open the command prompt on the client computer as a domain Admin user.

You will get a list of the Remote Sessions in the command window:

qwinsta /server:SERVERIP

Command line to disconnect the remote session:

rwinsta SESSIONID /server:SERVERIP 

An error while installing SQL Server (express) 2008 R2

Error text:

“************** Exception Text **************
System.Configuration.ConfigurationErrorsException: An error occurred creating the configuration section handler for userSettings/Microsoft.SqlServer.Configuration.LandingPage.Properties.Settings: Could not load file or assembly ‘System, Version=4.0.0.0, Culture=neutral, PublicKeyToken=……”

Caused by a LandingPage.exe error. It couldn’t bind to System assembly. Delete files from (users_profile)\AppData\Local\Microsoft_Corporation directory.

 

Exchange max e-mail size settings

1. Organization Configuration:

Organization Configuration | Hub Transport | Global Settings tab | Transport Settings

2. Server Configuration:

Server Configuration | Hub Transport | select a HT server | Receive Connectors -> select a connector | Properties

3. Send Connector Configuration

Organization Configuration | Hub Transport | Send Connectors -> select connector | Properties

4. Recipients Configuration:

Recipients Configuration | Mailbox | select mailbox | properties | Mail Flow Settings | Message Size Restrictions

5. Recipients Group Configuration:

Recipients Configuration |Distribution Group | select Group | properties | Mail Flow Settings | Message Size Restrictions

6. Global Setting in ADSIEdit:

Configuration container | Services | Microsoft Exchange |YourOrgName| Global Settings | Message Delivery | Properties

7. Transport Rules:

Organization Configuration | Hub Transport | Transport Rules

 

Event 1202 with status 0x534 logged on Windows Server 2008 R2 domain controllers after modifying security policy

When modifying any security setting in the Default Domain Controllers Policy using the Group Policy Management Console (GPMC) from the console of a Windows Server 2008 R2 domain controller, GPMC incorrectly translates the SID for the Wdiservice account in the policy to a user name which is not recognized by the local machines where the policy is enforced.

This issue also occurs when a Windows 7 or Windows Server 2008 R2 member computer modifies any security setting in the Default Domain Controllers Policy on a Windows Server 2008 R2 domain controller.

Edit the %SystemRoot%\Sysvol\domain\Policies\{6AC1786C-016F-11D2-945F-00C04fB984F9}\MACHINE\Microsoft\Windows NT\SecEdit\GPTTMPL.INF file:

Replace the value of a SeSystemProfilePrivilege: *S-1-5-32-544,NT Service\WdiServiceHost (initial value: *S-1-5-32-544,WdiServiceHost).

If you use IIS on server:
Add the “IIS AppPool\” prefix to ‘DefaultAppPool’ and ‘Classic .NET AppPool’ object.