PDA

View Full Version : Simple NAT Solution


liquidx
06-12-2002, 12:30 AM
If you run a dual DNS server, one for private, one for public, you can create a host, such as eq.yourdomain.com, set your LAN to use the private DNS, which has eq.yourdomain.com set to be the LAN address.. then use the public one as the domain record, and set it to be the WAN address..

In the zone bootup and the WorldAddress field in loginserver.ini set it to be the host instead of the IP. Anywhoo, works for me.. enjoy

Trumpcard
06-12-2002, 12:53 AM
I think thats the solution Hogie came up with, I havent been able to get it to work yet.

You dont have to be running a dual dns server, just set your host file on the windows client machine with

<external name> internal ip

so when you do a ping you should see the internal ip address rather than the external.

Im not 100% sure my build of eqemu was working at all though, so it might not have been the way I was NAT'ing that was causing my problem.

inkubus
06-16-2002, 06:30 PM
I have been succesfully able to run a server for internal network users and external internet users.

The trick is to use the hosts file as suggested in most of the forums related to NAT. You will need a hostname for your machine. (Those who don't have a static ip and of course a permant hostname try visiting www.dynip.com). For this example we'll use susie.dynip.com.

Before configuring the server it's important to check that the hostname you're about to use is resolving to your machines IP. Try using /dns susie.dynip.com in mIRC. If it is you're ready to go. If not you may have to wait some time for the DNS to kick in. Shouldn't take too long tho.

1) Server Configuration
a. LoginServer.ini:
Delete the username/password entries in LoginServer (including the username=/password=). I'm not sure why. Some people say its a parsing error at either the loginserver or worldserver end. I'm not sure. But this _Definately_ has something to do with the problems. Change your worldaddress= to worldaddress=susie.hacknet.org.

b. Zones (usually a shell script file)
I use a simple shell file that's like this:
./zone . susie.dynip.com 7995 localhost &
./zone . susie.dynip.com 7996 localhost &
./zone . susie.dynip.com 7997 localhost &
./zone . susie.dynip.com 7998 localhost &
./zone . susie.dynip.com 7999 localhost &
Keep the last hostname/ip as localhost. Seems to work a treat for me.

Configure the rest of the server as normal and then ask someone on the internet (try #eqemu) to login to your server. They'll hopefully be able to login with no problems. Once this is complete it's time to sort your internal client machines.

2) Client Machine Configuration
a. Always check you're using the correct EQHost.txt. At the time of writing this was available here: http://www.eqemu.net/eqhost.txt.

b. Make sure you are using the correct client version. It's never a good idea to update your EQ without making a back up. If you're unsure try login into the EQEmu login server and checking out someone who's hosting a server with the same version as you. If you can login there then you _should_ have no problem connecting to your own.

c. Edit your hosts file which can be located in c:winntsystem32driversetchosts or c:windowssystem32driversetchosts. Your machine will always look in this folder to lookup an IP's hostname before it checks the internet. You'll need to add an entry for susie.dynip.com like the default entry that's in there. Give it the internal network IP you're using also. For example:

127.0.0.1 localhost
192.168.0.1 susie.dynip.com

Save the changes and close the file. Load mIRC and do /dns suse.dynip.com. This should give you you're internal network IP for that machine. If it doesn't double check hosts and make sure you saved.

3) Connect to your server
At this point you should be ready to start playing. Connect to the EQEmu Login server with the correct client, locate your server and click play everquest. Hopefully you should be able to play! If not try looking at the errors you're recieving from your emulator.

I found that the main problem for me was not deleting the username= and password= from the LoginServer.ini. This is a very important process and should not be forgotten. For days i was baffled with why it wasn't working and this was the only solution that worked.

Good luck! If you have problems/questions feel free to email or drop by #EQEmu. I'm normally pestering the devs there. :>

- InKubus