Run Hamachi as a Service - Simplified

This page is for anyone wanting to run the excellent Hamachi VPN client as a service under Windows. That is, you want it to run under the local system account at bootup.

There is plenty of information on how to do so on the Hamachi forums. The problem is that this requires the installation of third party software and several error prone steps to get there.

The purpose of this page is to provide a way to narrow those steps down to a simple setup wizard.

If you just want to get to it, click here to DOWNLOAD the setup. Either "open" it or save it to your hard drive and run it from there (close Hamachi first if it is running).

Requirements (most will elicit a warning from the setup if you don't meet the specs)

  1. Hamachi version 1.0.0.45 or greater must be installed.
  2. Windows 2000, XP or Server 2003 (may work on Vista, not yet tested)
  3. Admin privileges

FAQ

  1. I have Hamachi start when I log in (or I have put it in the startup group), so why would I want to run it as a service?

    One reason is that remote desktop sharing (which via Hamachi gives you a great way to visit your work/home computer when you're elsewhere) requires that Hamachi be running under a different username. Another is that you may want Hamachi to always be running uninterrupted regardless of which user is logged in.
  2. How does it work?

    One of two ways. By default, it installs a specialized version of a program called ServiceEx(tm) which is a free utility for running any application as a service. Optionally, you can use Microsoft's Instrv and Srvany instead of ServiceEx. If you choose to use Microsoft's utilities, you will need to obtain them on your own since they are not redistributable. You'll find some information on where to find them here.

    In either case, ServiceEx or Srvany are lauched at bootup which, in turn, will launch Hamachi.

  3. What is the advantage of using ServiceEx rather than Instsrv/Srvany?

    ServiceEx comes bundled in the setup, so you don't need to do anything other than run the setup. Also, see the next item.
  4. What happens if Hamachi shuts down unexpectedly?

    Presumably one of the reasons one configures Hamachi to always be running under the local system account is to ensure that it is always running, even when the machine is rebooted or some other condition causes it to shut down. In order to accommodate this ServiceEx by default will be configured to restart Hamachi whenever it detects that Hamachi has shut down. But see the next item.
  5. Will Hamachi's Automatic update feature work if ServiceEx is trying to restart it whenever it shuts down?

    In a word, no. When an automatic update is applied by Hamachi, it temporarily stops Hamachi and then tries to restart it. This triggers an attempt by ServiceEx to restart Hamachi (if it is configured to do so), and Hamachi and ServiceEx interfere with each other. The exit value reported by Hamachi is the same as a normal shutdown, so there is no way for ServiceEx to distinguish this shut down from any other.

    Therefore we recommend that you either configure the ServiceEx setup to not restart Hamachi (which you can do in the setup wizard), or turn off automatic updates in Hamachi preferences (which as of this writing is off by default). Even if you turn off Hamachi automatic updates, you will still be notified of a new Hamachi version via a system message (your Hamachi tray icon will blink).

  6. What is Hamachi?

    Hamachi is VPN software that is notable for its ease of setup. Due to its NAT traversal capabilities, network members inside a NAT router can communicate with those outside even without having to open up ports. If you have yet to setup Hamachi, go here and then come back when you are ready to set it up as a service.

Notes:

Questions or comments