# MQTT CLI

**URL:** https://community.hivemq.com/c/mqtt-cli/9.md

[Latest](https://community.hivemq.com/latest.md) · [Categories](https://community.hivemq.com/categories.md)

---

## [About the MQTT CLI category](https://community.hivemq.com/t/about-the-mqtt-cli-category/91)

<div class="topic-metadata">

**Author:** [@hivemq-support](https://community.hivemq.com/u/hivemq-support)\
**Replies:** 0

</div>

This category is meant to provide a space to discuss anything regarding the newly released MQTT Command Line Interface, which is based on the HiveMQ MQTT Client Library. You can find the MQTT CLI on GitHub

---

## [Mqtt CLI persistant session](https://community.hivemq.com/t/mqtt-cli-persistant-session/2605)

<div class="topic-metadata">

**Author:** [@Zuendi](https://community.hivemq.com/u/Zuendi)\
**Replies:** 14\
**Last updated:** [February 15, 2024, 3:38pm UTC](https://community.hivemq.com/t/mqtt-cli-persistant-session/2605 "2024-02-15T15:38:11Z")

</div>

Hi all, I tried to start a persistent session using MQTT cli but couldn’t get it to work. The idea was to create a session that is able to queue a couple of messages and to receive them after my client connects again. …

---

## [Error: 'CONNECT failed as CONNACK contained an Error Code: NOT\_AUTHORIZED.'](https://community.hivemq.com/t/error-connect-failed-as-connack-contained-an-error-code-not-authorized/2217)

<div class="topic-metadata">

**Author:** [@gaurav](https://community.hivemq.com/u/gaurav)\
**Replies:** 7\
**Last updated:** [July 13, 2023, 10:34pm UTC](https://community.hivemq.com/t/error-connect-failed-as-connack-contained-an-error-code-not-authorized/2217 "2023-07-13T22:34:23Z")

</div>

Hi team, I am trying to set up HiveMQ locally on Windows: CLI setup :white\_check\_mark: HiveMQ Broker setup :white\_check\_mark: HiveMQ rub.bat and Security extension running :white\_check\_mark: PostgreSQL …

---

## [Installing MQTT CLI from Source Failing](https://community.hivemq.com/t/installing-mqtt-cli-from-source-failing/1679)

<div class="topic-metadata">

**Author:** [@mike55c](https://community.hivemq.com/u/mike55c)\
**Replies:** 1\
**Last updated:** [December 14, 2022, 8:39am UTC](https://community.hivemq.com/t/installing-mqtt-cli-from-source-failing/1679 "2022-12-14T08:39:46Z")

</div>

I have an aarch 64 bit architecture and im running a yokto based linux. I don’t have any package manager system on this machine so I have to build from source. After running the ./gradlew build i get 16 failed tests… al…

---

## [MQTT performance measurement using MQTT HiveMQ](https://community.hivemq.com/t/mqtt-performance-measurement-using-mqtt-hivemq/1624)

<div class="topic-metadata">

**Author:** [@Shruti](https://community.hivemq.com/u/Shruti)\
**Replies:** 0\
**Last updated:** [November 24, 2022, 11:14am UTC](https://community.hivemq.com/t/mqtt-performance-measurement-using-mqtt-hivemq/1624 "2022-11-24T11:14:29Z")

</div>

How can I measure MQTT performance. I am using HiveMQ MQTT Broker and MQTT CLI. What can I do this and how can I use this in my simulation? I want MQTT Performance mentioned on your website. I want to implement and me…

---

## [Mqtt list is showing only one client while I have several connected](https://community.hivemq.com/t/mqtt-list-is-showing-only-one-client-while-i-have-several-connected/1189)

<div class="topic-metadata">

**Author:** [@sanjmeh](https://community.hivemq.com/u/sanjmeh)\
**Replies:** 4\
**Last updated:** [May 5, 2022, 4:40pm UTC](https://community.hivemq.com/t/mqtt-list-is-showing-only-one-client-while-i-have-several-connected/1189 "2022-05-05T16:40:05Z")

</div>

I am using MQTT CLI to connect to a HiveMQ CE broker. There are around 10+ topics being published on the broker and 4 ~5 total clients are connected (2 pub and 2 sub from remote devices) and 1 sub from my CLI. When i do …

---

## [Mqtt shell \`con\` command without flag -s does not show any data](https://community.hivemq.com/t/mqtt-shell-con-command-without-flag-s-does-not-show-any-data/1188)

<div class="topic-metadata">

**Author:** [@sanjmeh](https://community.hivemq.com/u/sanjmeh)\
**Replies:** 1\
**Last updated:** [May 5, 2022, 12:59pm UTC](https://community.hivemq.com/t/mqtt-shell-con-command-without-flag-s-does-not-show-any-data/1188 "2022-05-05T12:59:44Z")

</div>

I am new to hivemq CLI. Am trying to test the publishing data for a specific topic. I am able to sucessfully subscribe to a topic as follows mqtt\> con -h mqtt.\[spoiler\]mindshiftapps\[/spoiler\].net -i machome machome@mqt…

---

## [HiveMQ CLI hexadecimal values](https://community.hivemq.com/t/hivemq-cli-hexadecimal-values/917)

<div class="topic-metadata">

**Author:** [@marco95](https://community.hivemq.com/u/marco95)\
**Replies:** 2\
**Last updated:** [January 3, 2022, 11:22am UTC](https://community.hivemq.com/t/hivemq-cli-hexadecimal-values/917 "2022-01-03T11:22:32Z")

</div>

Hi, I used the MQTT cli to test my first connection. I followed the guide and installed the software under windows and all works as expected. I can subscribe to a topic and receive what other instance publishes. Only t…

---

## [Getting the CLI sub cmd to display "missed" meesages](https://community.hivemq.com/t/getting-the-cli-sub-cmd-to-display-missed-meesages/462)

<div class="topic-metadata">

**Author:** [@daniel.altmann](https://community.hivemq.com/u/daniel.altmann)\
**Replies:** 2\
**Last updated:** [March 25, 2021, 1:53pm UTC](https://community.hivemq.com/t/getting-the-cli-sub-cmd-to-display-missed-meesages/462 "2021-03-25T13:53:54Z")

</div>

Dear HiveMQ-Team, dear MQTT-comrades, I’m trying to get the CLI-Tool to display missed messages. I.e. I am doing the following: mqtt sub -q 2-i 42 -se 1000 --no-cleanStart -t testtopic -h localhost -p 10083 mqtt pub …

---

## [MQTT CLI configuration for websocket](https://community.hivemq.com/t/mqtt-cli-configuration-for-websocket/214)

<div class="topic-metadata">

**Author:** [@almalb](https://community.hivemq.com/u/almalb)\
**Replies:** 4\
**Last updated:** [May 1, 2020, 11:01am UTC](https://community.hivemq.com/t/mqtt-cli-configuration-for-websocket/214 "2020-05-01T11:01:26Z")

</div>

Hello, Trying to connect to “broker.mqttdashboard.com” using port 8000 from MQTT CLI i have the output “Server closed connection without DISCONNECT.” What should be the configuration in config.properties file to connect …

---

## [Exception while decoding CONNECT: must not receive this packet typ](https://community.hivemq.com/t/exception-while-decoding-connect-must-not-receive-this-packet-typ/121)

<div class="topic-metadata">

**Author:** [@dileepmandapam](https://community.hivemq.com/u/dileepmandapam)\
**Replies:** 1\
**Last updated:** [December 23, 2019, 8:11am UTC](https://community.hivemq.com/t/exception-while-decoding-connect-must-not-receive-this-packet-typ/121 "2019-12-23T08:11:05Z")

</div>

Exploring Hive MQTT CLI commands on ActiveMQ broker with MQTT enabled. But con command is failing with ERROR Exception while decoding CONNECT: must not receive this packet type. Any clue what went wrong?. Here is the…

---

## [QoS1 message can't be shown anywhere](https://community.hivemq.com/t/qos1-message-cant-be-shown-anywhere/88)

<div class="topic-metadata">

**Author:** [@Seiji](https://community.hivemq.com/u/Seiji)\
**Replies:** 3\
**Last updated:** [October 1, 2019, 6:58am UTC](https://community.hivemq.com/t/qos1-message-cant-be-shown-anywhere/88 "2019-10-01T06:58:09Z")

</div>

Hi, I started to use MQTT CLI as it looks fine. It’s good and almost works I expected. but there is one issue I’m facing. I can’t see published message if it’s QoS1 and sent when disconnected. I’m using -oc and -of opt…
