Technology and Beyond (TaB)
Frequent queries of status info - Printable Version

+- Technology and Beyond (TaB) (http://tab.d-thinker.org)
+-- Forum: Data Thinker (/forumdisplay.php?fid=896)
+--- Forum: Resources (/forumdisplay.php?fid=211)
+---- Forum: Completed work (/forumdisplay.php?fid=275)
+---- Thread: Frequent queries of status info (/showthread.php?tid=3937)


Frequent queries of status info - LINGU2011-2012 (LINGU2) - 08-03-2015 02:06 PM

In some settings, we need to frequently query the status of a thinker. For example, the NGSCloud needs to know if a thinker is still running, and the thinker is behind a firewall -- the querying entity and the thinker are at different parts of the Internet. The current solution using SSH to periodically connecting into the thinker and running 'dt status' is quite iffy.

We'd better have a mechanism for efficient and reliable status query across the Internet.


RE: Frequent queries of status info - LINGU2011-2012 (LINGU2) - 08-03-2015 02:10 PM

IMHO, we need a 'status daemon' so that a client can query the status repeatedly in one TCP connection.


RE: Frequent queries of status info - LINGU2011-2012 (LINGU2) - 08-07-2015 01:09 PM

Executing remote commands to tbg15 with 1 ssh session, rather than 1 command 1 ssh session, helps. However, if commands are to the other 18 vpcs in class A internal ips, the ssh channels to them need to go thru the ssh channel of tbg15. This is not viable, especially true for real-time functions like dashboard (frequently executing top to all vpcs).
After a few successful executions, the ssh channels are blocked somehow. Of course, putting random delay between the executions help but is not scientific enough.
.


RE: Frequent queries of status info - LINGU2011-2012 (LINGU2) - 08-07-2015 04:20 PM

(08-07-2015 01:09 PM)LINGU2011-2012 (LINGU2) Wrote:  Executing remote commands to tbg15 with 1 ssh session, rather than 1 command 1 ssh session, helps. However, if commands are to the other 18 vpcs in class A internal ips, the ssh channels to them need to go thru the ssh channel of tbg15. This is not viable, especially true for real-time functions like dashboard (frequently executing top to all vpcs).
After a few successful executions, the ssh channels are blocked somehow. Of course, putting random delay between the executions help but is not scientific enough.
.
Forget about it, it turns out to be a 'top | grep' problem due to different versions of 'top' installed on tbg15 and vpcs.
Still, some of them fail: "Error: (SSH) Channel open failure: open failed", which is from the nodejs ssh library.
In conclusion, with a persistent ssh channel to tbg15, frequent(period 10s)-and-low-load(top) commands can be executed on vpcs via temporary channels (ssh vpc-ip <command>) within the persistent ssh channel with some reliability.
.


RE: Frequent queries of status info - amoners - 08-31-2015 10:23 AM

Moved to 'Completed work'.