第一部分:在Ubuntu1104 上面安装mosquitto
1)安装mosquitto
上面对ubuntu的安装介绍(https://launchpad.net/+help-soyuz/ppa-sources-list.html)
使用下面命令:
a) sudo apt-add-repository ppa:mosquitto-dev/mosquitto-ppa
b)sudo apt-get update
c) sudo apt-get install mosquitto
2) 把mosquitto.py, setup.py拷贝到linux下面(这个文件从windows安装包下面的python目录下得到;后面在Red Hat Enterprise环境下安装时,直接下载了python-mosquitto)。
但是提示错误:AttributeError: python: undefined symbol: mosquitto_lib_init
需要安装libmosquitto.
3) 安装libmosquitto
sudo apt-get install libmosquitto0-dev
第二部分:在Red Hat Enterprise 6 上面安装mosquitto
在本机用了windows环境和ubuntu环境,后来在Amazon Web Service上的测试环境是Red Hat Enterprise 6
2) yum install
The available packages are: mosquitto, mosquitto-pub, mosquitto-sub, libmosquitto0, libmosquitto-devel, libmosquittopp0, libmosquittopp-devel, python-mosquitto.