Take the 2-minute tour ×
Unix & Linux Stack Exchange is a question and answer site for users of Linux, FreeBSD and other Un*x-like operating systems.. It's 100% free, no registration required.

Me and two friends have been making a video game. We've thought about download hosting a bit, but found that Mediafire, Box, and those sorts of file-hosting sites' maximum free file-upload size is far too small for us. Because of this limitation I've written a short TCP client/server downloader so that we can host the client binary on Mediafire, and have that pull the actual game from our server side program running on Ubuntu Server.

I think that the Ubuntu Server computer needs a static IP address, but my question is this: is having a static IP address like the one you turn out with from this tutorial going to make the local IP address of the Ubuntu Server computer static, or is it going to make the IP address that you can see from whatismyip.com static? Aren't they equally crucial to ensuring the client always attempts to connect to the same place?

If my router is set to port-forward the Ubuntu Server computer's IP address but the IP address changes the download won't work. If my network's IP address (the one seen from WhatIsMyIP) changes the client program will attempt to connect to a completely incorrect place - how can I fix both?

share|improve this question
add comment

2 Answers 2

up vote 1 down vote accepted

my question is this: is having a static IP address like the one you turn out with from this tutorial going to make the local IP address of the Ubuntu Server computer static, or is it going to make the IP address that you can see from whatismyip.com static?

That makes your private IP static, i.e. the one on your LAN.

Aren't they equally crucial to ensuring the client always attempts to connect to the same place?

Not exactly: it is crucial that the private IP of your server be static, lest port-forwarding from the router to the server does not work.

A static public IP is indeed a sufficient condition to access your Ubuntu server from the WAN side, but it is not a necessary condition. There are both free and non-free solutions.

Your public IP (what is identified by services like whatismyipaddress.com) is not under your control: it is assigned to you by your ISP.

You could arrange for a static IP to be provided to your router by your ISP. This is surely not a free solution.

Alternatively, you may use a commercial Dynamic DNS service which will make sure that the name you choose (www.thismymyWebsite.com) always resolves to your correct IP address, even when your ISP changes it. An example of such a service is DynDNS, but there are many out there allowing to shop for a convenient one. The money you pay in this case is shared between the registration of your domain name (so that no one else can claim it in the meantime) and the real service of keeping DNS servers around the world corretly updated insofar as your domain is concerned.

Lastly, there is a free alternative to this, which may be useful for debugging and the initial phase, depending on the real scope of your business. It is called No-IP, and provides a third-tier domain name, i.e. something like

 www.myname.no-ip.biz

where you only get to choose the "myname" part.

share|improve this answer
add comment

Here are three possible solutions:

  1. Rent a server (e.g. a cheap VPS) with a static IP address.

  2. Use a Dynamic DNS service so that your server's DNS hostname has an A record pointing to its current IP address. Note that this solution is far from perfect as there are many situations where the hostname can be pointing to an old, i.e. stale, IP address (e.g. if your server goes down, the A record will point to the old IP until it comes back up again and registers its new IP with the dyndns service).

  3. Combination of 1 & 2 above - rent an Amazon Web Service or similar "cloud" server (google, rackspace, and many others have similar offerings) with a dynamic IP address and use Dynamic DNS to point to it.

share|improve this answer
    
If you're going with Amazon (or similar), then at least Amazon can be set up to serve static content directly from S3. You'd have to run the numbers on whether it's cheaper, but it's certainly easier if all you want to do is serve a largely static file or set of files. –  Michael Kjörling Dec 16 '13 at 12:02
add comment

Your Answer

 
discard

By posting your answer, you agree to the privacy policy and terms of service.

Not the answer you're looking for? Browse other questions tagged or ask your own question.