Server behind router

Discussions about product bugs & problems!
Note: This is no replacement for the Official ETM Support!
7 posts • Page 1 of 1
MattPaulissen
Posts:26
Joined: Fri Feb 19, 2016 9:27 pm

Server behind router

Post by MattPaulissen »

I'm having trouble connecting DIST and the Mobile UI when my OA server is running behind a router.

I just want to tackle one problem at a time right, so I'm focusing on the Mobile UI. I have the following ports forwarded from my router to my OA server:

80
4777
4897
4998
5678

In my config file I have the following:

event = "192.168.0.51"
data = "192.168.0.51"

messageCompression = "zlib-bzip2"

[opcuasrv]
disableSecurity = 1
enableAnonymous = 1
[opcua]
server = "ss"
[mod_1]
tcpServerPort = 9998
[httpServer]
indexPage = “/data/ulc/start.html"
uiArguments = "-p startPanel.pnl -iconBar -menuBar -user demo:"
[webClient]
mobileRootPanel = "startPanel.pnl"


Doing this I can get the ULC UX to work just fine. My android phone using Mobile UI can't connect to port 4897, but I noticed that it was aiming at the local IP of the server rather than the static public IP from my router. So I added a config.webclient and put this in it:

[general]
proj_version = "3.15"
langs = "en_US.utf8"

data = "xx.xx.xx.xx"
event = "xx.xx.xx.xx"

Where the IP in data and event are set to my static public IP address. When I do this it still fails, but in the pmon I see the following:

WCCILproxy (1), 2018.04.18 10:19:35.452, PARAM,WARNING, 209, Cannot find the host in the list of the allowed-hosts: (xx.xx.xx.xx:4897)

So the proxy sees a connection coming in, but it is the public IP address of my router(possibly because of port forwarding from the router to the internal IP address of my OA server).

Right now mxProxy is running on the same server. I know that I can run it separately, and place it in the DMZ and I'm assuming this is the recommended setup that will work; however, I'm running out of PCs to bring up this demo, and it also makes me wonder what I would do with a remote server behind a cellular modem.

So I guess my question is really how are you supposed to setup an OA server behind a router doing port forwarding? Are there some [proxy] config settings I need to be making? Any help is really appreciated, because my plan is to build demo labs at all of our offices and connect them all together.

tmalone
Posts:192
Joined: Mon Nov 22, 2010 11:21 pm

Re: Server behind router

Post by tmalone »

create a config.webclient file.

In there put in the

[general]
data = "ip-of-router:forwardedPort"
event = "ip-of-router:forwardedPort"

agruber
Posts:147
Joined: Tue Sep 07, 2010 2:52 pm

Re: Server behind router

Post by agruber »

Hi,

If you use the proxy, it seems you do, all external WinCC OA communication goes through the proxy.

So you need to tell the UI the internal data/event host and the proxy address where they can be reached.

So in your config.webclient the following part should work, though I have only ever tested this with internal hostnames, not with ip addresses.

Code: Select all

event = "192.168.0.51"
data = "192.168.0.51"

mxProxy = "192.168.0.51 xx.xx.xx.xx:5678 cert"
noReverseLookup = 1
BR, Andreas
Customer Care

MattPaulissen
Posts:26
Joined: Fri Feb 19, 2016 9:27 pm

Re: Server behind router

Post by MattPaulissen »

That worked with the host name and the IP address! I can get on now, but it just shows me the standard WinCC OA start screen. It isn't showing me the panel I have set under mobileRootPanel.

agruber
Posts:147
Joined: Tue Sep 07, 2010 2:52 pm

Re: Server behind router

Post by agruber »

If the config.webclient exists, the normal config file is ignored for a Desktop UI or Mobile UI. So you need to make UI relevant settings in the config.webclient too (like the mobileRootPanel = "startPanel.pnl" entry).

BR, Andreas
Customer Care

MattPaulissen
Posts:26
Joined: Fri Feb 19, 2016 9:27 pm

Re: Server behind router

Post by MattPaulissen »

Got it. So I can use all the configs I'd normally use under [webClient] then?

I'm assuming to fix my dist problem I just need to include the same mxProxy config settings like I did for the web client? I think once I have this up and running I'll start trying to create an actual proxy server inside the DMZ and hide all my other servers. That seems much simpler to configure on the network side and much more secure.

Edit: Also, if I want to use compression do I just make that entry under general, or do I need to place it under every manager I want to use it?

Gertjan van Schijndel
Posts:634
Joined: Mon Aug 02, 2010 10:37 am

Re: Server behind router

Post by Gertjan van Schijndel »

The config.webclient is provided to webclients (DesktopUIs/MobileUIs) instead of the config file. You can use all sections and config entries that you can also use in the config file (not just the webClient section).

The compression config entries could also be used in the general section.

7 posts • Page 1 of 1