Versions Compared

Key

  • This line was added.
  • This line was removed.
  • Formatting was changed.

We recommend using C:\hivemq as the home installation folder. The following examples follows this recommendation.

\uD83E\uDD14 Problem

The Windows service is failing fails to start after you follow the instructions https://hivemq.atlassian.net/wiki/x/DIG3Kw or https://docs.hivemq.com/hivemq/latest/user-guide/install-hivemq.html#_install_hivemq_as_a_windows_service following the instructions provided in this link or in the HiveMQ Documentation.

\uD83C\uDF31 Solution

The solution is to use involves utilizing the newer version of the Java wrapper, a tool specifically designed for running Java programs to run as a Windows serviceservices.

  1. Download

    View file
    nameyajswhivemq-windows-stableservice-13.10022024.zip

  2. Unzip the downloaded file to the $HIVEMQ_HOME directory.

    • If you followed the

    above-mentioned
    • abovementioned instructions, your $HIVEMQ_HOME directory is likely C:\hivemq\hivemq-windows-service-022024.

  3. If your $HIVEMQ_HOME directory is not C:\hivemq, but, for example, different, such as C:\hivemq\hivemq-4.9.15, or C:\Program Files\hivemq-42.25.0, or F:\HiveMQ, then you need to edit the wrapper’s configuration file .as follows

    1. The Locate the wrapper’s configuration file is at conf/wrapper.conf. The line to edit is located In our case its path C:\hivemq\hivemq-windows-service-022024\conf\wrapper.conf

    2. Find the line at the end of the wrapper.conf file and looks like thisfile resembling:

      Code Block
      languagebash
      wrapper.java.additional.1 = -Dhivemq.home=C:\\hivemq
    3. What you need to do is to update the Replace the existing text C:\\hivemq according to with your actual $HIVEMQ_HOME directory. For example, if your $HIVEMQ_HOME directory is it's F:\HiveMQ, you must update the line to:

      Code Block
      languagebash
      wrapper.java.additional.1 = -Dhivemq.home=F:\\hivemqHiveMQ

    Now, when the wrapper directory is located inside the $HIVEMQ_HOME directory and the wrapper.conf matches the actual $HIVEMQ_HOME, you can proceed to the service.

    1. Remove the “old” save the file

  4. Once step 3 is complete, please proceed with the following steps:

    1. Remove the old (failing) HiveMQ service by

      1. Open services app with run(win+R)>services.

      Run
      1. msc

      2. Find the existing HiveMQ service

      3. Select the HiveMQ service and delete it

    2. Install the new service by running C:\hivemq\hivemq-windows-service-022024\bat\installService.bat (Run As Administrator might be necessary) – this under the newly unzipped service folder. This will install the new HiveMQ service.

    3. Start the new HIveMQ service and monitor if it fails within You can either restart the computer or Manually start the new HiveMQ service by going to run(win+R)>services.msc>HiveMQ service and starting it.

    4. Please monitor the HiveMQ service and look for any issues within the first 30 seconds.

    5. If the HiveMQ service is running longer runs without failing for more than 30 seconds without failing, verify the check the C:\hivemq\log\hivemq.log file , if it contains no for errors and ensure it contains "HiveMQ started in"...

    6. Next, verify Confirm that you can log in to the HiveMQ Control Center.

Info

If you prefer building the wrapper on your own, for example, for a newer version, follow its author’s instructions provided in this video.

🐛 Troubleshooting

\uD83E\uDD14 Problem

When I double click the install.bat file in Windows, It prints some stuff and closes then quickly. What to do?

\uD83C\uDF31 Solution

You need to run the bat file from the Windows Terminal. This way the window does not close when the script ends.

  • Open Windows Terminal:

    • Press Win + X and select Windows Terminal (or Windows Terminal (Admin) if administrative privileges are needed).

  • Navigate to the Directory:

    • In the terminal, navigate to the directory where your batch file is located.

      Code Block
      languagepowershell
      cd C:\hivemq\bin
  • Run the Batch File:

    • Once in the correct directory, type the name of the batch file and press Enter.

      Code Block
      languagepowershell
      install-something.bat
  • Observe the output of the bat file in the terminal

Filter by label (Content by label)
showLabelsfalse
max5
spacescom.atlassian.confluence.content.render.xhtml.model.resource.identifiers.SpaceResourceIdentifier@957
sortmaxCheckboxmodifiedfalse
showSpacefalse
reversesorttruemodified
typepage
reversetrue
labelskb-troubleshooting-article
cqllabel = "kb-troubleshooting-articlewindows" and type = "page" and space = "KB"