Hosting a Webserver from My Home Machine

sinister

Registered
o.k., this may sound newbish, can't hide it!

I want to host a website from my home computer. I have a domain name already registered with network solutions. Now all I want to do is have the domain point to my machine. So How do I go about entering my IP address as the dns, and what else needs to get configured for it to work.

Thanks A Mil!!
 
Find someone with a DNS server to point to you or install BIND yourself. I reccommend going with the first option unless you want a whole new set of headaches that you never bargained before.

do you have a static IP with your internet provider? If so, great. If not, you will probably need to find a service such as dynip.org that will let you update your entries when you get a new IP.
 
O.k., I would prefer having full control of my domain. I downloaded bind. Having trouble installing it. Any docs where I can found out how to install it on OS X?
 
do you have the developer tools installed? If not, you'll need those first.

May also want to find out whether it's included in the install or not already; there are other services installed that are disabled under X.

even once it's installed, setting it up is no picnic. Personally I still don't know the basic format of the zone files, all I ever do is copy the ones I have now and change the domains around in them.
 
Unless you're doing this as a learning exercise, I'd highly recommend that you have someone else handle your dns for you. This is esp. true if you decide to handle email services yourself, as not going without email for days because you hosed your dns can be VERY frustrating.

If you don't have a static ip then you can go with a service such as dyndns.org. They provide scripts for various os's that will automatically update your dns entries with whatever ip address you get assigned. Some routers (Netgear) actually have support for dyndns built into them.

If you do have a static ip, then you can go with someone like google, they charge 15 a year to provide various services including dns. This route is very convenient because you also get their email services (they host the smtp and pop servers) and I guarantee that my time is worth much more than $15 year.

In either case, you go over to network solutions, log into your account, and change the dns servers that you have registered for your domain to either dyndns.org or google.com (or whoever you chose to handle the dns). Keep in mind that if you do your own dns servers, you will have to make sure your dns machine stays up all the time, or things like email will fail (i.e. if someone tries to send you an email, even if you aren't hosting your own smtp server, your dns server won't be there for the sender to find your MX record to know which machine to send the email to). Now you might get lucky and the sender might have your ip address's cached, but you see how problematic hosting your own dns can be.

If you really want to try it yourself, I would highly recommend that you still use some other dns servers to act as your secondaries, again so if anything bad happens to your dns server, there will be others to fall back on.

If your just tinkering on a domain that is just for play, then go for it. Have fun with bind, you'll learn to love nslookup. Interestingly, this is one area that Win2K shines in, setting up a dns server is mucho simple.
 
I back up binaryDigit here. Unless you really know how the files work, I would go with having someone else doing the DNS for you. It is very easy to mess up a DNS server, and it can take hours/days to get it fixed and sorted out. And in the meantime, no one will be able to connect to your webserver, or send mail to you.

Also, these files are ongoing work - you have to maintain them, you can't just set them and then leave them alone.
 
What are you setting up a server for?

If you're expecting to have high traffic and are on something like a home DSL, your bandwidth will be saturated, and your home computer (if it's not strictly dedicated as a server) could become loaded since it'll spend most of its resources serving--forget about using it for anything like games at the same time unless it's a monster machine.

If on the other hand your 'home' connection is something bigger, like an enterprise solution of some kind like a T-line or high bandwitdh DSL, see if your ISP will alias your domain for you ;) That will save you tonnes of time and possibly some money.

If you're just planning on having a few visitors (friends and family kind of thing) then dyndns or dynip are great solutions.
 
PS Most home ISPs forbid running servers, since it saturates their connections.

Check that you're allowed to run a server in the first place; if you are then they probably offer some facility for DNS aliasing themselves...
 
www.jeffntom.com is on my Mac and the DNS is hosted for FREE by ZoneEdit. They have a very functional interface that lots me do everything. They even forward my email @jeffntom.com to my ISP address.

You'll need to have your domain name registrar point to ZoneEdit's name servers before this will propagate... Give it a couple days before telling your friends and family...


The biggest newbie "Duh" that I had was not realizing that I had to keep my machine running... I thought it would work while sleeping, but now I realize how stupid that sounds.
 
Since we are entertaining newbie questions, I have one too.

I have a PowerBook that I'd like to turn Apache on for, but clearly this is not always turned on nor always on the network.

Is there a way that I can have a DNS point to it when it is on, and point to something else when it isn'? (That way I can have a Web page come up that says TommyWillB's Powerbook is sleeping now...)
 
Originally posted by TommyWillB
Since we are entertaining newbie questions, I have one too.

I have a PowerBook that I'd like to turn Apache on for, but clearly this is not always turned on nor always on the network.

Is there a way that I can have a DNS point to it when it is on, and point to something else when it isn'? (That way I can have a Web page come up that says TommyWillB's Powerbook is sleeping now...)

You can have dyndns.org host your dns. They provide software to dynamically change the ip that a dns entry points to. Can't remember now how much they charge ($15 or $35) but it does work well. Most important positive here is that the change happens immediately (dns caching not withstanding).

One alternative would be to have a machine that IS always on redirect the url when appropriate. Just depends on what you are trying to achieve.
 
Originally posted by binaryDigit
...One alternative would be to have a machine that IS always on redirect the url when appropriate. Just depends on what you are trying to achieve.
I thought of that but I can't think of what the logic would be to figure out if it is "appropriate" or not.

If I did this I'd probably host the DNS on my WinDoze IIS server and use ASP or something to do the detecting... Can IIS do something like a ping? ... or a test HTTP GET?
 
This is moving into the realm of web coding, but I think the easiest way to do it with ASP(wish I knew some more PHP) is to use Server.execute("page/script on powerbook"). You could have an ASP script that tries to execute something on your powerbook which would always return "OK" or something like that, then catch an error for when the powerbook isn't online.

I'm pretty sure that the remote script you call doesn't have to be an ASP page.

You can use the OK response to update the page that your powerbook is online, and if there's an error executing the script, then the powerbook wouldn't be online.
 
Back
Top