fiware-orion - 无法运行 Orion 上下文代理
问题描述
必须将 MongoDB 移动到外部 VM 上,因此重新配置 Orion CB 以不在本地主机上使用 Mongo,而是通过外部 mongoDB 的 IP(mongoDB 还配置为绑定外部 IP)。每当我尝试运行 Orion CB 时,它都会停止,日志说它失败了:
cat: /run/var/contextBroker/contextBroker.pid: no such file or directory
但是,当我创建这个文件时 - 它给了我这个:
contextBroker dead but pidfile exists.
starting contextBroker....pidfile not found
尝试使用 yum 和可用的最新 yum repo 配置重新安装它,但它似乎已关闭或未更新?- 给我 404 未找到。
编辑 1 yum repo 的配置取自 Orion 官方 Github:
[fiware-release]
name=FIWARE release repository
baseurl=https://nexus.lab.fiware.org/repository/el/7/x86_64/release
enabled=1
protect=0
gpgcheck=0
metadata_expire=30s
autorefresh=1
type=rpm-md
我尝试了多种运行 Orion 的方法。最常见的是:
contextBroker
除此之外,还使用了以下内容:
contextBroker -ngsiv1Autocast
service contextBroker start
编辑 2
解决方案
服务脚本和 yum 存储库 appart 的问题,请注意默认情况下 Orion 期望数据库在 localhost 中运行。因此,如果您的 MongoDB 实例在单独的服务器中运行,则必须使用该-dbhost
参数,例如:
contextBroker -fg -dbhost 10.1.1.1:27017
可以在此处找到有关 CB CLI 的额外文档。
编辑 1:如果您有一个 pid 文件,因为过去调用不干净退出(请注意日志跟踪中的 msg=),那么您必须在运行 CB 之前将其删除。例如:
rm -f /tmp/contextBroker.pid
contextBroker -fg -dbhost 10.1.1.1:27017
推荐阅读
- javascript - Bootstrap-datepicker onClose 事件问题
- sql - 递归查询以获取整个层次结构 [ORACLE]
- php - 卷曲忽略 CURLOPT_FILE
- r - R 中按组划分的树状图的颜色分支(没有 h 或 k 元素)
- c# - 如何处理应用程序中长时间运行的请求并允许用户在不冻结 UI 的情况下访问应用程序
- javascript - 通过Javascript访问s3对象时区分文件不存在和访问被拒绝
- for-loop - 如何使用动态创建的选项卡和 for 循环显示 ggplotly 图?
- python-3.x - python - 如何将一个窗口中计算的值访问到python tkinter中的另一个窗口?
- javascript - JavaScript Async/Await:尝试修改工作代码失败
- autodesk-forge - 无法获取 Forge 清单 - Autodesk Forge 查看器