i have up a web server and a mail server using debian on the same pc. Now i want to break down the webserver and mail server into two different Pcs, i.e have the web server on one PC and the mail server on a second PC. I will be very grateful if you could help by telling me what configuration i have to do, i have searched everywhere but i still dont know how to do it. My main problem is i dont know what to do with the DNS, * Should i intall it on the web server? If i do, what configuration do i have to do with the mail server? How do i access the mailserver from the Internet? (Through Phpmyadmin). How do iconfigure apache on the mailserver. * My web server is also using mysql and phpmyadmin. Can you please help me how to setup my dns, and i have only one IP address? . can i have one web server on this address "http://www.npccmauritius.com" and "http://mailserver.npccmauritius.com/ Thanking you in advance
Let's assume your servers have the IP addresses 1.2.3.4 (webserver) and 1.2.3.5 (mailserver). In DNS, you'd create the following records: npccmauritius.com. A 1.2.3.4 www.npccmauritius.com. A 1.2.3.4 mailserver.npccmauritius.com. A 1.2.3.5 npccmauritius.com. MX 0 mailserver.npccmauritius.com.
can i create a new website with the following address http://mailserver.npccmauritius.com and a new mail server [email protected] from the domain npccmauritius.com ? if yes how do i do so? thanks
How do i create the website, i want to put it on another pc? how do i add it to my current dns server configuration. is this setting up a subdomain?
Do you use a control panel like ISPConfig? If not, take a look here: http://httpd.apache.org/docs/2.0/vhosts/name-based.html If you use BIND, take a look at this tutorial: http://www.howtoforge.com/traditional_dns_howto
I have configured my dns server and added the following configuration to it: $ORIGIN test.mailserver.npccmauritius.com test IN A 192.168.192.42 IN MX 10 test.mailserver.npccmauritius.com. check IN CNAME test.mailserver.npccmauritius.com. when i ping check.npccmauritius.com, it responds but i get the content of what is on www.npccmauritius.com how do i redirect it to the check.npccmauritius.com? can i add it in the Virtual host part in Apache? I have tried to add it in the httpd.conf but it still redirects to www.npccmauritius.com. Sorry for all inconvenient caused, i am getting some light now Thanks a lot for your help
Are you sure you want to use a local IP address for a DNS record? Did you create an Apache vhost for check.npccmauritius.com? Because otherwise your requests go to the default vhost.
Is it wrong to add an internal IP in Dns? I have added the following in the httpd.conf NameVirtualHost 192.168.192.42 <VirtualHost 192.168.192.42> ServerName check.npccmauritius.com DocumentRoot /var/www/ </virtualHost> but still it redirects to www.npccmauritius.com
If noone else then poele in your local setup shall lookup the domain, then thats fine. If someone from the internet shall be able to lookup this domain, you will have to use a official (external) IP address.
why is it that i cannot access the web site that is on the check.npccmauritius.com (i.e 192.168.192.42)? do i have to do another configuration somewhere?
the result of IPCONFIG is eth0 Link encap:Ethernet HWaddr 00:04:75:c8:95:b1 inet addr:192.168.192.1 Bcast:192.168.192.255 Mask:255.255.255.0 UP BROADCAST RUNNING MULTICAST MTU:1500 Metric:1 RX packets:1024 errors:1 dropped:0 overruns:0 frame:0 TX packets:1024 errors:0 dropped:0 overruns:0 carrier:0 collisions:0 txqueuelen:1000 RX bytes:155132 TX bytes:620 Interrupt:28 lo Link encap:Ethernet local loopback inet addr:127.0.0.1 Mask:255.0.0.0 UP BROADCAST RUNNING MULTICAST MTU:3924 Metric:1 RX packets:1024 errors:1 dropped:0 overruns:0 frame:0 TX packets:1024 errors:0 dropped:0 overruns:0 carrier:0 collisions:0 txqueuelen:1000 RX bytes:218 TX bytes:23909
the ifconfig result is as follows: eth0 Link encap:Ethernet HWaddr 00:04:75:c8:95:b1 inet addr:192.168.192.1 Bcast:192.168.192.255 Mask:255.255.255.0 UP BROADCAST RUNNING MULTICAST MTU:1500 Metric:1 RX packets:1024 errors:1 dropped:0 overruns:0 frame:0 TX packets:1024 errors:0 dropped:0 overruns:0 carrier:0 collisions:0 txqueuelen:1000 RX bytes:155132 TX bytes:620 Interrupt:28 lo Link encap:Ethernet local loopback inet addr:127.0.0.1 Mask:255.0.0.0 UP BROADCAST RUNNING MULTICAST MTU:3924 Metric:1 RX packets:1024 errors:1 dropped:0 overruns:0 frame:0 TX packets:1024 errors:0 dropped:0 overruns:0 carrier:0 collisions:0 txqueuelen:1000 RX bytes:218 TX bytes:23909
What's the vhost configuration of www.npccmauritius.com? Please make sure you use 192.168.192.1 instead of 192.168.192.42 in your Apache configuration.
NameVirtualHost 192.168.192.42 <VirtualHost 192.168.192.42> ServerName check.npccmauritius.com DocumentRoot /var/www/ </virtualHost> isn't this vhosts?