I just got my dedicated server. It's running RedHat 7.2. I installed Apache 1.3.26, Php, MySQL, and Webmin. Everything works fine locally, now I have to configure it for the web. How should I go about this? I will be hosting a couple of domains and I want them each to have their own space in Apache and FTP accounts. Obviously I have to use DNS one way or another. How do I do this? Do I install a DNS server on my server and add my server's ip address to the DNS info under the domains? If so, how do I route the incoming requests from different domains to various apache folders? Does this have something to do with Virtual Servers in Apache?
I know they're a lot of questions. Your help is greatly appreciated.
If you dont know how to do it, it is best to keep DNS off the server. Use zoneedit.com or everydns.net.
Actually web hosting is very very simple. We are all needlessly complicating it.
You need an FTP server for users to publish their sites. Use ProFTPd. You can put a simple configuration file disabling anon FTP and putting RequireValidShell On [or YES cant remember]. So only SSH users can FTP to the server.
If you do this, there are only 4 steps to creating a virtual host [assuming your mail and DNS is outside the server and ProFTPd is set up as mentioned above] - the 4th being the most important for a site's uptime.
1. Create a unix user with a bash shell
2. Create a virtualhost container for the user's domain in httpd.conf ; save httpd.conf; "apachectl graceful" for restarting httpd.
3. Point the domain's DNS to the IP on which httpd is listening
4. Relax and Go have a Beer!
This is a basic set up that can go quite far. Further tuning is upto you. But if you want to set up SMTP, POP3 or IMAP for your virtual domains it is quite a complicated business .
Offering Managed Servers - for an exclusive clientèle who value uptime, caring support and superior technology.
Motley, thanks for the somewhat detailed explanation. I just read it. But before reading I got everything to work. . I ended up using MyDomain.com IP pointing. Apache's name server made it so easy. The longest part was getting ProFTPd to work but I got that down. Everything is working now.