Deployment on Server Core
This article contains information on how to deploy CodeTwo Email Signatures On-prem on the Server Core version of Windows Server. The program needs to be deployed on an Exchange server with the Mailbox server role installed. Since Server Core has no graphical user interface (GUI), only the basic components of CodeTwo Email Signatures On-prem, necessary to relay emails through the program, are installed. This means that to configure and manage email rules, edit program settings, or use other features of the program, you need to install the Administration Panel of CodeTwo Email Signatures On-prem, which requires a GUI to be managed. The Administration Panel needs to be installed on a client machine (not Core) from a standard EXE installer. For instructions on how to perform a standard installation of CodeTwo Email Signatures On-prem, refer to this article.
Download
Before you proceed, be sure to download the Server Core version of CodeTwo Email Signatures On-prem.
Follow the links below to learn how to:
- install CodeTwo Email Signatures On-prem on Server Core
- uninstall the program from Server Core
- update the Server Core version of CodeTwo Email Signatures On-prem
- install the CodeTwo Exchange Transport Agent manually on Server Core
- uninstall the CodeTwo Exchange Transport Agent manually from Server Core
How to install CodeTwo Email Signatures On-prem on Server Core
Follow the steps below to install the software on the Server Core version of Windows Server. As a result, the following components will be installed on Server Core:
- CodeTwo Email Signatures On-prem Services:
- CodeTwo App Monitor
- CodeTwo Mail Processor
- CodeTwo Sent Items Update
- CodeTwo Exchange Transport Agent
- the licensing module.
- Run the Command Prompt (cmd.exe).
- In the Command Prompt, in order to install CodeTwo Email Signatures On-prem Services services, run the EmailSignaturesOnPremSetupEN.msi file with the following parameters:
- /quiet
- ACTION="INSTALL"
- EXCHANGE_VERSION="<value>" – this parameter determines the version of Exchange server that is installed on your machine. The value can be, for example: SE or 2019.
- CORE="1" – this parameter determines a Server-Core-specific installation of CodeTwo Email Signatures On-prem. Setting the value to 1 will install a version of CodeTwo Email Signatures On-prem that is compatible with Server Core
- INSTALLDIR="<installation_dir_path>" – this parameter is optional. The default installation directory of CodeTwo Email Signatures On-prem is: C:\Program Files\CodeTwo\CodeTwo Email Signatures On-prem. You can change the installation location by typing a different path as the parameter value.
Example command line:EmailSignaturesOnPremSetupEN.msi /quiet ACTION="INSTALL" EXCHANGE_VERSION="SE" CORE="1"
-
In the PowerShell Console, navigate to the installation directory of CodeTwo Email Signatures On-prem, where the InstallCodeTwoTransportAgent.ps1 script is located. This script performs the following actions:
- stops the CodeTwo Email Signatures On-prem and the MSExchangeTransport services,
- installs and enables the CodeTwo Exchange Transport Agent,
- starts the CodeTwo Email Signatures On-prem and MSExchangeTransport services.
- Run the InstallCodeTwoTransportAgent.ps1 script to install the CodeTwo Exchange Transport Agent. If for some reason you cannot run the CodeTwo Exchange Transport Agent's installation script, you can install the transport agent manually. To do so, follow the steps described in section How to install the CodeTwo Exchange Transport Agent manually on Server Core.
To verify if the CodeTwo Email Signatures On-prem Services were installed correctly, perform the steps described below.
-
Launch the PowerShell Console and run the command:
Add-PSSnapin Microsoft.Exchange.Management.PowerShell.SnapIn
- Run the command:
Get-Service "CodeTwo *"
This command should return the following services: CodeTwo App Monitor, CodeTwo Mail Processor and CodeTwo Sent Items Update. Each of them should be active, i.e. their status should show Running. - Run the command:
Get-TransportAgent
This command returns a list of installed transport agents. You should see the CodeTwo Exchange Transport Agent at the bottom of the list. This transport agent should be enabled (Enabled = True).
How to uninstall CodeTwo Email Signatures On-prem from Server Core
Important
To be able to perform the steps described below, you need to use the same .msi file that was used to install the program. An .msi file of a different version of CodeTwo Email Signatures On-prem will not work.
If you don't have the relevant file any longer, perform these steps instead.
- In the PowerShell Console, navigate to the installation directory of CodeTwo Email Signatures On-prem, where the UninstallCodeTwoTransportAgent.ps1 script is located (by default, the program is installed in: C:\Program Files\CodeTwo\CodeTwo Email Signatures On‑prem). This script performs the following actions:
- stops the CodeTwo Email Signatures On-prem and MSExchangeTransport services,
- uninstalls the CodeTwo Exchange Transport Agent,
- starts the CodeTwo Email Signatures On-prem and MSExchangeTransport services.
- Run the UninstallCodeTwoTransportAgent.ps1 script to uninstall the CodeTwo Exchange Transport Agent. If for some reason you cannot run the CodeTwo Exchange Transport Agent's uninstallation script, you can uninstall the transport agent manually. To do so, follow the steps described in section How to uninstall the CodeTwo Exchange Transport Agent manually from Server Core.
- Run the Command Prompt (cmd.exe).
- In the Command Prompt, in order to uninstall the CodeTwo Email Signatures On-prem Services, run the EmailSignaturesOnPremSetupEN.msi file with the following parameters:
- /quiet
- REMOVE="ALL"
- EXCHANGE_VERSION="<value>" – this parameter determines the version of Exchange server that is installed on your machine. The value can be, for example: SE or 2019.
- CORE="1" – this parameter determines a Server-Core-specific installation of CodeTwo Email Signatures On-prem. Value 1 is used when uninstalling a version of CodeTwo Email Signatures On-prem that is compatible with Server Core.
Example command line:EmailSignaturesOnPremSetupEN.msi /quiet REMOVE="ALL" EXCHANGE_VERSION="SE" CORE="1"
In order to verify if the CodeTwo Email Signatures On-prem Services were uninstalled successfully, perform the steps described below.
- Launch the PowerShell Console and run the command:
Add-PSSnapin Microsoft.Exchange.Management.PowerShell.SnapIn
- In the PowerShell Console, run the command:
Get-Service "CodeTwo *"
This command should not return any services. - Run the command:
Get-TransportAgent
This command returns a list of installed transport agents. The CodeTwo Exchange Transport Agent should not be listed.
Uninstall CodeTwo Email Signatures On-prem by using the Windows Management Instrumentation (WMI) utility
This is an alternative method of uninstalling CodeTwo Email Signatures On-prem from Server Core, which doesn't require the original .msi file that was used to install the program.
- In the Command Prompt, type
wmic
and press Enter. This will display the wmic:root\cli> prompt. - Run the command:
product where name="CodeTwo Email Signatures On-prem" call uninstall
Type y to confirm the uninstall process.
You should get the following information after the program is successfully uninstalled :
Method Execution Successful.
Out Parameters:
instance of _PARAMETERS
{
ReturnValue = 0;
};
How to update the Server Core version of CodeTwo Email Signatures On-prem
Before you install the latest version of the program, you need to uninstall the existing version. Perform the steps described in section How to uninstall CodeTwo Email Signatures On-prem from Server Core using the EmailSignaturesOnPremSetupEN.msi file that contains the installation data of the currently deployed version of CodeTwo Email Signatures On-prem. Next, perform the steps described in section How to install CodeTwo Email Signatures On-prem on Server Core using the .msi file of the newer version of the program. All settings will be retained. If the CodeTwo Email Signatures On-prem Services are also installed on other servers in your organization, you need to update them on each server.
How to install the CodeTwo Exchange Transport Agent manually on Server Core
If for some reason you cannot run the CodeTwo Exchange Transport Agent's installation script, you can install the transport agent manually by following these steps:
- Launch the PowerShell Console and run the command:
Add-PSSnapin Microsoft.Exchange.Management.PowerShell.SnapIn
- Stop the MSExchangeTransport service by running the command:
Stop-Service "MSExchangeTransport"
- Stop all the installed CodeTwo Email Signatures On-prem Services by running the command:
Stop-Service "CodeTwo *"
- In the PowerShell Console, navigate to the installation directory of CodeTwo Email Signatures On-prem. By default, the program is installed in: C:\Program Files\CodeTwo\CodeTwo Email Signatures On-prem.
- Get an absolute path to the CodeTwo.ER.Agent.dll file by running the command:
$CodeTwoAgentAssemblyPath = Resolve-Path -Path CodeTwo.ER.Agent.dll
- Install the CodeTwo Exchange Transport Agent by running the command:
Install-TransportAgent -Name "CodeTwo Exchange Transport Agent" -AssemblyPath $CodeTwoAgentAssemblyPath -TransportAgentFactory "Agent.CAgentFactoryRouting"
- Enable the installed transport agent by running the command:
Enable-TransportAgent -Identity "CodeTwo Exchange Transport Agent"
- Start the MSExchangeTransport service by running the command:
Start-Service "MSExchangeTransport"
- Start all the installed CodeTwo Email Signatures On-prem Services by running the command:
Start-Service "CodeTwo *"
How to uninstall the CodeTwo Exchange Transport Agent manually from Server Core
If for some reason you cannot run the CodeTwo Exchange Transport Agent's uninstallation script, you can uninstall the transport agent manually by following these steps:
- Launch the PowerShell Console and run the command:
Add-PSSnapin Microsoft.Exchange.Management.PowerShell.SnapIn
- Stop the MSExchangeTransport service by running the command:
Stop-Service "MSExchangeTransport"
- Stop all the installed CodeTwo Email Signatures On-prem Services by running the command:
Stop-Service "CodeTwo *"
- Uninstall the CodeTwo Exchange Transport Agent by running the command:
Uninstall-TransportAgent -Identity "CodeTwo Exchange Transport Agent" -Confirm:$false
- Start the MSExchangeTransport service by running the command:
Start-Service "MSExchangeTransport"
- Start all the installed CodeTwo Email Signatures On-prem Services by running the command:
Start-Service "CodeTwo *"
In this article