Skip to main content

[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index] [List Home]
Re: [volttron-dev] Challenges using the Forward Historian
  • From: "Allwardt, Craig H" <Craig.Allwardt@xxxxxxxx>
  • Date: Wed, 30 Oct 2024 22:10:03 +0000
  • Accept-language: en-US
  • Arc-authentication-results: i=1; mx.microsoft.com 1; spf=pass smtp.mailfrom=pnnl.gov; dmarc=pass action=none header.from=pnnl.gov; dkim=pass header.d=pnnl.gov; arc=none
  • Arc-message-signature: i=1; a=rsa-sha256; c=relaxed/relaxed; d=microsoft.com; s=arcselector10001; h=From:Date:Subject:Message-ID:Content-Type:MIME-Version:X-MS-Exchange-AntiSpam-MessageData-ChunkCount:X-MS-Exchange-AntiSpam-MessageData-0:X-MS-Exchange-AntiSpam-MessageData-1; bh=2DIkdWHfx35KyptxWUddEzpjcFWZT32f8RYpXwPXC5I=; b=SJU5gV3Dy13oRDcVSjWU8DliEJXo/Am9qYKXfg1QeaTmjGmKR7St95kE8arF+A3GlaM4H0dm/xcdjMRLbz97Rw88YAiSQ7cuYCxkDA4nDqRH3Lw3a6iQnYGdzQTe8F0S0zFokTZOI0TVg7sRzciA+kvhIG8+XiChQhdq3FU8SwHKWA48zghm9HotGavBmyEMylketi4aK+JOOCu4YXZix/w9gvS3187pR2Jl/6E1lxSfqtG8lzXrXyXYetMvQHxNAh9aNwD1RezTokShNKFJ7qdNqy30G/UO3ir33rQyOCl5BZWOhlcs+w2XV0nJ7PEvir5cS3rZVjmamPH+WJrqTA==
  • Arc-seal: i=1; a=rsa-sha256; s=arcselector10001; d=microsoft.com; cv=none; b=fqpV/O+7fmkqy33OYW3cbjEwSBuZxyt177Aw0Yf9ddwnDa2PearY+GCTYzvPVo2B90i+s9xOhrvskXp018PXmuL/SXN6uGCvmL6ChGOVEC6hwRk+tXxAXLagViM2p+gtgeRqae4krzdqvVSf6wD2QJDMM91eB/P7boqRjkjapb5jBi0nKImoXCPNMHkFNpnaorxwpRv3LAiYtWSNJAR0LoY9t/QjquAf5wUwuocxsdEBplb/6wUILSpG6EUQRID2PeUsZxhzAZRZVJG7zdPdN1balw9Y6DGwLQ6WABDzkp5/DiXvE+hMJH+me8g7FtIEh9FTjeMyAel9NXvyypS50g==
  • Delivered-to: volttron-dev@xxxxxxxxxxx
  • List-archive: <https://www.eclipse.org/mailman/private/volttron-dev/>
  • List-help: <mailto:volttron-dev-request@eclipse.org?subject=help>
  • List-subscribe: <https://www.eclipse.org/mailman/listinfo/volttron-dev>, <mailto:volttron-dev-request@eclipse.org?subject=subscribe>
  • List-unsubscribe: <https://www.eclipse.org/mailman/options/volttron-dev>, <mailto:volttron-dev-request@eclipse.org?subject=unsubscribe>
  • Thread-index: AQHbKusuEVEqJfu0QUacx1k8ut0uVLKfnxWggAATLwCAACYsAIAAAoUw
  • Thread-topic: [volttron-dev] Challenges using the Forward Historian

Ok now to actually answer the question you posed.

 

No the address should just be 192.168.55.55

 

This will populate the record on the receiver’s auth.json file such as the following:

    {

      "domain": null,

      "address": "127.0.0.1",

      "mechanism": "CURVE",

      "credentials": "VqtDy03vqbgRZL8p0UdamVSP4O4OLtis9qAAp6-wbDI",

      "groups": [],

      "roles": [],

      "capabilities": {},

      "rpc_method_authorizations": {},

      "comments": null,

      "user_id": "9059a437-e399-4813-990a-36ac953753b9",

      "identity": "forward_from_first",

      "enabled": true

    }

 

In my example I use 127.0.0.1 but that could be any address.  Note if you are not seeing ANY connection at all on the receiver then it is likely that your serverkey is not correct in the forwarder config itself.

To get that serverkey, you use the receiver volttron and execute vctl auth serverkey

 

 

If you have a failure then you know that the server key is correct, but either you have the ip address incorrect or the publickey of the sender volttron isn’t authorized on the receiver.   You will see the following error in the receiver’s logs

 

2024-10-30 14:51:39,192 () volttron.platform.auth.auth_protocols.auth_zmq [263] INFO: authentication failure: userid='6fcade90-ed17-4c8b-b94e-f18bdff752c8', domain='vip', address='127.0.0.1', mechanism='CURVE', credentials=['VqtDy03vqbgRZL8p0UdamVSP4O4OLtis9qAAp6-wbDI']

 

Verify that the credentials are the publickey of the forwarder using the sender volttron’s command vctl auth publickey uuid

 

{

    "destination-vip": "tcp://127.0.0.2:22918",

    "destination-serverkey": "NNInd2qabB75mW3uweg2NZrXGinqCk3yNRCYN74FAHY"

}

 

Successful connection on the receiver should look like the following

 

2024-10-30 14:59:24,521 () volttron.platform.auth.auth_protocols.auth_zmq [246] INFO: authentication success: userid=b'3175710a-d0c9-44ad-b601-90d186032579' domain='vip', address='127.0.0.1', mechanism='CURVE', credentials=['VqtDy03vqbgRZL8p0UdamVSP4O4OLtis9qAAp6-wbDI'], user='9059a437-e399-4813-990a-36ac953753b9'

 

From: volttron-dev <volttron-dev-bounces@xxxxxxxxxxx> On Behalf Of Allwardt, Craig H via volttron-dev
Sent: Wednesday, October 30, 2024 3:09 PM
To: Lazlo Paul <lazlopaul17@xxxxxxxxx>
Cc: Allwardt, Craig H <Craig.Allwardt@xxxxxxxx>; volttron developer discussions <volttron-dev@xxxxxxxxxxx>
Subject: Re: [volttron-dev] Challenges using the Forward Historian

 

Ok now to actually answer the question you posed.

 

No the address should just be 192.168.55.55

 

This will populate the record on the receiver’s auth.json file such as the following:

    {

      "domain": null,

      "address": "127.0.0.1",

      "mechanism": "CURVE",

      "credentials": "VqtDy03vqbgRZL8p0UdamVSP4O4OLtis9qAAp6-wbDI",

      "groups": [],

      "roles": [],

      "capabilities": {},

      "rpc_method_authorizations": {},

      "comments": null,

      "user_id": "9059a437-e399-4813-990a-36ac953753b9",

      "identity": "forward_from_first",

      "enabled": true

    }

 

In my example I use 127.0.0.1 but that could be any address.  Note if you are not seeing ANY connection at all on the receiver then it is likely that your serverkey is not correct in the forwarder config itself.

To get that serverkey, you use the receiver volttron and execute vctl auth serverkey

 

 

If you have a failure then you know that the server key is correct, but either you have the ip address incorrect or the publickey of the sender volttron isn’t authorized on the receiver.   You will see the following error in the receiver’s logs

 

2024-10-30 14:51:39,192 () volttron.platform.auth.auth_protocols.auth_zmq [263] INFO: authentication failure: userid='6fcade90-ed17-4c8b-b94e-f18bdff752c8', domain='vip', address='127.0.0.1', mechanism='CURVE', credentials=['VqtDy03vqbgRZL8p0UdamVSP4O4OLtis9qAAp6-wbDI']

 

Verify that the credentials are the publickey of the forwarder using the sender volttron’s command vctl auth publickey uuid

 

{

    "destination-vip": "tcp://127.0.0.2:22918",

    "destination-serverkey": "NNInd2qabB75mW3uweg2NZrXGinqCk3yNRCYN74FAHY"

}

 

Successful connection on the receiver should look like the following

 

 

 

 

 

 

From: Lazlo Paul <lazlopaul17@xxxxxxxxx>
Sent: Wednesday, October 30, 2024 12:44 PM
To: Allwardt, Craig H <Craig.Allwardt@xxxxxxxx>
Cc: volttron developer discussions <volttron-dev@xxxxxxxxxxx>
Subject: Re: [volttron-dev] Challenges using the Forward Historian

 

Yes! I am including the credential. I just did not reproduce it here because I did not have a question on it. 

 

On Wed, Oct 30, 2024 at 11:36 AM Allwardt, Craig H <Craig.Allwardt@xxxxxxxx> wrote:

Just checking, but the line you mentioned continues past what you wrote here…

 

vctl auth add --address <address of source instance where forwarder is installed> --credentials <publickey of installed forwarder agent>

 

The credentials are what is 100% required.  The address is added protection.

 

Craig

 

From: volttron-dev <volttron-dev-bounces@xxxxxxxxxxx> On Behalf Of Lazlo Paul via volttron-dev
Sent: Wednesday, October 30, 2024 9:46 AM
To: volttron-dev@xxxxxxxxxxx
Cc: Lazlo Paul <lazlopaul17@xxxxxxxxx>
Subject: [volttron-dev] Challenges using the Forward Historian

 

Check twice before you click! This email originated from outside PNNL.

 

Hi All,

 

I am setting up two volttron instances on the same LAN, both are using ZMQ. I have one main volttron instance on a more performant computer, and one volttron instance running on a Raspberry Pi. Both are running Volttron 9.0

 

I am attempting to set up the Forward Historian, but can not make the connection from the platform on the Raspberry Pi to the main platform. I have followed the instructions in the following documentation: https://volttron.readthedocs.io/en/9.0.1/agent-framework/historian-agents/forwarder/forward-historian.html.

 

Is there something I might be missing? For the step in the documentation that calls for `vctl auth add --address <address of source instance where forwarder is installed>` should the address be in the format 192.168.55.55:22916? Is there a method for me to more productively debug this? 

 

Thank you for your help!
Lazlo


Back to the top