[SOLVED] Problems running the server from remote

Ask for help regarding any technical issue or report any bug or OS independent issues.
Post Reply
wjhildreth
Newly Registered User
Posts: 7
Joined: 02 Feb 2012, 21:04

[SOLVED] Problems running the server from remote

Post by wjhildreth »

Hello all,

I just want to warn you that this may be a lengthy post, but I want to make sure I give enough information that you may be able to help me.

First, I want you to know that I never heard of The Mana World until the last issue of Full Magazine came out where it was described how to set up a Mana World Server. I followed these instructions but had errors because of missing config files. From there I checked out a resource in the document (http://wiki.themanaworld.org/index.php/How_to_Develop). This ended up with a working server. Now, I used all the default ports and changed the config files to point to the local IP of the machine except for the login server which remained 127.0.0.1. Now, I have two wireless networks in my house. (192.168.1.0/24) and (192.168.2.0/24) Clients from both of these were able to connect and play on the local server (IP: 192.168.1.79)

So far so good. My next task was to allow it to recieve connections from the outside world, so some of my son's friends could play with us. I done the following:

1) I opened both UDP and TCP ports for (6901 - Login Server, 6122 - Char Server and 5122 for Map Server.) My machine sits behind a firewall and my outside IP is natted to the TMW server machine. I know this works because I can ssh into my server from work.

2) I edited the ~/tmw-ea/eathena-data/login/conf/lan_support.conf file to have the following values with comments in ():
lan_char_ip: 192.168.1.79
lan_map_ip: 192.168.1.79
subnet: 192.168.0.0 (BTW, this seems like it should be called network rather than subnet)
subnetmask: 255.255.0.0 (I gave the class B network and mask because I want it available to both internal networks of 192.168.1.0 and 192.168.2.0 although the IP config on the server is on a 255.255.255.0 mask)

3) I edited the ~/tmw-ea/eathena-data/login/conf/login_local.co to have the following values:
admin_pass: <secret>
gm_pass: <secret>
(everything else is defaults)

4) I edited the ~/tmw-ea/eathena-data/world/conf/lan_support.conf exactly the same as step 2 above.

5) I edited the ~/tmw-ea/eathena-data/world/conf/char_local.conf to have the following values:
login_ip:192.168.1.79
char_ip:192.168.1.79
Everything else is set to defaults.

6) I edited the ~/tmw-ea/eathena-data/world/map/conf/map_local.conf with the following:
char_ip:192.168.1.79
map_ip:192.168.1.79

As far as I know that is all the changes I need to make. Below is the output from starting the login-server:

Code: Select all

joeh@XBMCLive:~/tmw-ea/eathena-data$ ./login-server &
[1] 11194
joeh@XBMCLive:~/tmw-ea/eathena-data$ ---Start reading of Login Server configuration file (conf/login_athena.conf)
---Start reading of Login Server configuration file (conf/login_local.conf)
---End reading of Login Server configuration file.
---End reading of Login Server configuration file.
---Start reading Lan Support configuration file
LAN IP of char-server: 192.168.1.79.
Sub-network of the char-server: 192.168.0.0.
Sub-network mask of the char-server: 255.255.0.0.
LAN test of LAN IP of the char-server: LAN test (result): LAN source.
---End reading of Lan Support configuration file
read_gm_account: file 'save/gm_account.txt' readed (1 GM accounts found).
mmo_auth_init: 7 accounts read in save/account.txt,
               of which is 1 GM account, and 5 server accounts ('S').
The login-server is ready (Server is listening on the port 6901).
Below is the ouput of starting the char-server:

Code: Select all

joeh@XBMCLive:~/tmw-ea/eathena-data$ ./char-server &
[2] 11195
joeh@XBMCLive:~/tmw-ea/eathena-data$ The Mana World server has been intialized
Login server IP address : 192.168.1.79 -> 192.168.1.79
Character server IP address : 192.168.1.79 -> 192.168.1.79
---start reading of Lan Support configuration...
LAN IP of map-server: 192.168.1.79.
Sub-network of the map-server: 192.168.0.0.
Sub-network mask of the map-server: 255.255.0.0.
LAN test of LAN IP of the map-server: LAN test (result): LAN source.
---End reading of Lan Support configuration...
mmo_char_init: 2 characters read in save/athena.txt.
can't read db/exp_guild.txt
The char-server is ready (Server is listening on the port 6122).

Attempt to connect to login-server...
Connection of the char-server 'The Mana World' accepted.
Connected to login-server (connection #4).
Awaiting maps from map-server.
From login-server: receiving of 1 GM accounts information.
And finally the output from the map-server:

Code: Select all

joeh@XBMCLive:~/tmw-ea/eathena-data$ ./map-server &
[3] 11199
joeh@XBMCLive:~/tmw-ea/eathena-data$ Character server IP address : 192.168.1.79 -> 192.168.1.79
Map server IP address : 192.168.1.79 -> 192.168.1.79
Unable to find resource: data\030-2.gat
Loading Maps [0/85]: data\001-1.gat                                      
167 114
Loading Maps [1/85]: data\001-2.gat                                      
160 100
Loading Maps [2/85]: data\001-3.gat                                      
150 150
Loading Maps [3/85]: data\002-1.gat                                      
136 128
Loading Maps [4/85]: data\002-3.gat                                      
128 128
Loading Maps [5/85]: data\002-4.gat                                      
128 128
Loading Maps [6/85]: data\003-1.gat                                      
190 138
Loading Maps [7/85]: data\003-2.gat                                      
75 50
Loading Maps [8/85]: data\004-1.gat                                      
117 133
Loading Maps [9/85]: data\004-2.gat                                      
98 87
Loading Maps [10/85]: data\005-1.gat                                      
200 130
Loading Maps [11/85]: data\005-3.gat                                      
120 116
Loading Maps [12/85]: data\005-4.gat                                      
75 50
Loading Maps [13/85]: data\006-1.gat                                      
150 150
Loading Maps [14/85]: data\006-3.gat                                      
150 150
Loading Maps [15/85]: data\007-1.gat                                      
144 124
Loading Maps [16/85]: data\008-1.gat                                      
162 120
Loading Maps [17/85]: data\009-1.gat                                      
117 75
Loading Maps [18/85]: data\009-2.gat                                      
200 120
Loading Maps [19/85]: data\009-3.gat                                      
200 151
Loading Maps [20/85]: data\009-4.gat                                      
160 160
Loading Maps [21/85]: data\010-1.gat                                      
150 120
Loading Maps [22/85]: data\010-2.gat                                      
107 110
Loading Maps [23/85]: data\011-1.gat                                      
154 124
Loading Maps [24/85]: data\011-3.gat                                      
60 60
Loading Maps [25/85]: data\011-4.gat                                      
150 150
Loading Maps [26/85]: data\011-6.gat                                      
300 300
Loading Maps [27/85]: data\012-1.gat                                      
168 188
Loading Maps [28/85]: data\012-3.gat                                      
520 210
Loading Maps [29/85]: data\012-4.gat                                      
520 210
Loading Maps [30/85]: data\013-1.gat                                      
154 124
Loading Maps [31/85]: data\013-2.gat                                      
88 63
Loading Maps [32/85]: data\013-3.gat                                      
200 200
Loading Maps [33/85]: data\014-1.gat                                      
140 120
Loading Maps [34/85]: data\014-3.gat                                      
140 200
Loading Maps [35/85]: data\015-1.gat                                      
140 120
Loading Maps [36/85]: data\015-3.gat                                      
64 64
Loading Maps [37/85]: data\016-1.gat                                      
140 120
Loading Maps [38/85]: data\017-1.gat                                      
154 124
Loading Maps [39/85]: data\017-2.gat                                      
53 51
Loading Maps [40/85]: data\017-9.gat                                      
53 51
Loading Maps [41/85]: data\018-1.gat                                      
200 120
Loading Maps [42/85]: data\018-2.gat                                      
146 70
Loading Maps [43/85]: data\018-3.gat                                      
200 200
Loading Maps [44/85]: data\019-1.gat                                      
138 128
Loading Maps [45/85]: data\019-3.gat                                      
138 128
Loading Maps [46/85]: data\020-1.gat                                      
128 148
Loading Maps [47/85]: data\020-2.gat                                      
160 100
Loading Maps [48/85]: data\020-3.gat                                      
160 160
Loading Maps [49/85]: data\021-1.gat                                      
178 168
Loading Maps [50/85]: data\021-2.gat                                      
200 200
Loading Maps [51/85]: data\022-1.gat                                      
150 129
Loading Maps [52/85]: data\024-1.gat                                      
119 122
Loading Maps [53/85]: data\024-2.gat                                      
200 200
Loading Maps [54/85]: data\024-3.gat                                      
100 100
Loading Maps [55/85]: data\024-4.gat                                      
500 500
Loading Maps [56/85]: data\025-1.gat                                      
150 120
Loading Maps [57/85]: data\025-3.gat                                      
190 190
Loading Maps [58/85]: data\025-4.gat                                      
200 240
Loading Maps [59/85]: data\026-1.gat                                      
150 120
Loading Maps [60/85]: data\027-1.gat                                      
150 120
Loading Maps [61/85]: data\027-2.gat                                      
150 130
Loading Maps [62/85]: data\027-3.gat                                      
150 90
Loading Maps [63/85]: data\027-4.gat                                      
80 100
Loading Maps [64/85]: data\028-1.gat                                      
140 140
Loading Maps [65/85]: data\028-3.gat                                      
100 100
Loading Maps [66/85]: data\029-1.gat                                      
100 100
Loading Maps [67/85]: data\029-3.gat                                      
100 100
Loading Maps [68/85]: data\030-1.gat                                      
138 128
Unable to find resource: data\030-2.gat
Loading Maps [69/85]: data\030-2.gat                                      
220 130
Loading Maps [70/85]: data\031-1.gat                                      
128 148
Loading Maps [71/85]: data\031-2.gat                                      
100 50
Loading Maps [72/85]: data\031-3.gat                                      
320 320
Loading Maps [73/85]: data\031-4.gat                                      
96 92
Loading Maps [74/85]: data\032-1.gat                                      
100 100
Loading Maps [75/85]: data\032-3.gat                                      
160 100
Loading Maps [76/85]: data\033-1.gat                                      
138 128
Loading Maps [77/85]: data\034-1.gat                                      
178 128
Loading Maps [78/85]: data\041-1.gat                                      
125 125
Loading Maps [79/85]: data\042-1.gat                                      
148 100
Loading Maps [80/85]: data\042-2.gat                                      
70 110
Loading Maps [81/85]: data\044-1.gat                                      
225 200
Loading Maps [82/85]: data\044-3.gat                                      
160 200
Loading Maps [83/85]: data\045-1.gat                                      
200 200
Loading Maps [84/85]: data\botcheck.gat                                   
75 75
Maps Loaded: 85                                                             
Maps Removed: 0 
Unable to find resource: data\itemslottable.txt
data\itemslottable.txt not found
read db/item_db.txt done (count=633)
read db/item_bluebox.txt done (count=0)
read db/item_violetbox.txt done (count=0)
read db/item_cardalbum.txt done (count=0)
read db/item_giftbox.txt done (count=0)
read db/item_scroll.txt done (count=0)
can't read db/item_avail.txt
read db/item_noequip.txt done (count=0)
Unable to find resource: data\num2cardillustnametable.txt
data\num2cardillustnametable.txt not found
Exp for mob 'Maggot' generated: 6
Exp for mob 'Scorpion' generated: 13
Exp for mob 'RedScorpion' generated: 168
Exp for mob 'GreenSlime' generated: 302
Exp for mob 'GiantMaggot' generated: 136
Exp for mob 'YellowSlime' generated: 94
Exp for mob 'RedSlime' generated: 131
Exp for mob 'BlackScorpion' generated: 253
Exp for mob 'Snake' generated: 361
Exp for mob 'FireGoblin' generated: 41
Exp for mob 'Spider' generated: 348
Exp for mob 'EvilMushroom' generated: 233
Exp for mob 'PinkFlower' generated: 296
Exp for mob 'SantaSlime' generated: 298
Exp for mob 'RudolphSlime' generated: 101
Exp for mob 'Bat' generated: 27
Exp for mob 'Pinkie' generated: 99
Exp for mob 'SpikyMushroom' generated: 54
Exp for mob 'Fluffy' generated: 100
Exp for mob 'CaveSnake' generated: 195
Exp for mob 'JackO' generated: 16130
Exp for mob 'FireSkull' generated: 5493
Exp for mob 'PoisonSkull' generated: 5493
Exp for mob 'LogHead' generated: 149
Exp for mob 'MountainSnake' generated: 512
Exp for mob 'EasterFluffy' generated: 98
Exp for mob 'Mouboo' generated: 497
Exp for mob 'SeaSlime' generated: 187
Exp for mob 'GrassSnake' generated: 627
Exp for mob 'Zombie' generated: 7782
Exp for mob 'Squirrel' generated: 34
Exp for mob 'Wisp' generated: 3726
Exp for mob 'Snail' generated: 180
Exp for mob 'Skeleton' generated: 3950
Exp for mob 'LadySkeleton' generated: 4122
Exp for mob 'SnakeLord' generated: 32588
Exp for mob 'Poltergeist' generated: 4230
Exp for mob 'Bee' generated: 178
Exp for mob 'Butterfly' generated: 85
Exp for mob 'CaveMaggot' generated: 16
Exp for mob 'AngryScorpion' generated: 37
Exp for mob 'IceGoblin' generated: 75
Exp for mob 'GCMaggot' generated: 684
Exp for mob 'Archant' generated: 88
Exp for mob 'Moggun' generated: 280
Exp for mob 'Terranite' generated: 4851
Exp for mob 'Pumpkin' generated: 19
Exp for mob 'Bandit' generated: 91
Exp for mob 'BanditLord' generated: 633
Exp for mob 'VampireBat' generated: 148
Exp for mob 'Reaper' generated: 617
Exp for mob 'Reaper2' generated: 5780
Exp for mob 'Scythe' generated: 6463
Exp for mob 'BallLightning' generated: 5
Exp for mob 'IceElement' generated: 2897
Exp for mob 'Yeti' generated: 9040
Exp for mob 'TheLost' generated: 2354
Exp for mob 'DrunkenSkeleton' generated: 4827
Exp for mob 'TipsySkeleton' generated: 4952
Exp for mob 'DrunkenLadySkeleton' generated: 4565
Exp for mob 'BlueSpark' generated: 3647
Exp for mob 'RedSpark' generated: 3647
Exp for mob 'Serqet' generated: 13
Exp for mob 'HuntsmanSpider' generated: 467
Exp for mob 'CrotcherScorpion' generated: 428
Exp for mob 'IceSkull' generated: 5493
Exp for mob 'Larvern' generated: 164
Exp for mob 'Hyvern' generated: 990
Exp for mob 'HungryFluffy' generated: 111
Exp for mob 'Wolvern' generated: 280
Exp for mob 'BlueSlime' generated: 759
Exp for mob 'SlimeBlast' generated: 20
Exp for mob 'WhiteSlime' generated: 55
Exp for mob 'Reinboo' generated: 273
read db/mob_db.txt done
can't read db/mob_avail.txt
read db/mob_branch.txt done
can't read db/mob_poring.txt
read db/mob_skill_db.txt done
NPCs Loaded: 7130 [Warps:544 Shops:24 Scripts:470 Mobs:6092]               
read db/exp.txt done
read db/job_db1.txt done
read db/job_db2.txt done
read db/job_db2-2.txt done
read db/skill_tree.txt done
read db/attr_fix.txt done
can't read db/size_fix.txt
read db/statpoint.txt done (size=1189)
can't read db/castle_db.txt
Incomplete skill db data online (1 entries)
read db/skill_db.txt done
read db/skill_require_db.txt done
can't read db/skill_cast_db.txt
[magic-conf] Magic configuration file `conf/magic.conf' not found -> no magic.
npc: OnInit Event done. (11 npc)
The map-server is ready (Server is listening on the port 5122).

Attempt to connect to char-server...
Connected to char-server (connection #4).
chrif: OnCharIfInit event done. (0 events)
chrif: OnInterIfInit event done. (0 events)
guild_castlealldataload ??
guild_castlealldataload ??
guild_castlealldataload ??
guild_castlealldataload ??
guild_castlealldataload ??
guild_castlealldataload ??
guild_castlealldataload ??
guild_castlealldataload ??
guild_castlealldataload ??
guild_castlealldataload ??
guild_castlealldataload ??
guild_castlealldataload ??
guild_castlealldataload ??
guild_castlealldataload ??
guild_castlealldataload ??
guild_castlealldataload ??
guild_castlealldataload ??
guild_castlealldataload ??
guild_castlealldataload ??
guild_castlealldataload ??
guild_castlealldataload ??
guild_castlealldataload ??
guild_castlealldataload ??
guild_castlealldataload ??
From login-server: receiving of 1 GM accounts information.
Map-Server 0 connected: 85 maps, from IP 192.168.1.79 port 5122.
Map-server 0 loading complete.
Connecting with the manaplus client I can login and the server gives the following:

Code: Select all

Connection of the GM (level:99) account 'Gilimi' accepted.
LAN test (result): WAN source.
The news is displayed and resources are loaded I guess. Then the client reads requesting characters and hangs there until it finally gives the message:

Code: Select all

Error 
Couldn't connect to remote host.
Could someone please tell me where I have erred or perhaps where to look for the problem. Many thanks for your time and energy.

Joe
Last edited by wjhildreth on 02 Feb 2012, 22:24, edited 1 time in total.
wjhildreth
Newly Registered User
Posts: 7
Joined: 02 Feb 2012, 21:04

[SOLVED] Re: Problems running the server from remote

Post by wjhildreth »

Well, maybe I should have dug around and experiments more. I used my public addess in the config files and referenced the other servers with the internal IP and it works.

Or more exactly:

map_local.config points the map to external and char to internal

char_local.config ponts the char to external and login to internal

Once I read a post about three servers and them needing to communicate, then I realized that when a server process needs to talk to another server process it needs its local address, while telling the original server process that it has an external address of xxx.xxx.xxx.xxx.

Am I correct in this line of thought? This is new territory for me.

Regards,
Joe
Frost
TMW Adviser
TMW Adviser
Posts: 851
Joined: 09 Sep 2010, 06:20
Location: California, USA

Re: [SOLVED] Re: Problems running the server from remote

Post by Frost »

wjhildreth wrote:Well, maybe I should have dug around and experiments more. I used my public addess in the config files and referenced the other servers with the internal IP and it works.
Congratulations!
Or more exactly:

map_local.config points the map to external and char to internal

char_local.config ponts the char to external and login to internal
Well said, and exactly right.
Once I read a post about three servers and them needing to communicate, then I realized that when a server process needs to talk to another server process it needs its local address, while telling the original server process that it has an external address of xxx.xxx.xxx.xxx.

Am I correct in this line of thought? This is new territory for me.
To the best of my knowledge, you are completely correct. The server both advertises connection information to the client and connects to other processes which are (presumably) on the same host as the server itself.

Enjoy the game! You might want to occasionally update the content as new features are added. (git://gitorious.org/+tmw-admins/tmw/tmwa-server-test.git)
You earn respect by how you live, not by what you demand.
-unknown
Post Reply