Jump to content
Sign in to follow this  
Zombunny

Restarting Immunet Service - another way

Recommended Posts

Hi all,

I noticed a thread that's been moved to the FAQ section (therefore I can't reply on it) regarding someone wanting to use the CLI to restart the immunet service. The solution offered was to use good-old "net stop" / "net start". This requires you to know the exact name of the service (obviously). The problem is that over the years I've used Immunet, the service name has changed occasionally. It has been known as "ImmunetProtect", "Immunet", "Immunet[version.number]", etc.

If you want a generic way of always reliably starting and stopping the service from a terminal, you need something that just needs to know that the service you're after is Immunet, but doesn't care about the exact name. The solution? The following "generic" commands:

Stop any service that's got the word "Immunet" in its name:

wmic service where "name like 'Immunet%'" call stopservice

Start any service that's got the word "Immunet" in its name:

wmic service where "name like 'Immunet%'" call startservice

Please note that these work directly on the commandline. If you wish to execute these from within a batch file, you need to replace 'Immunet%' with 'Immunet%%' (add a second %), or it won't work.

These two commands should allow you to always be able to restart the service, regardless of if the developers change its name slightly from version to version.

I use these in a .bat file that adds the latest Sanesecurity and Securiteinfo ClamAV signatures to Immunet (amazing detection rate), but I will wait until the "ask me" bug in 6.2 is fixed before posting the source here, as these signatures cause many false positives.

  • Like 1

Share this post


Link to post
Share on other sites

Create an account or sign in to comment

You need to be a member in order to leave a comment

Create an account

Sign up for a new account in our community. It's easy!

Register a new account

Sign in

Already have an account? Sign in here.

Sign In Now
Sign in to follow this  

×