LinuxQuestions.org

LinuxQuestions.org (/questions/)
-   Linux - Newbie (https://www.linuxquestions.org/questions/linux-newbie-8/)
-   -   Name Resolving (https://www.linuxquestions.org/questions/linux-newbie-8/name-resolving-779992/)

jjena 01-05-2010 08:33 AM

Name Resolving
 
Hi,

I am new to Linux. I am using Redhat Enterpise 5 version. Now I want to configure DNS for only local (Intranet) name resolution. So that users can simply type the local website address and access the site.

Kindly tell me the step by step procedure to configure the same.

Regards,
Jyotirmay

thePiet 01-05-2010 08:52 AM

I'm using DNSMasq for that kind of stuff, check out http://www.thekelleys.org.uk/dnsmasq/doc.html if this application suits your needs.

jjena 01-06-2010 08:20 AM

Name resolving
 
Hi,
Thanks for advice ...
I have installed & follow the configuration instruction.

Now please tell me where can I add the local & ip address (such as local mail & portal). So that by using the address of DNSMASK PC as DNS the user can open the .

For Example:

Now they are opening the url by typing- http://10.16.2.3/webmail/src/login.php

---------------->

What I want that they can open by simply typing- mail.sarda.co.in



As I told you that I am very new to linux. So please help me in this.

Regards,
Jyotirmay

thePiet 01-07-2010 02:39 AM

By default, DNSMasq reads /etc/hosts for local entries. DNSMasq allows you to manually enter hosts with their IP addresses in a file, e.g. /etc/hosts . This way you can add an entry like:

foobar 10.0.0.1
bazfoo 10.0.0.2
thishostdoesnotexist 10.0.0.3

Etcetera. Plus, if you also run DHCP with DNSMasq and you set DNSMasq as DNS server on your clients, DNSMasq will respond to requests of local machine names. For example, if you have a box called "box1" and that box is getting it's IP from DNSMasq, other clients using your DNSMasq installation as DNS server can resolve box1.

In /etc/dnsmasq.conf:

# If you don't want dnsmasq to read /etc/hosts, uncomment the
# following line.
#no-hosts
# or if you want it to read another file, as well as /etc/hosts, use
# this.
#addn-hosts=/etc/banner_add_hosts

jjena 01-07-2010 06:47 AM

Hi,
Again thanx a lot for your help. I am not using DHCP. I only wants to configure the host file for name resolving. My host file is looks like the bellow.
# Do not remove the following line, or various programs
# that require network functionality will fail.
127.0.0.1 localhost.localdomain localhost
::1 localhost6.localdomain6 localhost6
72.9.243.250 joomla.com joomla
192.9.100.18 manager



Suppose that my mail server address is - http://170.16.2.3/webmail/

and I want to give the name mail.someone.co.in.

Now please gude me how can I add this to my Host file.

Regards,
Jyotirmay

thePiet 01-08-2010 02:46 AM

Well, simply append

170.16.2.3 mail.someone.co.in

To /etc/hosts and restart DNSmasq.


All times are GMT -5. The time now is 02:50 PM.