cancel
Showing results for 
Search instead for 
Did you mean: 
cancel
Showing results for 
Search instead for 
Did you mean: 

Community Tip - Want the oppurtunity to discuss enhancements to PTC products? Join a working group! X

Error while connecting EMS to thingworx

bjadhav
6-Contributor

Error while connecting EMS to thingworx

getting error SDK: Error intializing socket connection.  Err = -1 while connecting EMS to thingworx

4 REPLIES 4
supandey
19-Tanzanite
(To:bjadhav)

Hi balkrishna, have you re-checked the configuration for the EMS? Are you configuring for the first time? Could you share which for which OS are you configuring the EMS and ThingWorx server version. How is the encryption setup for the EMS and on the ThingWorx server?

bjadhav
6-Contributor
(To:supandey)

Hi sushant,i'm configuring EMS for windows and thingworx 7.I have set encryption as none.

jamesm1
5-Regular Member
(To:bjadhav)

Can you send your whole EMS config file (you can retract the appKey, if you'd like)?

Here is a copy of a working EMS config with file transfer and tunneling to a localhost instance with no encryption and an auto bind to a thing named StandardRemoteThing, the appKey, host, and potentially the virtual directory would need to be updated:

{

  "ws_servers": [{

  "host": "localhost",

  "port": 80

  }],

  "appKey": "92d68c74-4bf3-42c8-ab7c-0cb602d11873",

  "ws_connection": {

  "encryption": "none",

  "verbose": true

  },

  "logger": {

  "level": "TRACE",

  "publish_directory":"/_tw_logs/",

  "publish_level":"TRACE",

  "max_file_storage":2000000,

  "auto_flush":true

  },

  "certificates": {

  "validate": false,

  "allow_self_signed": true

  },

  "auto_bind": [{

  "name": "StandardRemoteThing",

  "gateway": false

  }],

  "tunnel": {

  "buffer_size": 8192,

  "read_timeout": 10,

  "idle_timeout": 300000,

  "max_concurrent": 4

  },

  "file": {

  "buffer_size": 128000,

  "max_file_size": 8000000000,

  "virtual_dirs": [

  {"tw": "c:\\filestest"}

  ]

  }

}

posipova
20-Turquoise
(To:bjadhav)

Hi,

You may validate your json at JSONLint - The JSON Validator.

Have you renamed your config file to config.json? What is the port number you are using? If no proxy is set up, you should be using the same as in when accessing the composer through the browser (e.g, 80, 8080, .. )

Top Tags