Closed matteo-bon closed 6 years ago
I found the problem, I was setting iothub connection string as a parameter of proxy, but not as an environment variable (_HUB_CS). Starting proxy without arguments (after setting _HUB_CS with export
in bashrc) works.
I'm facing some problems while running the C# opcua client example.
Following the README:
I started the sample opcua server (NetCoreConsoleServer) in the UA-.NETStandard repository, with -a option
then I run the proxy (specifing the iothub connection string)
so the C# client, without providing arguments (so it connets to the sample opcua server), simply running dotnet run. However, the client exits with error "BadNotConnected".
The sample client in the UA.-NETStandard however works fine, connecting to sample sever.
I tried with another opcua server (with open62541 sdk), using my ip-address instead of localhost, but the problem is the same.
Here the commands:
dotnet run --project NetCoreConsoleServer.csproj -a #for UA-.NETStandard server
./proxyd -c 'HostName=<..>;SharedAccessKeyName=<..>;SharedAccessKey=<..>' #for proxy
dotnet run --framework netcoreapp2.0 #for opcua c# client
This is the error:![client_cs](https://user-images.githubusercontent.com/34126751/44331161-11aef480-a469-11e8-9b42-9c3908c53ca6.png)
Maybe the problem could be in the proxy, which gives this warning:![proxy](https://user-images.githubusercontent.com/34126751/44331581-293aad00-a46a-11e8-9381-1d75b451e816.png)
I'm not sure if this is the issue, maybe due to authentication problems the connection is refused.
I'm running Linux Mint 18 64 bit (kernel 4.4.0-34-generic). For C# client, I'm using branch '1.0.4-lts'; for proxy, I'm using 'master' and '1.0.2' branch.
Thanks