OS: Linux ---Centos7
RabbitMQ版本:RabbitMQ version: 3.8.1
erlang版本:Erlang configuration: Erlang/OTP 22 [erts-10.6.3] [source] [64-bit] [smp:4:4] [ds:4:4:10] [async-threads:64] [hipe]
安装方式:使用rpm安装

后台启动方式:

cd /usr/lib/rabbitmq/bin
./rabbitmq-server start &

或者

./rabbitmq-server start -detached
# Warning: PID file not written; -detached was passed.#忽略警告,貌似是rabbitmq bug

问题1:用 rabbitmq-server start &启动报错

[root@lyy bin]# rabbitmq-server start &
[1] 9900
[root@lyy bin]# /usr/lib/rabbitmq/bin/rabbitmq-server:行51: /var/lib/rabbitmq/mnesia/rabbit.pid: 权限不够
Failed to write pid file: /var/lib/rabbitmq/mnesia/rabbit.pid

解决方法:

chown -R rabbitmq:rabbitmq /var/lib/rabbitmq/mnesia/

问题2: rabbitmqctl 用不了

[root@lyy bin]# rabbitmqctl status
Error: unable to perform an operation on node 'rabbit@lyy'. Please see diagnostics information and suggestions below. Most common reasons for this are: * Target node is unreachable (e.g. due to hostname resolution, TCP connection or firewall issues)
* CLI tool fails to authenticate with the server (e.g. due to CLI tool's Erlang cookie not matching that of the server)
* Target node is not running In addition to the diagnostics info below: * See the CLI, clustering and networking guides on https://rabbitmq.com/documentation.html to learn more
* Consult server logs on node rabbit@lyy
* If target node is configured to use long node names, don't forget to use --longnames with CLI tools DIAGNOSTICS
=========== attempted to contact: [rabbit@lyy] rabbit@lyy:
* connected to epmd (port 4369) on lyy
* epmd reports node 'rabbit' uses port 25672 for inter-node and CLI tool traffic
* TCP connection succeeded but Erlang distribution failed * Authentication failed (rejected by the remote node), please check the Erlang cookie Current node details:
* node name: 'rabbitmqcli-4109-rabbit@lyy'
* effective user's home directory: /var/lib/rabbitmq
* Erlang cookie hash: 8y/oHO82So4EqWKv6DO9vw==

解决办法:

[root@lyy bin]# vim /var/lib/rabbitmq/.erlang.cookie
[root@lyy rabbitmq]# cd /home
[root@lyy ~]# vim .erlang.cookie

把两个文件中内容改为一致,重启rabbitmq即可

使用rabbitmq过程中遇到的问题及解决方法记录。的更多相关文章

  1. 国内不fq安装K8S四: 安装过程中遇到的问题和解决方法

    目录 4 安装过程中遇到的问题和解决方法 4.1 常见问题 4.2 常用的操作命令 4.3 比较好的博客 国内不fq安装K8S一: 安装docker 国内不fq安装K8S二: 安装kubernet 国 ...

  2. 将html代码部署到阿里云服务器,并进行域名解析,以及在部署过程中遇到的问题和解决方法

    本博客主要是说一下,,如何将html代码部署到阿里云服务器,并进行域名解析,以及在部署过程中遇到的问题和解决方法. 1.先在阿里云上购买一台阿里云服务器(ECS云服务器): 2.远程连接上该服务器,在 ...

  3. 2016最新cocoapods安装流程,安装过程中遇到的问题及解决方法

    现在的cocoapods与之前比较.有很多不一样的地方.自己试了一试,终于搞定.现在大概纪录一下. 1.首先查看ruby是否是最新版的. ruby是通过rvm安装的所以需要先安装rvm后查看ruby是 ...

  4. 蘑菇街TeamTalk编译连接过程中遇到的问题及解决方法(iOS)

    今天浏览博文的时候,“蘑菇街开源的即时通讯框架,包括iOS.Android.Mac.Windows客户端和后台 Github源码下载地址:https://github.com/mogujie/Team ...

  5. caffe安装过程中遇到的问题以及解决方法

    1. 在安装依赖库的时候,遇到: @gxjun-Latitude-E5440:~$ sudo apt-get install libatlas-base-dev 正在读取软件包列表... 完成 正在分 ...

  6. 使用javamail发信过程中的一些问题及解决方法

    http://www.blogjava.net/TrampEagle/archive/2006/05/26/48326.html 今天在研究javamail发信的过程中,出现了一些小问题,现总结如下, ...

  7. Tomcat启动过程中找不到JAVA_HOME解决方法

    在XP上明明已经安装了JDK1.5并设置好了JAVA_HOME,可偏偏Tomcat在启动过程中找不到. 报错信息如下:Neither the JAVA_HOME nor the JRE_HOME en ...

  8. 最新cocoapods安装流程,安装过程中遇到的问题及解决方法

    最近重新安装了一次cocoapods,参考的安装流程:http://blog.csdn.net/showhilllee/article/details/38398119/ 但是现在的cocoapods ...

  9. live555源码研究(十)------在编译过程中遇到的问题及解决方法

    一.编译testOnDemandRTSPServer.cpp. 在testProgs项目中,加入testOnDemandRTSPServer.cpp进行编译,编译类型是编译成exe文件,在编译过程中会 ...

随机推荐

  1. react-ts模板2.0

    最新整理的react模板2.0 - react 16.12.0 - react-router - redux,redux-thunk - hooks,typescript - antd v4,sass ...

  2. VS c# 操作 Microsoft Project mpp 文件 并遍历边关系

    网上找到资料提供了遍历.mpp文件中任务的功能: http://blog.csdn.net/gxf36/article/details/5253792 ======================== ...

  3. Using platform encoding (UTF-8 actually) to copy filtered resources, i.e. build is platform dependen

    Using platform encoding (UTF-8 actually) to copy filtered resources, i.e. build is platform dependen ...

  4. 十分钟搭建自己的私有NuGet服务器-BaGet

    目录 前言 开始 搭建BaGet 上传程序包 在vs中使用 其他 最后 前言 NuGet是用于微软.NET(包括 .NET Core)开发平台的软件包管理器.NuGet能够令你在项目中添加.移除和更新 ...

  5. 职场老鸟,一文教你如何正确入门Python爬虫!

    爬虫现在的火热程度我就不说了,先说一下这门技术能干什么事儿,主要为以下三方面: 1.爬取数据,进行市场调研和商业分析 爬取知乎.豆瓣等网站的优质话题内容:抓取房产网站买卖信息,分析房价变化趋势.做不同 ...

  6. Python预测2020高考分数和录取情况

    “迟到”了一个月的高考终于要来了. 很多人学习python,不知道从何学起.很多人学习python,掌握了基本语法过后,不知道在哪里寻找案例上手.很多已经做案例的人,却不知道如何去学习更加高深的知识. ...

  7. Linux 中文编码

  8. Django Web 测试

    Django 单元测试 模拟浏览器发起请求,测试 web 功能.只是简单记录一下怎么使用. 环境 Win10 Python2.7 Django 1.8.11 MySQL5.6 项目结构 大致如下 my ...

  9. gotoblas,mpich,hpl,hpcg的安装

    gotoblas的安装 mpich 安装 tar zxvf mpich-3.2.1.tar.gz cd mpich-3.2 ./configure --prefix=/usr/local/mpich( ...

  10. C#设计模式之14-命令模式

    命令模式(Command Pattern) 该文章的最新版本已迁移至个人博客[比特飞],单击链接 https://www.byteflying.com/archives/413 访问. 命令模式属于行 ...