Jump to content

IP/Realm Connection Issues


Guest Noaru

Recommended Posts

Hello I'm having some issues trying to connect to my server, I'm trying to set it up so I can login locally, and have other people login externally from outside my local network. However I'm having some issues, I cannot seem to login on both sides. I.e. If I set it up so I log in, no one can connect externally, and if I set it up externally, I can't login (locally). Apparently my Router doesn't support NAT Loopback, but I thought there's a work around this entire issue some where. I even tried making two realms on the realmlist and having my External IP and Local IP set up so that I can login one way and external users can login their way, however neither of those tend to work. Where if I set it up with my Local IP (first listed server) then second is external IP address, only I can login. Then if I have that reversed where the external IP is first and the local IP is second, only external access is permitted while the second realm (local) doesn't show up at all. So I hope you can understand all this, I've tried this many many ways, and with no success.

Note: My server is DMZ-ed so, no PF needed and the Server is also on another computer on my network so, no localhost/127.0.0.1 confusion.

Link to comment
Share on other sites

Can you post additional information,

1) ports you have forwarded on your router

2) type of router (if its similar to any of the ones of I've dealt with at home and work, I may be able to help)

2) records in your realmd.realmlist table

3) the lines in your mangos.conf and realmd.conf, specifically BindIP and Port lines

I was going to suggest reading the guide on setting up mangos for intranet and internet use, but it sounds like you may have done so already

Link to comment
Share on other sites

Can you post additional information,

1) ports you have forwarded on your router

2) type of router (if its similar to any of the ones of I've dealt with at home and work, I may be able to help)

2) records in your realmd.realmlist table

3) the lines in your mangos.conf and realmd.conf, specifically BindIP and Port lines

I was going to suggest reading the guide on setting up mangos for intranet and internet use, but it sounds like you may have done so already

Well, I have had the ports in the Database (8085) and everything from the config files, (inc SQL DB), forwarded.

However the system which I have it on is being DMZ Hosted and therefore is outside the firewall and should not need Port Forwarding. (in addition it has no software layer firewall enabled)

There were two records in the realmlist table:

ID|name|address|port|icon|realmflags|timezone|allowedSecurityLevel|poulation|realmbuilds|

1|Twilight|EXTERNAL IP|8085|0|2|0|0|0.02| |

2|DEV|192.168.0.3|8085|0|2|0|0|0.02| |

I also changed #2's port from 8085 to 8086 and still nothing worked or showed up.

The lines in the configuration files are mostly the same except for the SQL Passwords and users. The Bind IP is also set to 0.0.0.0

I've read numerous guides inc the one on setting up for hosting behind a router.

The Router I'm using is "Actiontec M1000", doesn't support NAT Loopback, i.e. cannot access the External IP from that router unless using a Proxy.

Link to comment
Share on other sites

Ok, those lines look similar to mine.

Port 8085 is correct for both entries.

BindIP 0.0.0.0 is correct in telling it listen on ANY interface

I'm sure you've done this, but I still have to ask, are both "mangos-worldd" and "mangos-realmd" running?

In your LAN client's realmlist.wtf is it pointing to the LAN IP of the Login Server (realmd)?

Are your WAN clients' realmlist.wtf pointing to the WAN IP of the Login Server?

Edit:

Your first post makes me think you are not able to login (get to character select screen) is this correct or is it that you can get that far but cannot enter the world?

Edit:

Are there any other services on the server you can test locally and externally to make sure they are working with your network configuration (apache,ssh,etc)

Link to comment
Share on other sites

Perhaps the realmd.realmlist.id is the issue, since that is configured in mangosd.conf as well.

Good call, forgot about RealmID, and with the current core only one realmid can be used / updated at runtime.

Sorry Noaru, maybe get a router that supports NAT Reflection, or try using a hostname rather than the IP address, than on your local machine edit their hosts file so that the hostname will point to the local LAN IP for you, but for WAN users they would see your WAN IP (your own local DNS server might help to), not sure if that would work correctly, i'm unable to test at the moment?

Link to comment
Share on other sites

Oh here's an idea (a bit hacky, but it seems to work), what about changing the database structure so that realmid is not the primary key (yes we loose auto-increment, but if it works who cares) create a new UNIQUE index using id,name.. then for your two entries set both their ID's to 1 (with different names and IPs of course)

This seems to work on my server having one entry using a WAN IP and the other using the LAN IP

The database shows that my LAN users are connecting using the LAN address not the WAN

Note: I assume no responsibility for what may happen to your database if you mess with the structure

Edit: This may cause further unexpected issues having 2 realms with the same ID, but in my limited 5 minutes of testing i was able to login internally and externally

both realms updated the population correctly (reporting the same values)

both realms got their realmflags set to online (realmflags|=0x2)

Link to comment
Share on other sites

I thought about changing the hosts file and i'm not sure if it'd work correctly I could try but not 100% sure. And I did think about taking away the primary key for the realm ID so they both point to "1". Not sure which one to really test, any recommendations on the best method?

Also what would I enter if I were to change a Windows host file?

Link to comment
Share on other sites

You are right, I only chose to make id,name an UNIQUE index because they were originally PRIMARY and UNIQUE respectivly, so I merely just merged them together making it so names were only unique to the realm id they were attached (probably not the prefered way now that i think about it, like I said 5 minute testing).

But yes ip,port makes more sense for a key, the point of my idea was to say that dropping the PRIMARY key from id allowed me to set two realms to the same id allowing LAN/WAN access with the way the core currently is

With the way the core currently is the Key/index is a mute point anyways because the core won't utilize the indexs with this "hack", with only 2 realms it won't make a noticable difference

Link to comment
Share on other sites

If you set your realmlist up the way I did using a dns hostname rather than an IP address, you can use a service like dyndns and get a domain name like

mymangosserver.dyndns.go.net

and use that instead of the IP address in realmlist

which for WAN users would point to your WAN IP

on your LAN you'd edit your hosts file (C:\\WINDOWS\\system32\\drivers\\etc\\hosts) in notepad and add in an entry for the domain name but point it to your LAN IP

example:

127.0.0.1 localhost (this is already in there)

192.168.1.4 mymangosserver.dyndns.go.net

As far as the recommended method I can't say, at least the hosts file won't affect the database structure like my other idea I would try it first since it would be easier to fix if something broke or it didn't work

Link to comment
Share on other sites

×
×
  • Create New...

Important Information

We have placed cookies on your device to help make this website better. You can adjust your cookie settings, otherwise we'll assume you're okay to continue. Privacy Policy Terms of Use