在多个 VOLTTRON Historian Framework 之间切换或添加

Switching between or adding multiple VOLTTRON Historian Framework

我在我的 Volttron 平台上安装了以下代理:

AGENT - IDENTITY - TAG

sqlhistorianagent-3.6.1 - platform.historian - platform_historian

遵循文档:http://volttron.readthedocs.io/en/4.1/core_services/historians/index.html

我尝试按照此文档安装另一个 Historian -(Mongo Historian)。:http://volttron.readthedocs.io/en/4.1/core_services/historians/Mongo-Historian.html#prerequisites

下面是在 Ubuntu 上安装 mongodb 所遵循的步骤:

先决条件

1.Mongodb

cd volttron
. env/bin/activate
sudo scripts/historian-scripts/root_install_mongo_ubuntu.sh

2.Mongodb 连接器

pip install pymongo

安装成功。但是,我正在使用以下命令来检查已安装代理的状态。

volttron -l log1&
volttron-ctl status

出于某种原因,它没有出现在我的代理下。

问题:

是否可以在同一个 Volttron 中同时使用两个代理?如果不是, 请让我知道如何在历史代理之间切换(即用 Mongodbagent 替换 Sqlhistorianagent)或启用 Mongodbagent 代理?

值得一提的是我安装了"Crate Historian"

pymongo 是连接到 mongo 数据库所必需的。您仍然需要安装 MongodbHistorian。

您可以查看 https://github.com/VOLTTRON/volttron/blob/master/scripts/historian-scripts/start-historian-mysql.sh 的示例,了解安装代理本身需要执行的操作。以下假设您是 运行 它来自 volttron 目录的根目录,并且您已经修改了 mongodbhistorian 目录中的配置文件以连接到您的 mongodb 实例。

#!/usr/bin/env bash

if [ ! -e "./volttron/platform" ]; then
    echo "Please execute from root of volttron repository."
    exit 0
fi

export HIST="services/core/MongodbHistorian"
export HIST_CONFIG="$HIST/config.mongodb"
SCRIPTS_CORE="./scripts/core"

$SCRIPTS_CORE/start_historian.sh 

还需要注意的一件事是,不久我们会将 master 更新为 releases/5.0rc,因此安装方法将发生变化。