Remoting over Internet with server behind gateway

M

Michal Rizek

Hi,
i have our server located on local network, but i need to be albe to connect
it from internet as well.
I am able to connect it from Internet when i set port forwarding on gateway
and then set "machineName" property of tcp channel to "my.gateway.addr".

<channel port="61612" timeout="2000" ref="tcp" machineName="my.gateway.addr"
useIpAddress="false">

Problem is that with this settings, i am unable to connect to server from
local network - I need to setup machineName to "gate.firma.cz" for
connections comming fom Internet and to "localname" for local connections. I
tried to add second channel to <channels> section, but it seems .NET is not
able to deside which chanel to use and always use first one.

<channels>
<channel name="T2" port="61613" timeout="2000" ref="tcp">
<serverProviders>
<formatter ref="binary" typeFilterLevel="Full" />
</serverProviders>
</channel>

<channel name="T1" port="61612" timeout="2000" ref="tcp"
machineName="my.gateway.addr" useIpAddress="false">
<serverProviders>
<formatter ref="binary" typeFilterLevel="Full" />
</serverProviders>
</channel>
</channels>

What am i doing wrong?
Any idea how to make work so i can connect to server from within local
network as well as from the Internet?

Thanks
 

Ask a Question

Want to reply to this thread or ask your own question?

You'll need to choose a username for the site, which only take a couple of moments. After that, you can post your question and our members will help you out.

Ask a Question

Top