Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Failure to create a new token during install of OpenHorzion #16

Open
oshadmon opened this issue Apr 17, 2024 · 1 comment
Open

Failure to create a new token during install of OpenHorzion #16

oshadmon opened this issue Apr 17, 2024 · 1 comment
Assignees
Labels
bug Something isn't working

Comments

@oshadmon
Copy link
Collaborator

I attempted to deploy a second EdgeLake instance on a different machine, however, learned the hard way that when the HZN_DEVICE_ID name on the second node is the same as the first, the the first EdgeLake instances goes down.

When trying to us a different HZN_DEVICE_ID, I get invalid-input error (directions shown below).

Steps:

  1. Update hzn related information in profile (Ubuntu bashrc)
export HZN_ORG_ID=alog
# export HZN_DEVICE_TOKEN= # specify a string value for a token
export HZN_DEVICE_ID=edgelake-demo
...
  1. Attempt to install using hello world
curl -sSL https://raw.githubusercontent.com/open-horizon/anax/v2.30/agent-install/agent-install.sh | bash -s -- -i anax: -c css: -p IBM/pattern-ibm.helloworld -w '*' -T 120 

Expect: Success
Actual: failed to create node with new Device ID

Node alog/edgelake-demo does not exist in the Exchange with the specified token, creating/updating it...
Error: bad HTTP code 400 from PUT http://132.177.125.232:3090/v1/orgs/alog/nodes/edgelake-demo?noheartbeat=true: invalid-input, Unrecognized field "isNamespaceScoped" (class com.horizon.exchangeapi.PutNodesRequest), not marked as ignorable (12 known properties: "pattern", "softwareVersions", "jsonFormats", "msgEndPoint", "token", "name", "nodeType", "userInput", "registeredServices", "heartbeatIntervals", "publicKey", "arch"])
 at [Source: (String)"{"token":"goYck5og-VccN7uRhIqPTLb18lVtGFN0_UaAYT9I2AfQhsb4OI1in7vk8aTeFhcsGqHj0XKEwrh75TYUKGV05yJ0","name":"edgex-demo","nodeType":"device","isNamespaceScoped":false,"pattern":"","registeredServices":null,"msgEndPoint":"","softwareVersions":{},"publicKey":"","arch":"amd64","userInput":null}"; line: 1, column: 292] (through reference chain: com.horizon.exchangeapi.PutNodesRequest["isNamespaceScoped"])
@oshadmon oshadmon added the bug Something isn't working label Apr 17, 2024
@oshadmon
Copy link
Collaborator Author

When installing OpenHorizon with code by @playground (Jeff from IBM) then I'm able to deploy a second EdgeLake operator using a different HZN_DEVICE_ID

curl -sSL https://raw.githubusercontent.com/playground/hzn-cli/main/install.sh --output install.sh && bash ./install.sh

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
bug Something isn't working
Projects
None yet
Development

No branches or pull requests

2 participants