When installing an Exchange update you may run into the following error.
Error: The following error was generated when "$error.Clear(); & $RoleBinPath\ServiceControl.ps1 -Operation:DisableServices -Roles:($RoleRoles.Replace('Role','').Split(',')) -SetupScriptsDirectory:$RoleBinPath; & $RoleBinPath\ServiceControl.ps1 Stop $RoleRoles.Replace('Role','').Split(',') " was run: "Microsoft.Exchange.Configuration.Tasks.ServiceStopFailureException: Service 'tmlisten' failed to stop due to error:'Cannot stop tmlisten service on computer ---> System.InvalidOperationException: Cannot stop tmlisten service on computer ---> System.ComponentModel.Win32Exception: The requested control is not valid for this service
The tmlisten service is associated with the Trend Micro antivirus product and specifically the Trend Micro Listener service. This service requires a password to stop and can not be disabled via either the services snap-in or command line.
Tip: It’s best practice to temporarily shut down antivirus products during the Exchange install as they have been known to increase install times by several hours. Or, in this case, completely block updates.
The tmlisten workaround
To disable Trend Micro right-click on its icon in the system tray and select Exit Security Agent.
You will be prompted to enter a password to shut down the Trend Micro services. Enter this password and click Ok.
You may need to wait about 60 seconds for the Trend Micro services to stop. Once stopped you can continue your Exchange update past this error.
Have you ever run into this problem? What did you do to fix it? Drop a comment below or come join the conversation on Twitter @SuperTekBoy.
Jon says
I know this is an old post, but thank you! Was pulling my hair out and because I’m a doof I didn’t think to disable a/v. Thanks for pointing me in the right direction!
-Jon
Zoltan says
Hey Gareth,
Yes, antivirus is known to interfere with many things and best practice is to disable it during significant changes, including (un)installing Exchange and its updates. Same is true for other software such as backup and even Performance Monitor.
I’ve come across similar issues, see my blog at http://ezoltan.blogspot.ro/2016/11/removing-exchange-2010-disable.html?m=1
I enjoy reading your posts, keep it up ?
Zoltan
Gareth Gudger says
Interesting read Zoltan. I have seen various antivirus, backup and, 3rd party monitoring software block the Exchange uninstall. Have not run into Performance Monitor yet. Will add that to my list of things to look for. Many thanks!