How to use the Exchange 2007/2003 Address Rewrite Feature

How to use the Exchange 2007/2003 Address Rewrite Feature

by

Marc Grote

[Published on 24 May 2007

/

Last Updated on 24 May 2007]

Why the Exchange Address Rewrite feature might be necessary in your Exchange Server environments.

In this article I will show you how to use the Exchange Server Address Rewrite feature. This feature allows Exchange Administrators to centrally rewrite outgoing SMTP addresses. Exchange Server Address Rewrite is available as an additional tool for Exchange Server 2003 which can be downloaded for free at the Microsoft website. In Exchange Server 2007, Address rewrite is natively integrated into the core messaging system in the form of Exchange Management Shell CMD’lets.

Let’s begin

This article briefly explains why the Exchange Address Rewrite feature could be necessary in your Exchange Server environment. Address Rewrite is mostly focused on Exchange Server 2007 but I will also explain the Exarcfg tool for Exchange Server 2003.

What is Exchange Address Rewrite?

Exchange Address Rewrite is the process of rewriting e-mail addresses for all outgoing messages on a special SMTP virtual server (true for Exchange Server 2003). Exchange Address Rewrite is especially used in merger or acquisition scenarios where two Exchange organizations are to be merged into one but, until these two organizations are completely merged, every organization uses its own SMTP namespace while for all outgoing SMTP messages the new or unique SMTP address space is used.

One example:

NWtraders has acquired Contoso and for a limited time, until the acquisition is finalized, all users of Contoso should use the SMTP E-mail address space of NWTraders for outgoing messages.

There are some steps to perform when you enable Address Rewrite. If you would like to use this feature you must perform the following steps:

  • Enable Address Rewrite for all outgoing messages for users of the Contoso Exchange organization
  • Create contacts in Active Directory for all Contoso Mail enabled users with a target SMTP address for Contoso and a primary SMTP address for NWtraders
  • Create an SMTP connector with an address space of Contoso
  • Enable Address Rewrite on the corresponding Exchange SMTP virtual Servers

Exchange Address Rewirte requires that the following work properly:

  • All SMTP messages must be externally submitted through the Exchange Bridgehead server
  • All SMTP messages must be sent to the Internet

Please note:
Exchange Address Rewrite is NOT used for sending internal E-Mails from one Exchange Server to another in your Exchange Organization. There is one exception from this rule: All native SMTP clients like Mozilla, Thunderbird or Microsoft Outlook Express use Exchange Address Rewite because these messages will be sent directly to the SMTP driver.



Downloading and Installing Exchange Address Rewrite

Because Exchange Server 2003 has no native integration with Exchange Address Rewrite, you must download the Address Rewrite tool called EXARCFG.EXE from the Microsoft website. You will find the download link at the end of this article.

After downloading the tool, simply extract the download package and open a command prompt to use the EXARCFG tool, as shown in the following screenshot.


Figure 1: Exarcfg Syntax

The parameters are self explanatory and require only a little attention.

The EXARCFG parameter –E enables Address Rewrite while the parameter –D disables Exchange Address Rewrite. The only parameter you should pay more attention to is the –V parameter which specifies which Exchange Virtual SMTP Server should be used.


Figure 2: Enabling Exarcfg for the Exchange Server London.nwtraders.msft

These were the necessary steps for using Exchange Address Rewrite in Exchange Server 2003. Using Exchange Address Rewrite in Exchange Server 2007 is a bit different from Exchange Server 2003.

Exchange Address Rewrite in Exchange Server 2007

Exchange Address Rewrite in Exchange Server 2007 is already installed with the core messaging subsystem but is not enabled. You have to use the Exchange Management Shell to activate Exchange Address Rewrite.

One other new feature of Exchange Address Rewrite in Exchange Server 2007 is that you can enable this feature on a per user, SMTP domain and/or SMTP subdomain base and not for the whole Exchange 2003 Virtual SMTP Server as in Exchange Server 2003.

You configure Address Rewriting agents on the SMTP receive connector and send connector on a computer that has the Edge Transport server role installed.

Please note:
The Exchange Server 2007 Address Rewrite Agent is only available on Edge Transport servers.

Enumerating Installed Transport Agents

The following Exchange Management Shell CMD’lets show the installed Transport Agents on a Hub Transport Server. As you can see there is no Transport Agent for the Address Rewrite feature.


Figure 3: Installed Transport Agents on Hub Transport Server

When you start the Exchange Management Shell CMD’let to enumerate the Exchange 2007 Transport Agents on a Exchange 2007 Edge Transport Server, you can see the Transport Agent for Incoming and Outgoing SMTP message transfer.


Figure 4: Installed Transport Agents on Edge Transport Server

Display Exchange Server 2007 Address Rewrite Entries

If you would like to see for which users, Domains or subdomains Address Rewrite is enabled, start the Exchange Management Shell CMD’let from the following screenshot.


Figure 5: Display installed Address Rewrite entries

With Exchange Server 2007 Address Rewrite you can rewrite SMTP addresses based on:

  • Single Address
  • Single Domain
  • Multiple Subdomains

How to enable Address Rewrite for a Single Address

New-AddressRewriteEntry -name “grotem@it-training-grote.de to grotem@telta.de” -InternalAddress grotem@it-training-grote.de -ExternalAddress grotem@telta.de Single Domain

How to enable Address Rewrite for a Single domain

New-AddressRewriteEntry -name “IT TRAINIHG GROTE to TELTA” -InternalAddress it-training-grote.de -ExternalAddress telta.de

How to display Address Rewrite entries after configuring some entries

You have to use the Exchange Management Shell to display configured Address Rewrite entries as shown in the following screenshot.


Figure 6: Display installed Address Rewrite entries

What SMTP Header fields are rewritten and which are not?

Exchange Server 2007 Address Rewrite doesn’t rewrite all the SMTP Header fields. The following table from Microsoft lists the SMTP Header fields that are rewritten for inbound or outbound messages.

SMTP Header field

Outbound

Inbound

Envelope From (MAIL FROM) Rewritten Not rewritten
Envelope To (RCPT TO) Not rewritten Rewritten
Body To Rewritten Not rewritten
Body Cc Rewritten Not rewritten
Body From Rewritten Not rewritten
Body Sender Rewritten Not rewritten
Body Reply-To Rewritten Not rewritten
Body Return-Receipt-To Rewritten Not rewritten
Body Disposition-Notification-To Rewritten Not rewritten
Body Resent-From Rewritten Not rewritten
Body Resent-Sender Rewritten Not rewritten

Table 1: SMTP Header fields that are rewritten and those that are not with Exchange Server 2007 Address Rewrite

Conclusion

Exchange Server 2003/2007 Address Rewrite is a great tool that rewrites SMTP addresses and is especially useful in Exchange environments within a merger or acquisition scenario. You should carefully plan the implementation of Exchange Address Rewrite. Setting up Exchange Address Rewrite is really simple but the underlying organizational process should be carefully considered.

Related Links

Exarcfg Download

Planning for Address Rewriting

Overview of the Exchange Server 2003 Resource Kit Tools

Supporting Two SMTP Mail Domains and Sharing an SMTP Mail Domain with Another System

How to create a new Address Rewrite Entry

Hub Transport Servers in Exchange Server 2007

Notes

ESXi 5.1 ASRock Z77 Broadcom Nic Drivers

Broadcom network card drivers
[ source: The Broadcom BCM57781, ASRock Z77 Extreme 4, and You ]

  1. Download the broadcom driver (vmware download) or broadcom driver (local download).
  2. Download ESXi-Customizer.
  3. Run ESXi-Customizer.cmd, select the ESXi iso you’d like to modify (instructions are for 5.0 u1 but 5.1 works also), the broadcom driver zip and save the iso.
  4. Use unetbootin to create the bootable usb key

After you run through the ESXi install, if you have a DHCP server on the network, you’ll now get an IP assignment.

ESXi 5.1 – Boot from USB

ESXi 5.1 – Boot from USB

ESXi 5 Boot from USB

1.    Download UNetbootin from http://unetbootin.sourceforge.net/

2.    Run it and select the below options

  • a.    Diskimage
  • b.    ISO
  • c.    Drive (Drive letter of connected USB)

 

 

 

 

 

 

 

 

 

3.    Boot drive is getting created

 

 

 

 

 

 

 

 

 

4.    Boot disk creation completed

 

 

 

 

 

 

 

 

 

5.    Boot the Machine with this boot disk, and select Boot from USB in boot manager.

6.    Voila, ESXi  5.x Screen

 

 

 

 

 

 

 

 

 

Thanks for Griffon for his link.

Direct Booking using Outlook 2010 against Exchange 2003 Server

Direct Booking using Outlook 2010 against Exchange 2003 Servers

Rate This
  • Comments 0

Now that Office 2010 has RTM’ed, we’ve started to see a number of issues pop up where customers are finding that they are having problems reserving a conference room using it.  The reason is that Outlook 2010 by default has Direct Booking disabled.  This is by design since Direct Booking is the old Exchange 2003 way of doing things and Exchange 2007 and 2010 has automatic processing of resource mailboxes.

If you are still on Exchange 2003, however, you may have the need to enable Direct Booking for your clients.  In order to enable it in Outlook 2010 you will need to add the following DWord in the registry for the organizers client:

Key: HKEY_CURRENT_USERSoftwareMicrosoftOffice14.0OutlookOptionsCalendar

DWORD: EnableDirectBooking

Value: 1

Hope that helps some people out.

Notes

ESXi How to backup restore the host configuration with powercli

ESXi How to backup restore the host configuration with powercli

    Why powercli?
    A lot of what I’ve seen out there for backing up the host configuration uses VMA or Vcli but I use powercli more consistently as I know a lot of other people do also.

    Here is the code to backup your esxi host via powercli

    Get-VMHostFirmware -VMHost $host -BackupConfiguration -DestinationPath C:DownloadFolder
    Set-VMHostFirmware -VMHost $Host -Restore -SourcePath c:bundleToRestore.tgz -HostUser user -HostPassword pass

    *note: that the backup config files can be restored only to the same version of esxi and same build.
    I havent tested otherwise but posts on different blogs confirm that.

    Pre-backup evidence
    Test host: before backing up
    Here are some configs that I want to see go over after restoring

    Backing up the config
    Connect to your host/vcenter first

    Using:
    Get-VMHostFirmware -VMHost $host -BackupConfiguration -DestinationPath C:Downloads

    Here is what is backed up, its tiny!

    Installing ESXi

    Here is the new install booting from dhcp

    Restoring Using:
    Set-VMHost -VMHost Host -State ‘Maintenance’

    Set-VMHostFirmware -VMHost Host -Restore -SourcePath c:bundleToRestore.tgz -HostUser user -HostPassword pass

    Connected to esxi host
    Place into maintenance mode

    I had to use the force optionotherwise I was getting  Restore failed: fault.MismatchedBundle.summary

    Server came up by itself:
    Here is the console

    Here are the settings in the vmware client

    Looks like I will have to add the nic manually to the switch labeled vswitch1

    It knows the NTP time setting

    Conclusion:
    It can be a great timesaver if you have a lot of settings to redo.

    *notes:
    *Note was readig that  this cant be used to restore the config to a different system because you will get a fault.MismatchedBundle.summary because the nic macs are different
    I havent tried that with the force option so it might work…..

Notes

find the 25 largest files on your linux harddisk

find the 25 largest files on your linux harddisk

ever wondered where all your harddisk space went?

hit this: (tested on debian)

du -a / | sort -n -r | head -n 25

example output:

du: cannot access `/proc/1245/task/1245/fd/4′: No such file or directory
du: cannot access `/proc/1245/task/1245/fdinfo/4′: No such file or directory
du: cannot access `/proc/1245/fd/4′: No such file or directory
du: cannot access `/proc/1245/fdinfo/4′: No such file or directory
45746884    /
44448916    /opt
44448912    /opt/kerio
44448908    /opt/kerio/mailserver
44215540    /opt/kerio/mailserver/store
27005076    /opt/kerio/mailserver/store/logs
25928000    /opt/kerio/mailserver/store/logs/error.log
13029208    /opt/kerio/mailserver/store/backup
3409084    /opt/kerio/mailserver/store/mail
1922948    /opt/kerio/mailserver/store/backup/F20121216T000004Z.zip
1898332    /opt/kerio/mailserver/store/backup/F20121209T000000Z.zip
1862128    /opt/kerio/mailserver/store/backup/F20121230T000006Z.zip

Notes

Windows 2003 upload size limit – error 800a0001

Windows 2003 upload size limit – error 800a0001

Problem Description

Windows 2003 by default limits upload sizes to 200 KB for ASP pages. With AspUpload, this usually manifests as an error such as these:

Persits.Upload.1 error ‘ 800a0001 ‘
Request.BinaryRead Failed.

Persits.Upload.1 error ( 0x800a0001 )
Unspecified error

Solution

IIS 6.0 on Windows 2003 has a file named metabase.xml which resides in the folder C:Windowssystem32inetsrv . By default, this file has this entry:

AspMaxRequestEntityAllowed = “204800″

This limits upload size to 204,800 bytes. You can change that to a large value (such as 2000000000for 2 gigabytes) to allow your Windows 2003 server to accept large uploads.

If your server does not allow the Metabase Edit-While-Running feature, you will need to stop the IIS service before you can save the metabase.xml file.

Notes

PHD Virtual 6.1 – Using VM Replication

Using VM Replication

There are multiple scenarios in which VM Replication can be used. At a minimum, a single PHD VBA can be used in one virtual environment to replicate VMs from one host to another. This is done by creating backups for your VMs, then creating replication jobs that will create replicas of those VMs on another host in the same virtual environment.

Figure E – 1. Using a single PHD VBA to replicate VMs within the same virtual environment.

When using a DR site, you could deploy another PHD VBA to that site to run your replication jobs. In this scenario, the PHD VBA at the DR site would be configured to connect to the primary site’s backup storage directly, then use that data to create the replica VMs on the hosts at the DR site. Then as backups are created at the primary site each night, replicas can be updated with the changed data from each backup.

Figure E – 2. Replicating VMs from a primary site to a DR site.

Prerequisites

Before replicating VMs, you must have at least one PHD Virtual Backup VBA deployed and running regular backups. These backups can be stored on any supported backup data storage (attached virtual disk, a CIFS share, or an NFS share). Note that if an attached virtual disk is used, it must be shared in order to be used for replication. For details, see Connectors tab

In addition, a stable network connection must exist between any primary and secondary locations in order to transfer replicated data.

After establishing your regular backups, you will create replication jobs to run after the backups have finished to replicate any changes.

Step 1: Deploy/Configure a PHD VBA for Replication

If you will be using a DR site, the first step to configuring replication requires that you deploy a new PHD VBA to your secondary location. This is the location where you will be replicating VMs to (the “DR site” in the image above). The PHD VBA deployed here will read the data from your primary site’s backup location then use that data to create replica VMs. Follow the instructions in the PHD Virtual Backup Installation Guide to deploy a new PHD VBA.

After deciding which PHD VBA will be used to perform the replication, it will need to be configured. Open the PHD Console and connect to the location where your replication PHD VBA is deployed. In the Configuration area, configure the hypervisor credentials (if it is a new PHD VBA) on the General tab (refer to the Installation Guide for additional detailed deployment and configuration instructions).

Next, click the Replication tab. This is where you will add backup storage locations to be used with replication.

Click Add to add a backup storage location. These can be backup storage locations used by another PHD VBA (at your primary site, for example) or the current PHD VBA’s backup storage. Add all of the backup storage locations from which you want to replicate VMs.

After entering the required information and clicking OK, the storage location is displayed in the list, as seen in the following image.

You can automatically discover any backup storage for all PHD VBAs in your environment, by clicking Discover. More information about the Replication tab is in the section Replication tab.

Step 2: Create VM Replication Jobs

After adding the storage locations you will use for creating replica VMs, you will next use the Create Replication Job wizard to create your replication jobs. The wizard can be opened from the Jobs area of the PHD Console, or from the Replication area.

From the Replication area, in the Virtual Machines Available for Replication tab, you can see all of the VMs available for replication. This list of VMs represents all of the VM backups available on the storage locations you added in the previous step.

At this point, you can select the VMs you want to replicate then click Replicate to open the Create Replication Job wizard. Follow the steps in the wizard to create the replication job. For details, see Using the Create Replication Job Wizard.

Tip:    Replication takes advantage of existing backups to create and update replica VMs. Therefore, some consideration should be given to when your replication jobs are scheduled to run. If possible, replication jobs should be set to run after your nightly backups complete, to ensure your replicas are up to date with the latest changes.

After the job is created, it is stored in the Jobs area of the PHD Console, as seen in the following image.

Step 3: Run Replication Jobs and Manage Replicas

When a Replication Job runs, either scheduled or if manually started, VMs are replicated to the location you specified. If you view the Replicated Virtual Machines tab in the Replication area of the PHD Console, you will see all of the VMs that have been created.

Note:    Only one replica VM can be created per hypervisor environment (per vCenter or host). For example, if you create a replica of VM1 on host1 and VM1 is also included in a second replication job replicating to that same host, when the job runs, the original replica will be found and no new replica will be created. A warning stating the replica already exists will be logged and included in the email report when the job completes.

From the Replicated Virtual Machines tab, you can see the status of each replica VM and select them for either testing or failover. For additional information about testing replicas and failover, refer to the following sections.

Replication Notes

  • When the virtual disks of a replicated VM change, for example, if a disk is added or removed, or if a disk’s size is altered, the next replication job will include a warning and any changed disks will not be replicated. In order to include virtual disk changes to your VMs, you will need to remove the existing replica and then either edit or create a new replication job to make sure any disk changes are included. You can verify changes are included by viewing the VM in the View/Edit step of the Replication wizard.
  • VM configuration settings are not updated after the initial replication takes place. For example, if you replicate a VM that was configured to use 1 GB of memory, the replica VM will be configured with the same value. If you then change the size of the memory on the source VM, the replica VM will still have the original 1 GB value. To update the replica, you can either manually change the settings on the replica VM, or delete the replica VM and let the replication job create a new full replica the next time the job runs. This also applies to the replica’s configuration settings – if you change a setting on the replica, it will not be overwritten by incremental changes applied during a replication job.
  • The list of VMs available for replication is automatically synchronized with the configured backup storage locations every five minutes. You can force synchronization by clicking refresh on the Replication page of the PHD Console.

Notes

“Help and Support” is missing after you upgrade to Windows Server 2003 Service Pack 2

To resolve this problem, reinstall the Help and Support service. To do this, follow these steps:
  1. Click Start, click Run, type cmd in the Open box, and then click OK.
  2. At the command prompt, locate the following folder:
    %windir%PCHealthHelpCtrBinaries
  3. At the command prompt, type the following commands, and then press ENTER after each command:
    • HelpSvc.exe /regserver /svchost netsvcs /RAInstall
    • HSCUpd.exe -i hscmui.cab
    • HSCUpd.exe -i hscsp_s3.cab

      Note The following commands do not apply to some language versions of Windows Server 2003:

      • HSCUpd.exe -i hscmui.cab
      • HSCUpd.exe -i hscsp_s3.cab

      The reason is that the Hscmui.cab compressed file is not included in some language versions of Windows Server 2003, such as the Japanese version of Windows Server 2003.

Notes

Clean Up C:WindowsInstaller

Clean Up C:WindowsInstaller

If you have a Windows computer that’s been around for awhile, you may have noticed that your free disk space has gotten kind of low, lower than you would expect. WinDirStat is a great little utility to figure out where that space is going. If you use that program, you might discover that C:WindowsInstaller is really big. Sometimes that directory is not as clean as it should be because of various failed program installations or unclean uninstalls.

Use the Windows Installer Cleanup Utility to safely get rid of the unneeded cruft. Download the installer here. Once installed, open up a command prompt and type:

cd "Program FilesWindows Installer Clean Up"msizap G!

In one case that I saw, 7 GB was reduced down to about 1.5 GB.

I do not recommend using the other utility included with the installer unless told to do so elsewhere. This is the utility that you will see a new entry for in the Programs menu and is not a command line program. Its purpose is not related to the one this post is written about.

If you see an error message like:

MsiZapInfo: Performing operations for user S-1-5-21-…..
Removing orphaned cached files.
Error opening 9040110900063D11……InstallProperties subkey of Products key for S-1-5-18 user. Error: 2.
FAILED to clear all data.

don’t worry about it. The program has finished cleaning up all it can. If you’re bothered by it and know your way around the Windows Registry, you’ll find the GUID listed somewhere under HKEY_LOCAL_MACHINESOFTWAREMicrosoftWindowsCurrentVersionInstallerUserData. If you’re sure it refers to something you’ve uninstalled already, go ahead and delete the key, run ‘msizap G!’ again and you shouldn’t see the error message anymore.

(Note: I am aware this information is already available online elsewhere in some for or other, but I found it to be somewhat scattered and confusing.)

Notes