Mosquitto installing Message Queuing on _ubuntu/debian Mosquitto

Source: Internet
Author: User
Tags gpg

Mosquitto installing Message Queuing on _ubuntu/debian Mosquitto

MQTT is an Instant Messaging protocol developed by IBM. MQTT is a connectivity protocol for both the machine and the internet of Things, with lightweight publishing and subscription messaging. Mosquitto is an open source messaging agent software that implements the MQTT v3.1 protocol, providing a lightweight, publish/Subscribe messaging push mode that makes device-to-device short message communication easy to use.
If you first contact the MQTT protocol, you can first understand the following concepts:
"MQTT protocol Features"-the MQTT protocol allows for better remote control than the restful architecture of the IoT system, thanks to the messaging push feature.
The MQTT protocol role-The IoT system in the RESTful architecture, contains two role clients and server-side, while the MQTT protocol includes publishers, agents (servers), and Subscribers.
The messages in the MQTT protocol message--MQTT can be understood as the content (payload) exchanged by the Publisher and Subscribers, which contain specific content that can be used by subscribers.
Topics in the MQTT protocol topics--MQTT can be understood as message collections of the same type or similar type

The port is monitored by default:

1883:MQTT, no encryption
8883:MQTT, encryption
8884:MQTT, encryption, customer service side need to verify
8080:mqtt via WebSockets, no encryption

By default, Mosquitto will be placed in the kernel of the computer or in the same way as like Intel-edison in the micro-control, the following is the Linux download station for everyone to say how to install Mosquitto.


To install Mqtt:

Update Source,



$ sudo wget http://repo.mosquitto.org/debian/mosquitto-repo.gpg.key

$ sudo apt-key add Mosquitto-repo.gpg.key


Make source, using apt:

$ sudo cd/etc/apt/sources.list.d/

Then choose according to your Debian version:


$ sudo wget http://repo.mosquitto.org/debian/mosquitto-wheezy.list

$ sudo wget http://repo.mosquitto.org/debian/mosquitto-jessie.list


For Ubuntu users please use this address: https://launchpad.net/~mosquitto-dev/+archive/ubuntu/mosquitto-ppa/


Update apt information:

$ sudo apt-get update

Look at the resources available for the Mosquitto installation package:

$ sudo apt-cache search Mosquitto

Or go directly into the installation:

$ sudo apt-get install Mosquitto

To open MQTT:

$ sudo service Mosquitto start

To stop MQTT:

$ sudo service Mosquitto stop

To view the MQTT status:

$ sudo service Mosquitto status

To view the monitored ports:

$ NETSTAT-ANPLT | grep 1883

You can also test,

$ sudo mosquitto_sub-h test.mosquitto.org-t "#"-V

Mosquitto installing Message Queuing on _ubuntu/debian Mosquitto

Contact Us

The content source of this page is from Internet, which doesn't represent Alibaba Cloud's opinion; products and services mentioned on that page don't have any relationship with Alibaba Cloud. If the content of the page makes you feel confusing, please write us an email, we will handle the problem within 5 days after receiving your email.

If you find any instances of plagiarism from the community, please send an email to: info-contact@alibabacloud.com and provide relevant evidence. A staff member will contact you within 5 working days.

A Free Trial That Lets You Build Big!

Start building with 50+ products and up to 12 months usage for Elastic Compute Service

  • Sales Support

    1 on 1 presale consultation

  • After-Sales Support

    24/7 Technical Support 6 Free Tickets per Quarter Faster Response

  • Alibaba Cloud offers highly flexible support services tailored to meet your exact needs.