Web Server How to run a simple web server at home For some people who have a personal website or dabble in the world of web, web hosting is something that must be held. By using a web hosting company, a person can have the freedom to manage the web sites run. Some of them like the arrangement of domain names, subdomains, web server setup, configuration files, email and so forth. And of course all be done by renting a space or a place in the web hosting service providers. What if we tried to use a computer at home to build simple web hosting? Nothing hurts to try, and here I'll give some tips and tricks how to build a web hosting / server in the house aka home web server. There are several requirements to run a simple web server at home. Some of them are as follows: * Internet Service Provider (ISP) and private IP public (non-shared). Generally, an IP provider who provides public like this is a broadband provider in which the IP is not shared for use by other users, I do not know what the dynamic or static IP (it would be great if static so that every time connected, IP it will not change). While dial-up providers generally use one IP for multiple computers that are connected to the internet that will allow the development of a web server. In the example here I use Streamyx package as providernya using Dynamic IP. * Modem or router. Generally, the modem is only heading to a client does not need a configuration that means, but when using a wireless router as I do, then you will be little need to set the router configuration like port forwarding or firewall to open the modem or router. In the example here, I'm using Linksys WAG200G modem. * Server. It should not be using IBM or HP servers based on Xeon or Opteron is very expensive. Even ordinary computer or laptop with a modem and the ISP that I referred to above can also be used as a web-server. I myself using a laptop that is connected to WiFi to my Linksys modem at the top. Operating system the server can be Windows, Linux or others. * Software such as Apache webserver and software-support software such as PHP, MySQL, and so forth. * Domain name. Rather difficult to apply directly for a domain to point to an IP address for the server is particularly simple as using a Dynamic IP. The solution is to use the service DynDNS.com that will change a domain name (more precisely a subdomain) to point to your server IP. About this will be explained below. * The knowledge base of networking, such as how to set the IP address based on their respective operating systems, how to set the modem or router, and some networking terms (terms that do not understand can be found on the internet). Attention! By trying to make a home web server, you will open up the possibility of your computer accessible by others from outside (remote). Please pay attention to security software such as firewalls and antivirus software for the always active and always updated before opening your web server to be accessed from outside. Above is a diagram showing the scheme about how the IP address of the router settings, ISP and others in the house. In the diagram above, I take the example that I got the IP address 18.104.22.168 from the ISP that I use and this IP is dynamic, which means it will change when I re-do the connection to the ISP. Gateway of the router that I use is set to use IP address 192.168.1.1. While the laptop that I use as a home web server is set manually (without DHCP) to use the IP address 192.168.1.110, while the IP address of the PC to the right set automatically by the modem. To find the IP address of the ISP-assign you, try to access the status of your modem is generally to be found by opening the browser address http://192.168.1.1/ commonly used, or use a service-service to detect IP Internet. Once you know the IP of in-assign by your ISP, it is time to turn off the firewall for the ports that are generally used for HTTP is port 80. For Windows users (I tried for Windows XP), it can be done through Control Panel> Windows Firewall. Then the Exception tab and select the "Add port ...", enter the name "HTTP" or the other, enter port number 80 and select the TCP protocol, then press OK. So by checking the HTTP port of your computer will be open for access by other computers. For Linux (in particular the use Ubuntu), when it is still new and not installed a firewall, do not need to configure at all. Whereas when using other firewall program, try to find ways to advance the exception or provide access to port 80. Now run the web server program and other support programs such as PHP or MySQL and others. If you just use the normal modem, you can try to type the IP address obtained from the ISP in your browser. If there is no other configuration is required, it will automatically appear on web pages that are home web server. And not directly, that means your modem is not very safe to use because there is not a firewall and other facilities can only access the computer / server you directly, and vulnerable to malicious actions such as cracking and hacking. But after trying to access via web browser using the IP address from your ISP did not show anything, it is possible that what you are doing is still blocked by the router or modem configuration, one port forwarding. Now the difficult part is the port forwarding. If you use a router as I could connect a lot of clients and enable DHCP server on your router, then you should do is clicking-assign / set the IP manually on the server you use. Why? Because DHCP makes IP diassign can vary depending on the client is connected to the router. In the example above, I assign IP address 192.168.1.110 for the laptop that I use as a home web server. Besides generally requires the use of port forwarding the same IP address (unless there is a router / modem that can automatically detect that the laptop at any time if I change the IP). To configure port forwarding in your router or modem, log into your router (usually using the web browser and type 192.168.1.1 in the address bar of it). Then find the port forwarding, and enter some parameters below in a set of fields that will be in the forward port. I use a Linksys WAG200G, then the following fields are visible, but when using a router / modem may be different from others. * Name / Application: HTTP (this section is not very influential, just general descriptions only) * IP address: 192.168.1.110 * Internal port: 80 * External port: 80 * Protocol: TCP * Enabled: Yes / Check Now as before, open your browser, type the IP address of in-assign from ISP to the gateway / router / modem, see the results. When the display is visible as when you type localhost in the address bar, it can be said that the measures you use have been successful. If not, then chances are there are still some things that make the web server can not be accessed, usually because of problems at the server firewall, router, or modem. Therefore, when finding such a problem, please try again. What if had been successful? What is just enough here? No! For some people, memorize your IP address, what else is changing the dynamic alias is quite difficult and inconvenient. We will try to use Dynamic DNS (Domain Name Service) is useful to change a domain address (such as www.example.com) into your IP address. Dynamic DNS service provider for the widely used is tzo.com and DynDNS.org. What if had been successful? What is just enough here? No! For some people, memorize your IP address, what else is changing the dynamic alias is quite difficult and inconvenient. We will try to use Dynamic DNS (Domain Name Service) is useful to change a domain address (such as www.example.com) into your IP address. Dynamic DNS service provider for the widely used and tzo.com DynDNS.org. DynDNS.org provide services free of charge, but tzo.com require users to pay, so I was more suggesting DynDNS.org. Create an account at DynDNS.org, then select "Add Host Service", and the contents according to the following: * Hostname: select the subdomain and the domain that you will use to point to your IP. * Wildcard: can you choose or not. If selected, so there are sub-subdomains of the hostname of your content, it will be fixed automatically redirected to your IP. * Service Type: Host with IP address * IP Address: Fill in your IP address. Or just select "Use auto detected IP address" that will make the field is filled automatically. * Mail routing: no need to get selected unless you need an email facility for the hostname (which means not included in this description). After all the fields filled in, select Create Hosts and agree to "purchase" price of $0, then the hostname will be "owned" your IP. Generally, some routers have a facility to assign a domain name automatically. Therefore, you need to know the about the router / modem with the search category menu or DNS DDNS there. When using a Linksys WAG200G, the menu can be accessed via the Setup> DDNS. Select DynDNS.org for DDNS service, fill your username and password you created at DynDNS.org account, fill in the hostname that you have previous message, and click connect. After that, when there are status "Connected Successfully", meaning that all went well, and when the modem / router you are connecting back to the ISP, new IP automatically be directed to use the hostname without having to open the dyndns.org site again. If the router / modem you do not provide the service as above, then you should visit the site every time you want to change its IP address. Similarly, few guidelines to make the home web server using DDNS. If there are any questions, suggestions or improvements, please be submitted via the comment section. If you want to adapt or copy-and the content of this article, please include a link back to this article. Hopefully this article will be useful for you.