Hi Folks,
I use Loggernet to remotely connect to my loggers via an NL100 connected to a freewave radio network. Yesterday the the connection only worked at 7am and then was down for a few hours. Today it is doing the same. I copied this info from a log file. Any idea what causes an "unexpected socket close"? Are there other things in the log file I should be looking at? I have another network running off a seperate NL100 which is not having this same problem.
From
Log file
"2009-10-20 8:07:46 AM","NL100-IARC","S","opening","137.229.94.98,6784"
"2009-10-20 8:07:46 AM","NL100-IARC","S","Provider opened"
"2009-10-20 8:07:46 AM","NL100-IARC","S","Device dialed"
"2009-10-20 8:07:46 AM","Repeater","F","transaction failure","unreachable destination","check/set clock"
"2009-10-20 8:07:46 AM","NL100-IARC","F","unexpected socket close"
Thanks
新对话如下:
This problem is still occurring today. I have never seen these error messages before. I can telnet in to the NL100 and ping it. Do you think this is aloggernet issue or something else?
Thanks
"2009-10-21 8:05:00 AM","NL100-IARC","S","opening","137.229.94.98,6784"
"2009-10-21 8:05:00 AM","NL100-IARC","S","Provider opened"
"2009-10-21 8:05:00 AM","NL100-IARC","S","Device dialed"
"2009-10-21 8:05:00 AM","PakBusPort_2","S","link lost","4094","1"
"2009-10-21 8:05:00 AM","PakBusPort_2","S","link lost","4094","200"
"2009-10-21 8:05:00 AM","PakBusPort_2","S","link lost","211","221"
"2009-10-21 8:05:00 AM","PakBusPort_2","S","link lost","211","200"
"2009-10-21 8:05:00 AM","PakBusPort_2","S","link lost","4094","211"
"2009-10-21 8:05:00 AM","PakBusPort_2","S","link lost","4094","221"
ETC, ETC.
新对话如下:
Hello BNZLTER,
I am able to connect to at least two devices in your PakBus network, and see all the others (or what I presume is "all" of the others).
This error message can result from a variety of reasons. Usually, it is that the socket times out, or is refused/reset, by the device you are try to connect to, but there are other reasons as well (it's a fairly generic message).
If you close LoggerNet and restart it, are you able to connect? If so, one thing to try is disabling the Cache IP Address setting on the Hardware screen for the IP port. This will ensure that LoggerNet resolves the IP address each time it attempts connection.
You may also be experiencing latency on your network (which maybe the case since I can connect but you can't?). If so, adding extra response time to the PakBus port may help (a second or two is all that is needed).
Lastly :) If some other LoggerNet user is connected to the datalogger network and their PakBus port is set to "Always Open", this would lock out any other user. Older versions of LoggerNet had this setting enabled by default, but at some point (3.4? I'd have to check the change logs...) it was set to be unchecked by default (so PakBus port closed).
Give these few things a try and let me know if you have success.
Dana W
新对话如下:
Thanks Dana,
The only one I can't rule out is whether someone else is using loggernet right now. I know of 3 people who know this IP and e-mailed them all. Will it only affect this link if they have this IP in their loggernet set-up?
Restarting loggernet gets me nothing, I turned off the IP cache, and added 2 seconds to the ERT.
I can see the pakbus port flash online for less than a second while watching the status window and trying to connect manually.
I agree that it may be another user b/c it seems to happen during the work day.
I wonder how you were able to connect and I am not? Any ideas on this one?
Thanks
Brian
新对话如下:
Something I noticed, not sure if it's relevant. Shouldn't 137.229.94.98,6784 be 137.229.94.98:6784?
IslandMan
新对话如下:
I wonder how you were able to connect and I am not? Any ideas on this one?
The one thing I thought of after I responded yesterday is that it could also be because all of the PakBus IDs for LoggerNet are set to 4094. This is the default LN PakBus address. I have mine set to 4084, since I also have a laptop I use to connect to my network and I cause myself headaches at times.
All PakBus devices in a network need to have unique addresses -- including the LoggerNet servers.
The PakBus address is set in the LoggerNet Setup window, under a menu option (in LN 4, it is the Options menu).
And now that I type all that... I just tried to connect and I am getting the Unexpected socket error. I can ping, and also tracert all the way to the ip (roof1.....) so it would appear the NL100 is refusing/closing the connection. I would definitely make sure someone else doesn't have it "locked up".
Dana W.
新对话如下:
There are two methods for configuring the NL100 in order to service PakBus dataloggers:
- You can configure the NL100 port (CS I/O or RS232) to work with the PakBus service. By default, the PakBus routing service on the NL100 is for port 6785.
- You can configure the NL100 port as a serial server. By default, the RS232 serial server is bound to port 6784 on the NL100. Given that is the report used in your logs, I expect that this is the option that you are using.
In the first case, the NL100 will allow multiple PakBus/TCP connections and will act as a PakBus router between those connections provided that each of the PakBus/TCP clients has a unique PakBus address. If the address is not unique, the NL100 (and the CR1000 for that matter) is likely to hang up the connection during the link verification phase. In this case, I would have expected to see "hello" messages reported in your comms log.
In the second case, the NL100 can service only one serial server client at any given time. It further has the somewhat nasty habit of accepting a second attempt and then closing that socket. This would lead to the sort of messages that you described in your post. As I mentioned above, this could be addressed by changing the configuration setting for the port on the NL100 so that it is associated with the NL100's PakBus service.
* Last updated by: jtrauntvein on 10/22/2009 @ 2:27 PM *
新对话如下:
So we did find someone running some old cron jobs attempting to connect to our sites through this IP (though unsuccessfully as they are all PAKBUS loggers now). I also changed the port, based on Bob's suggestion, to makes sure noone was accidentally getting to our NL100. CSI, e-mail if you need the new port number for testing.
IN regards to changing the NL100 to work with the PAKBUS service, I'm not sure if this will work for us. Our NL100 is connected, through the RS232 port, to a free wave radio. All of our sites have unique PAKBUS addresses but can we use this setup when using a freewave? If so, that would seem like an improvement. Can someone comment on this?
BTW, I am currently able to connect to one site without a problem at this time.
新对话如下:
Ok, all is well in the radio and NL100 world again. I am still curious about changed the operating mode of the NL100 though. If you could send me some details on doing this that would be great.
Thanks
Brian
新对话如下:
When the NL100 is set up as a PakBus router, it will be able to handle multiple requests from PakBus devices (as long as PakBus IDs are unique). When set as a serial server, you can look at it sort of like a direct connect -- only one device can be connected at a time.
The NL100 manual is really the only document available on using the device in a PakBus network (that and the PakBus networking guide for a description of PakBus communication). If you have specific questions, you might want to post them.
Regards, Dana W.