IP Problems...[Edit][Edit] Grrr Still not working properly
Moderator: OpenTTD Developers
IP Problems...[Edit][Edit] Grrr Still not working properly
My comp Ip is different to my modem/router Ip. so i cant host a game as yet.
any ideas how to remedy this (have i overlooked a simple solution?). I 'CAN'
connect to other games online to and networked games run fine also.
[Edit] Now i got it to bee seen, those that see it say it says 'server offline'
any ideas how to remedy this (have i overlooked a simple solution?). I 'CAN'
connect to other games online to and networked games run fine also.
[Edit] Now i got it to bee seen, those that see it say it says 'server offline'
Last edited by Muttley on 20 Jan 2005 18:11, edited 2 times in total.
Ummmmm ?
I cant host games of any kind not just tycoon. i even tried with nofirewall at all. works fine on the LAN and internet goes thru lan. i think its cos my comps
have diff IP to the internet IP
have diff IP to the internet IP
Well, I'm telling you thats why it won't work. I had the same thing happen until I forwarded the ports.
Edit: I cannot tell you a step-by-step for all hardware. You will have to find out what router you have, then follow a tutorial at: http://www.portforward.com
Edit: I cannot tell you a step-by-step for all hardware. You will have to find out what router you have, then follow a tutorial at: http://www.portforward.com
Last edited by teeone on 17 Jan 2005 04:23, edited 1 time in total.
How do i forward the ports ?
How is that done exactly ?
I'm assuming you have a cable modem or DSL router here. If you have a cable modem, and also a home network I'm assuming you have a normal network router as well. If you don't have a home network it doesn't really matter, you can just think of your comp as the home network.
Here's the deal: Your router has the job of taking the one IP address your ISP has given you and pass on all the information on the internet to the computers on your home network ( this process is called NAT or Network Address Translation). This is why you have two IP-addresses: One is the one the router uses to identify itself on the internet, the other is the one it uses to identify the comps at your home network.
The problem here is that initially, the rest of the internet don't know about your computer; they only know about the router. But once your computer sends information to the internet, it first goes to the router, the router says "Okay, I'll give that website/server/whatever this piece of info", the recipient gets the info, sends it back to the router, which says "hey, this must be the reply to what I just forwarded, I'll pass it on to the correct comp", and all is well.
As you see, your computer can connect to other computers on the internet, but no computers can connect to yours (initially, that is). This is why you can connect to other hosted games, but you can't host them yourself. UNLESS you do what is called 'port forwarding'. Every IP address comes with 65536 ports that are like 'sockets for information'. A program can be set up to listen on these ports for information constantly. But since the router only has one IP address to the internet, it also only has 65536 ports to listen on, and it can't guess what ports belong to which computer on your home network. Thus, all attempts to make a connection to your internet IP address are blocked by your router. (This is essentially what a firewall does)
This is where port forwardingn comes in: You simply tell the router which comp gets which ports! Now, if you only have one comp, this isn't a problem at all, since you can simply forward every port to it. This is called making your router transparent, but it also makes your comp more vulnerable to attacks. But I won't go into details about that.
So, to host a OTTD game, you have to forward the port 3979 and allow TCP and UDP communication on it (It's not important to know what TCP and UDP is, they're simply ways to communicate). But here is where it gets difficult, because the process of port forwarding is different from router to router. I'll use my home network as an example, and you'll have to find instructions for your particular router.
I use a Telnet console to communicate with my router. My home network has IP addresses on the form 10.0.0.x, which means the router has 10.0.0.1, my comp has 10.0.0.2, my friend 10.0.0.3 and so on. So I choose Run on the start menu and type in 'telnet 10.0.0.1'. Then there's a lot of menues I have to navigate, to a menu called 'NAT settings' and I can type in different port ranges. I'm not gonna go into details, because I'm 99% sure your router is different. Some routers have a web-interface, where you simply type the routers IP address in your web browser. But enough about that, on with the show.
Now, I could have forwarded ports on an on-need basis, but it quickly gets hard to remember which ports are used by which program. So I've used a different approach, and simply forward a range of ports based on the IP address the comp has on the home network. So, 10.0.0.2 gets ports 2000-2999, 10.0.0.3 gets 3000-3999, and, well, you get the idea. This approach requires you to configure the programs you're gonna use to use one of the ports that has been assigned to the comp, but most programs, including OTTD (if my memory serves me correctly), has a way of doing this. This also removes the problem of two comps using the same program, because a port can only belong to one comp. Plus it's a ton easier to manage.
So what you gotta do is either find your router's manual, or search the internet (Google is your friend!) for the exact method of forwarding ports on your particular router. Look for your router's name and/or model number and the terms port forwarding or NAT.
Closing words: There's new technology now called UPnP which makes programs able to request ports to be forwarded automagically, but only newer routers and programs support it, and unfortunately OTTD is not one of those. But I hope everything works out for you. Good luck!
THERE! I DID IT! I wrote the ultimate port forwarding guide! It's done once and for all!
Edit: And NOW I notice the page teeone has edited into his message.... brilliant. Nevertheless, I will post this, as I think it fleshes out that page nicely. Also, chances are you'll find info on your particular router there =)
Here's the deal: Your router has the job of taking the one IP address your ISP has given you and pass on all the information on the internet to the computers on your home network ( this process is called NAT or Network Address Translation). This is why you have two IP-addresses: One is the one the router uses to identify itself on the internet, the other is the one it uses to identify the comps at your home network.
The problem here is that initially, the rest of the internet don't know about your computer; they only know about the router. But once your computer sends information to the internet, it first goes to the router, the router says "Okay, I'll give that website/server/whatever this piece of info", the recipient gets the info, sends it back to the router, which says "hey, this must be the reply to what I just forwarded, I'll pass it on to the correct comp", and all is well.
As you see, your computer can connect to other computers on the internet, but no computers can connect to yours (initially, that is). This is why you can connect to other hosted games, but you can't host them yourself. UNLESS you do what is called 'port forwarding'. Every IP address comes with 65536 ports that are like 'sockets for information'. A program can be set up to listen on these ports for information constantly. But since the router only has one IP address to the internet, it also only has 65536 ports to listen on, and it can't guess what ports belong to which computer on your home network. Thus, all attempts to make a connection to your internet IP address are blocked by your router. (This is essentially what a firewall does)
This is where port forwardingn comes in: You simply tell the router which comp gets which ports! Now, if you only have one comp, this isn't a problem at all, since you can simply forward every port to it. This is called making your router transparent, but it also makes your comp more vulnerable to attacks. But I won't go into details about that.
So, to host a OTTD game, you have to forward the port 3979 and allow TCP and UDP communication on it (It's not important to know what TCP and UDP is, they're simply ways to communicate). But here is where it gets difficult, because the process of port forwarding is different from router to router. I'll use my home network as an example, and you'll have to find instructions for your particular router.
I use a Telnet console to communicate with my router. My home network has IP addresses on the form 10.0.0.x, which means the router has 10.0.0.1, my comp has 10.0.0.2, my friend 10.0.0.3 and so on. So I choose Run on the start menu and type in 'telnet 10.0.0.1'. Then there's a lot of menues I have to navigate, to a menu called 'NAT settings' and I can type in different port ranges. I'm not gonna go into details, because I'm 99% sure your router is different. Some routers have a web-interface, where you simply type the routers IP address in your web browser. But enough about that, on with the show.
Now, I could have forwarded ports on an on-need basis, but it quickly gets hard to remember which ports are used by which program. So I've used a different approach, and simply forward a range of ports based on the IP address the comp has on the home network. So, 10.0.0.2 gets ports 2000-2999, 10.0.0.3 gets 3000-3999, and, well, you get the idea. This approach requires you to configure the programs you're gonna use to use one of the ports that has been assigned to the comp, but most programs, including OTTD (if my memory serves me correctly), has a way of doing this. This also removes the problem of two comps using the same program, because a port can only belong to one comp. Plus it's a ton easier to manage.
So what you gotta do is either find your router's manual, or search the internet (Google is your friend!) for the exact method of forwarding ports on your particular router. Look for your router's name and/or model number and the terms port forwarding or NAT.
Closing words: There's new technology now called UPnP which makes programs able to request ports to be forwarded automagically, but only newer routers and programs support it, and unfortunately OTTD is not one of those. But I hope everything works out for you. Good luck!
THERE! I DID IT! I wrote the ultimate port forwarding guide! It's done once and for all!
Edit: And NOW I notice the page teeone has edited into his message.... brilliant. Nevertheless, I will post this, as I think it fleshes out that page nicely. Also, chances are you'll find info on your particular router there =)
Creator of the longest Locomotion station ever.
Sh*t does NOT just happen, sh*t takes time and effort.
Yay, that's me in my avatar! I win!
Keep violence virtual!
Sh*t does NOT just happen, sh*t takes time and effort.
Yay, that's me in my avatar! I win!
Keep violence virtual!
-
- Tycoon
- Posts: 1395
- Joined: 12 Jun 2004 00:37
- Location: United Kingdom of Great Britain and Northern Ireland
- Contact:
emule has instructions on how to set up port forwarding on a number of routers, yours might be one of them:
http://emule-project.net/home/perl/help ... cat_id=251
Instead of using the port numbers it gives, you'll just need 3979.
http://emule-project.net/home/perl/help ... cat_id=251
Instead of using the port numbers it gives, you'll just need 3979.
thnx for the info guys
I appreciate the help you guys have posted. I tried the Site Tee posted and had my router but even tho i followed the instructions i keep getting a 501 error 'method not implemented' .
Stylpe wrote:Edit: And NOW I notice the page teeone has edited into his message.... brilliant. Nevertheless, I will post this, as I think it fleshes out that page nicely. Also, chances are you'll find info on your particular router there =)


Muttley, as for your problem:
I'm assuming thats a router error you are getting when you try to actually forward the ports (501 error 'method not implemented') . If so, you need to look at your router's manual and figure out what that error means, other than that, I have no idea.
that didnt help
I DL the manual from the D-Link site and it didnt help.
It is possible that you have a (n extremely) crappy router that simple can't DO forwarding... in that case you're screwed. unless you get a better router.
Creator of the Openttd Challenge Spinoff, Town Demand patch
After action reports: The path to riches, A dream of skyscrapers
After action reports: The path to riches, A dream of skyscrapers
Dunno
I dont know the manual has settings for port forwarding the just dont seem to work.
- lucaspiller
- Tycoon
- Posts: 1228
- Joined: 18 Apr 2004 20:27
I have a D-Link Di-624 router, I don't know whether this is what you have or not but I shouldn't think there is much difference between models so here are some instructions.
1) Point your browser to whatever your routers IP is (by default http://192.168.0.1/ and login.
2) Click on the Advanced tab at the top, if there isn't one look through each tabs list of options and find one that has a Virtual Server or Firewall button.
3) On my system I need to use the Virtual Server option so click on it.
4) Enter the following options so that you have something that looks like the picture below (assuming you have a simular device):
Name: OpenTTD
Private IP: 192.168.0.2 (or whatever the IP of the machine you are hosting the game on is)
Protocol Type: Both
Private Port: 3979
Public Port: 3979
Schedule: Always
5) Click the green Apply button and then hopefully everything should work.
If you keep getting 501 errors while using the web based interface on your browser try resetting it and if that doesn't work upgrading the firmware. If you still get the error you should contact D-Link support.
1) Point your browser to whatever your routers IP is (by default http://192.168.0.1/ and login.
2) Click on the Advanced tab at the top, if there isn't one look through each tabs list of options and find one that has a Virtual Server or Firewall button.
3) On my system I need to use the Virtual Server option so click on it.
4) Enter the following options so that you have something that looks like the picture below (assuming you have a simular device):
Name: OpenTTD
Private IP: 192.168.0.2 (or whatever the IP of the machine you are hosting the game on is)
Protocol Type: Both
Private Port: 3979
Public Port: 3979
Schedule: Always
5) Click the green Apply button and then hopefully everything should work.
If you keep getting 501 errors while using the web based interface on your browser try resetting it and if that doesn't work upgrading the firmware. If you still get the error you should contact D-Link support.
- Attachments
-
- settings.PNG (24.41 KiB) Viewed 3337 times
No longer active here, but you can still reach me via email: luca[at]stackednotion[dot]com
Re:modem specs
My modem is DSL302G (D-link) I couldnt find the virtual server/firewall thingy. I also sent a e-mail to support yesterday havent heard back yet.
- lucaspiller
- Tycoon
- Posts: 1228
- Joined: 18 Apr 2004 20:27
If you would have told us what product you had before it would have helped a lot more. I looked on the D-Link site and couldn't find a manual so what I guess you must have downloaded was the install guide which wouldn't have been any help. Also I guess your product must have come with a manal so next time read it!
Also a quick search on Google turned up this - enjoy.
Also a quick search on Google turned up this - enjoy.

No longer active here, but you can still reach me via email: luca[at]stackednotion[dot]com
FOr your information........
My modem/router did 'NOT' come with a manual and I 'DID' download the 'MANUAL' from the New Zealand/Australia D-Link site. "AND' I followed the manuals instructions to the letter. So think twice before shooting your mouth off please.
I have provided a link to where I DL the manual.
http://www.dlink.com.au/tech/drivers/fi ... sl302g.htm
I have provided a link to where I DL the manual.
http://www.dlink.com.au/tech/drivers/fi ... sl302g.htm
Re: FOr your information........
Not even a word of thanks, but instead you're almost offending the nice guys who helped you. Even though your question was even off topic in the first place.Muttley wrote:So think twice before shooting your mouth off please.


"There's a readme that comes with the source. I suggest you read it."
- Korenn
- Korenn
Srry i didnt finish....
Srry i didnt get to finish my post. My rid e turned up for cricket and i had to up and go. D-Link E-mailed me and helped said i had to use IE instead of mozilla. So in fact nothing suggested would have worked anyway.
[Edit] It forwrded ports ok but now those that see it see 'Server Offline'
(See Topic Edit Also)
[Edit] It forwrded ports ok but now those that see it see 'Server Offline'
(See Topic Edit Also)
- lucaspiller
- Tycoon
- Posts: 1228
- Joined: 18 Apr 2004 20:27
Who is online
Users browsing this forum: Amazon [Bot] and 10 guests