首页 > 系统相关 >Installing Mosquitto Under CentOS【转】

Installing Mosquitto Under CentOS【转】

时间:2022-11-11 23:02:14浏览次数:65  
标签:CentOS sudo Installing Step mosquitto yum Mosquitto was


 

    It was decided that CEIT was in need of a local MQTT server to avoid having to play in the mess that is IBM's realtime server. So I installed one on the same virtual machine that ejabberd was installed on. Here's how I did it:

What you'll need:

  • Port 1883 to be open to incoming MQTT messages

    Step 1: Add the CentOS mosquitto repository to YUM's list of repositories

 



1. $ cd /etc/yum/yum.repos.d 2. $ wget http://download.opensuse.org/repositories/home:/oojah:/mqtt/CentOS_CentOS-5/home:oojah:mqtt.repo 3. $ sudo yum update



 

 

    Step 2: Install mosquitto



1. $ sudo yum install mosquitto



 

    Step 3: Run mosquitto

    As of writing, no init.d script exists for the CentOS distribution of mosquitto. However, it is a simple enough matter to set it running as a daemon, you'll just need to restart it yourself whenever your machine gets restarted.



1. $ sudo su 2. $ /usr/sbin/mosquitto -d -c /etc/mosquitto/mosquitto.conf > /var/log/mosquitto.log 2>&1



  

    Mosquitto should now be running! You can test it by pointing mosquitto_pub and _sub at it.

 

    Likely problems:

    There appear to be some issues with the mosquitto libraries in the repository, in that they don't work out of the box. I had better success compiling the libraries from source and installing them that way. The method for doing that is fairly similar to doing under OSX, so see my previous post on that subject.

 

参考文章:​​http://ceit.uq.edu.au/content/installing-mosquitto-under-centos​


标签:CentOS,sudo,Installing,Step,mosquitto,yum,Mosquitto,was
From: https://blog.51cto.com/u_15107509/5845534

相关文章

  • centos7安装docker
    环境查看centos需要7版本以上,内核最好3.10以上1.查看Linux版本:rpm-qcentos-release2.查看内核版本:uname-r安装卸载旧组件sudoyumremovedocker\......
  • centos安装zookeeper服务
    zookeeper介绍ZooKeeper是一个开源的分布式协调服务。它是一个为分布式应用提供一致性服务的软件,分布式应用程序可以基于Zookeeper实现诸如数据发布/订阅、负载均衡、命......
  • CentOS 7 升级OpenSSH 9.1p1记录
    因服务器被扫描出漏洞,需要对OpenSSH升级,遇到一些波折,记录如下。安装配置telnet服务OpenSSH用于远程登录,一旦升级失败用不了,将无法远程登录,安装telnet-server备用。yumi......
  • CentOS中卸载安装JAVA
    一、卸载CentOS中原有JAVA1、查看原有JDKrpm-qa|grepjava2、卸载JDKsudoyum-yremovejava-1.6.0-openjdk-1.6.0.41-1.13.13.1.el6_8.x86_64sudoyum-yrem......
  • centos8下mysql创建新用户
    1、进入docker下mysqldockerexec-it容器ID/bin/bashmysql-uroot-p2、修改用户密码UPDATEuserSETpassword=PASSWORD('newpassword')whereUSER......
  • Linux Centos7 部署步骤 mysql
    0.首先查看cpu架构uname-a输出内容中有关键词ARM或aarch64就是ARM架构,有关键词x86_64就是X86架构1.下载mysql8(https://dev.mysql.com/)选择 RedHat......
  • CentOS 7 安装 ElasticSearch 8.5
    参考:InstallElasticsearchfromarchiveonLinuxorMacOS|ElasticsearchGuide[8.5]|ElasticInstallKibanafromarchiveonLinuxormacOS|KibanaGuide[......
  • Linux下(CentOS)下Docker的安装
    Linux下(CentOS)下Docker的安装以及阿里云加速器的配置什么是Docker?Docker是一个开源的应用容器引擎。让开发者可以打包他们的应用以及依赖包到一个可移植的镜像中,然后发布到......
  • LINUX CENTOS7 部署步骤 Ftp
    0.linux中FTP服务叫做vsftpd1.查看ftp是否安装rpm-qa|grepftp2.查找vsftpyumlist|grepvsftp3.安装vsftpdyum-yinstallvsftpd4.验证是否安装......
  • CentOS7 安装mysql8
    1、下载并解压mysql安装包https://downloads.mysql.com/archives/community/  放到服务器后解压-C放到指定文件夹tar-xvfmysql-8.0.30-linux-glibc2.12-x86......