unable to connect from outside LAN

Support for the latest build of L2J Server, get help here with installations, upgrades, problems.
Do not post bugs reports here, use viewforum.php?f=77 instead.
There is no support for other server builds than the official provided by l2jserver.com
Forum rules
READ NOW: L2j Forums Rules of Conduct
Post Reply
suxa
Posts: 5
Joined: Sun May 17, 2009 5:20 pm

unable to connect from outside LAN

Post by suxa »

If you want to receive support we need this info to help you properly.
» Find Revision
L2J Revision 2943:
L2JDP Revision 5990:

helo,
so here is the problem: my computer is running on LAN and if i try log in in from other computers in LAN(using sever LAN ip), everything is fine, i can log in and play. but if i try to log in from a friend which is not in my LAN(using WAN server ip), it just not logs in. no error, no nothing. just dont log in.
Image
my LAN is something like that:
Image
my LAN ip from cmd>ipconfig is 192.168.0.101
my WAN ip from http://www.whatismyip.com is 217.17.81.72
my loginserver.properties looks like that

Code: Select all

# ---------------------------------------------------------------------------# Login Server Settings# ---------------------------------------------------------------------------# This is the server configuration file. Here you can set up the connection information for your server.# This was written with the assumption that you are behind a router.# Dumbed Down Definitions...# LAN (LOCAL area network) - typically consists of computers connected to the same router as you.# WAN (WIDE area network) - typically consists of computers OUTSIDE of your router (ie. the internet).# x.x.x.x - Format of an IP address. Do not include the x'es into settings. Must be real numbers.# ---------------------------------------------------------------------------  # ---------------------------------------------------------------------------# Networking# ---------------------------------------------------------------------------# ---------------------------------------------------------------------------# This is transmitted to the clients connecting from an external network, so it has to be a public IP or resolvable hostname# Common settings...# 127.0.0.1 - If you are playing alone on a test server# 192.168.x.x - This is if you are on a 192.168.x.x type network (behind a standard consumer router) and want other computers from JUST the internal network to be able to connect# x.x.x.x - WAN IP obtained from http://www.whatismyip.com/. This is if you want people outside your internal network to be able to connect to your server.# ---------------------------------------------------------------------------# Default: 127.0.0.1ExternalHostname = 217.17.81.72 # ---------------------------------------------------------------------------# This is transmitted to the client from the same network, so it has to be a local IP or resolvable hostname.# This can be the internal IP such as 127.0.0.1 or the computer's IP such as 192.168.x.x.# ---------------------------------------------------------------------------# Default: 127.0.0.1InternalHostname = 192.168.0.101 # Bind ip of the LoginServer, use * to bind on all available IPs# Default: *LoginserverHostname = * # Default: 2106LoginserverPort = 2106 # The address on which login will listen for GameServers, use * to bind on all available IPs# Default: *LoginHostname = * # The port on which login will listen for GameServers# Default: 9014LoginPort = 9014 # The delay in minutes after which the login updates the gameservers IP's (usefull when their ip is dynamic)# Default: 15IpUpdateTime = 15 
Any ideas?
Last edited by suxa on Sun May 31, 2009 8:02 am, edited 1 time in total.
benurb
Posts: 77
Joined: Sun Dec 10, 2006 2:00 pm

Re: unable to connect from outside LAN

Post by benurb »

you shouldn't disucss about your l2.ini here (maybe even delete it), cause client modding is illegal and server adress could easily be changed through hosts file without modding the client.
The other thing is that you should open the ports on your router (port 2106 and 7777 (both TCP) if you haven't changed port settings).
suxa
Posts: 5
Joined: Sun May 17, 2009 5:20 pm

Re: unable to connect from outside LAN

Post by suxa »

but i can log in to other servers on the internet, shouldn't that mean these ports are open?
Vapulabe
Posts: 271
Joined: Wed Mar 19, 2008 10:16 am

Re: unable to connect from outside LAN

Post by Vapulabe »

Does your computer have both the internal and external IP or is it the router which does some kind of port/ip forwarding to the private address ?
suxa
Posts: 5
Joined: Sun May 17, 2009 5:20 pm

Re: unable to connect from outside LAN

Post by suxa »

i think its router
Vapulabe
Posts: 271
Joined: Wed Mar 19, 2008 10:16 am

Re: unable to connect from outside LAN

Post by Vapulabe »

Then, connexions from outside looks like connexion from the router (LAN) to the L2J server... which sends the LAN IP as the server IP to the client...
suxa
Posts: 5
Joined: Sun May 17, 2009 5:20 pm

Re: unable to connect from outside LAN

Post by suxa »

im not quite sure what does that mean... :?

is it posible to make it working?
Vapulabe
Posts: 271
Joined: Wed Mar 19, 2008 10:16 am

Re: unable to connect from outside LAN

Post by Vapulabe »

Short answer : no

Long answer :
Your L2J-box is behind both a SNAT (for its internet access) and a DNAT (for the port forwarding) which means that from L2J point of view, the only IP used is the LAN IP which is in the private IP range.
When a client tries to connect to L2J, it reaches the Login server through the LAN IP so the Login server sends the LAN IP as Game Server IP.
As there is no protocol-tracking for L2 protocol (which would be very difficult if not impossible to do thanks to the crypto), the NAT box can't fix the IP and the clients gets a private IP as Game Server IP.
When it tries to connect to game server, the packets get dropped at the first router encountered as private IPs are not routable.
suxa
Posts: 5
Joined: Sun May 17, 2009 5:20 pm

Re: unable to connect from outside LAN

Post by suxa »

thanks for explanation. i will try run server from some other place.
mr.karrde
Posts: 19
Joined: Sun Mar 01, 2009 10:45 am
Contact:

Re: unable to connect from outside LAN

Post by mr.karrde »

Vapulabe wrote:Short answer : no
Depends on Router.
Just setting my Router to forward all necessary ports e.g. "WAN_IP Port 2106 <-> LAN_ServerIP Port 2106" works for me.
vaderek
Posts: 11
Joined: Tue Nov 11, 2008 1:34 am

Re: unable to connect from outside LAN

Post by vaderek »

Vapulabe, doesnt the external ip in the configs solve this problem? i mean the login forwards to the client whatever in that field or am i mistaken?
toastgodsupreme
Posts: 750
Joined: Sun Dec 07, 2008 7:01 pm
Location: Poland

Re: unable to connect from outside LAN

Post by toastgodsupreme »

I don't see why this is so complicated...

server.properties...
ExternalHostname = 217.17.81.72
InternalHostname = 192.168.0.101
LoginHost = 127.0.0.1
LoginPort = 9014
GameserverHostname = *
GameserverPort = 7777

loginserver.properties...
ExternalHostname = 217.17.81.72
InternalHostname = 192.168.0.101
LoginserverHostname = *
LoginserverPort = 2106
LoginHostname = 127.0.0.1
LoginPort = 9014


Unless you have something NOT in that picture, then there's no reason it shouldn't work assuming you have all the proper ports opened and forwarded.
Post Reply