Microsoft SQL Server agent, Db2 agent, and Sybase agent installations fail with an earlier version of Microsoft Visual C++ 2013

Problem

If an earlier version of Microsoft Visual C++ 2013 is already installed on your system, then whenever you try to install Microsoft SQL Server agent, Db2 agent, and Sybase agent, the first time, the installations fail.
Note: This issue occurs for agent version 8.1.4.0.17 and later versions.

Symptom

If an earlier version of VC++ 2013 is already installed on the system, then the agent installations fail, the first time you install the agents.

The following failure statement is displayed in the log file:

[LOG]: RC_INFO: ERROR: 64-bit VC++ redistributable 2013 package installation failed. See log file for additional information. To resolve the issue, install <installer_path>\apm\inst\core-framework\InstallITM\vcredist_x64.exe manually.

Cause

When you install the agents, VC++ 2013 -12.40.664 package is installed along with the agents.

However, if any earlier version of VC++ 2013 is already installed on the system and is being used by any application on the system, then the agent installations fail, the first time you try to install the agents.

Solution

When you install the agents again for the second time on same system, the agents are installed successfully.