LabVIEW

cancel
Showing results for 
Search instead for 
Did you mean: 

Web Server consolidation behind router/firewall

Hello.  I'm hoping someone might be able to help (or at least point me in the right direction) with something I'm trying to set up in my lab.  We've got four different computers, each with LabView (I believe they're all on 8.0, but it's possible one of them might be on 6.1).  Each of these computers has a VI running 24/7 monitoring the pressure of a piece of equipment.  It would be nice to be able to check up on these pressure remotely (using the LabView web server, for example) so that we don't have to come in to the lab every time we want to check on the pressures.

The problem is that all of these computers are on a local network behind a router/firewall.  I can set up port forwarding on the router so that one of the computers can be accessed (and that works just fine), but that means the three other computer are inaccessible from outside the local network.  A software VPN setup would probably allow us to do what we need to do, but the client software for such a thing isn't exactly cheap (at least not that I've been able to find for the router we are currently using).

I've been trying to figure out if LabView has the ability to export the .snap images of the front panels to a remote server (e.g. another computer outside of the local network with a static IP), but I haven't found anything concerning such.  Another possibility would be to run LabView on that same remote server, and have the monitoring computers behind the router/firewall export data to it on some sort of schedule, and then it would be easy to set up the remote server with a standard LabView web server interface.  Is this something that TCP/IP communication might be useful for?  I have a lot of experience with LabView, as well as networking and all that, but little experience with servers and data communications and such.  Anyone have any suggestions?  I'm all ears.

Thank you,
Tyler Grassman
0 Kudos
Message 1 of 8
(3,365 Views)
Hello Tyler,
 
Have you considered using Shared Variables ??
But since you are having networking issues, you might run into similar problems here too, as your firewall might block the port that the shared variable engine uses.
I would suggest it would be much simpler for you to talk to your IT department unblock the required ports.
 
Chetan K
 
0 Kudos
Message 2 of 8
(3,347 Views)
Thanks for your reply to my post, and thanks for the suggestions.  However, it's not really networking issues that I'm having trouble with.  Well, I mean, the fact that we're behind the router/firewall is an issue, but I can open/forward the HTTP port (80) to a particular computer, which I can have LabView Web Server running on, and that all works fine.  The issue that I'm trying to figure out is how to export either the Web Server .html or .snap files from all the computers to one computer, which will be running Web Server.

In thinking about this issue a little more, I realized that one of the 4 computers I mentioned can very well also be the main Web Server (the computer to which port 80 is being forwarded), and then all I need to do is export the the Web Server monitoring files (or the pressure data) from the remaining three computers to the main server computer.  It doesn't seem as though there is a way to do this (i.e. export the .snap files to a remote server).  Although, maybe there is a way to code the VI.html file such that the .snap files could be read remotely?  Or perhaps I could set up some sort of TCP/IP communications between the VI's on all the computers such that the main server will be actively listening, and the other three computers can send it a data update on some schedule (say every minute)?  I'll continue to look into this, but any suggestions will be greatly appreciated.

Thanks again,
Tyler
0 Kudos
Message 3 of 8
(3,344 Views)
Okay, I guess as an answer to my own query, I figured out a way to do it.  Essentially all I did was wrote a very simple web page with links to the URLs of the Web Server pages on the different computers (to which I assigned static IPs).  That way I can use my one computer that I have port 80 forwarded to as sort of a gateway to the other computers.  It works pretty well, actually, simple as it may be.

-Tyler
0 Kudos
Message 4 of 8
(3,342 Views)
Oh, wait, I got ahead of myself...  It doesn't work after all.  I was testing it from within the LAN, no outside of it.  When coming in from the outside the URLs in the links then don't register.  Got ahead of myself.  Okay, well, any suggestions?  Thanks!

-Tyler
0 Kudos
Message 5 of 8
(3,340 Views)
Tyler,

There are probably more clever approaches lurking...but one idea is to create a "Viewer" VI on your port-forwarded LabVIEW machine whose purpose is to establish connections with the static IP machines, request panel images from the VIs running on those machines, and display the results on its front panel.

Attached (LV 7.1) is a version that works when everything is running on one machine.  If you embed Viewer.vi in a Web page, you end up with an interface that allows you to dial up the panels of Child1.vi and Child2.vi, if they're in local memory.  You can extend the concept to view VIs from the other machines on your LAN.

Good luck,
John
0 Kudos
Message 6 of 8
(3,334 Views)
John,

Thanks for the suggestion, I may give it a try.  In the meantime, however, I figured out how to make my original attempt to work.  Simply enough, all I ended up doing was to configure the LabView Web Server on each of the machines to use a different port number (something nice and high, unused), and then just forwarded those port numbers through the firewall to each static IP'ed computer appropriately.  Yeah, not exactly "clever" per se, but it works well enough.  I do like the idea of using a single machine acquiring the images (or even just the data) from the other computers, so perhaps I'll go ahead and work on that, but for the time being what I'd got will work.  Thanks again for the suggestion.

-Tyler
0 Kudos
Message 7 of 8
(3,331 Views)
Tyler,
 
That WAS a clever solution. Thanks for sharing it on our forums. Smiley Happy
 
Regards,
Chetan K
Application Engineer
National Instruments
 

Message Edited by CKap on 11-21-2006 09:21 AM

0 Kudos
Message 8 of 8
(3,321 Views)