1834798 Members
2897 Online
110070 Solutions
New Discussion

Re: Name Resolution

 
SOLVED
Go to solution
Kathleen
Regular Advisor

Name Resolution

We made a change to our email server (Openmail 7.0 running on HP-UX 11.0) that involved an IP address change. We wanted to try and somehow set it up on our dns to automatically redirect the windows clients there were still pointing to the old external IP address to the new internal address....but I guess that can't be done.
So....now what we would like to do is allow the users to type in the name of the server. In the dns it is setup as mail.abc.def.ghi
What we would like our users to be able to do is just be able to type in a simple mail address reference and not all the extra abc.def.ghi
Can that be done somehow?
22 REPLIES 22
Tim D Fulford
Honored Contributor

Re: Name Resolution

Edit /etc/resolv.conf..
domainname abc.def.ghi

Regards

Tim
-
John Collier
Esteemed Contributor

Re: Name Resolution

Kathleen,

The fastest way to accomplish what you are wanting is to add this information to the host file in the Windoze machines.

Of course, this may not be feasible depending on how many M$ machines you have to redirect.

Other than that, the best way would be to have the DNS fully resolve the host name both forward and backward (host name to IP and IP to hostname). As long as the client PCs and the Mail host is in the same domain it should be no problem if everything is set up correctly.

For example, we have many routers and servers on our system named something like ???router1.ourdomain.com??? or ???server1.ourdomain.com???. All I need to type to get to router 1 is simply ???telnet router1???. It works ever time here???

Once again, if I have missed something then I???m sure these fine gurus will be happy to point it out ;-)
"I expect to pass through this world but once. Any good, therefore, that I can do, or any kindness that I can show to any human being, let me do it now. Let me not defer or neglect it, for I shall not pass this way again." Stephen Krebbet, 1793-1855
Kathleen
Regular Advisor

Re: Name Resolution

John, the getting it to telnet or connect like you can to just router1 is the problem I am having. I can telnet to mail.ourdomain whatever, but not to just mail

What am I missing????
Kathleen
Regular Advisor

Re: Name Resolution

John, the getting it to telnet or connect like you can to just router1 is the problem I am having. I can telnet to mail.ourdomain whatever, but not to just mail

What am I missing????
Kathleen
Regular Advisor

Re: Name Resolution

John, that is exactly what we are looking to do. Instead of mail.ourdomain we want the users to be able to use simply mail.....to telnet or use that to connect with the email clients.

how do we do that???

Right now, we can only get it to work with mail.ourdomain
John Collier
Esteemed Contributor

Re: Name Resolution

Kathleen,

Are all of the workstations part of the same domain as the mail server? Do they all resolve names through the same DNS servers?
"I expect to pass through this world but once. Any good, therefore, that I can do, or any kindness that I can show to any human being, let me do it now. Let me not defer or neglect it, for I shall not pass this way again." Stephen Krebbet, 1793-1855
Kathleen
Regular Advisor

Re: Name Resolution

yes they do, John
Kathleen
Regular Advisor

Re: Name Resolution

and yes they are....sorry I didn't say that the first time.
John Collier
Esteemed Contributor

Re: Name Resolution

Kathleen,

What happens when you bring up a command prompt on one of the Windoze boxes and type ???nslookup mail??? or ???nslookup mail.yourdomain??? or ???nslookup ????

Do you get all of them resolved to both a DNS name and an IP address? If not, then it would be time to speak to the DNS Admins about cleaning up the DNS servers.
"I expect to pass through this world but once. Any good, therefore, that I can do, or any kindness that I can show to any human being, let me do it now. Let me not defer or neglect it, for I shall not pass this way again." Stephen Krebbet, 1793-1855
Kathleen
Regular Advisor

Re: Name Resolution

IP works, mail.mydomain works....the only one that doesn't work is mail

We are trying to figure out how to get that working.
Ron Kinner
Honored Contributor

Re: Name Resolution

In /etc/resolv.conf do you have a line which starts with domain? If it says
domain .ghi

then if you ask it for mail it will tack on .ghi and get mail.ghi which won't work. If the DNS is serving multiple subdomains then you're probably out of luck but if it only serves abc.def.ghi then adding (or changing) the line to read
domain abc.def.ghi

will fix that problem.

You can also use the search line:

search abc.def.ghi def.ghi .ghi

to get it to try adding on the correct domain tag. You can use this when it serves multiple domains as long as there are only 6 and the names don't overlap (you can't have mail.abc.def.ghi and mail.jkl.def.ghi. You only get 6 choices and the order tried is from left to right. A match stops the search. Works in 4.8.3 and newer.

the search line and default line override each other so the last one in resolv.conf wins.

Ron

Kathleen
Regular Advisor

Re: Name Resolution

using just nslookup mail works on the dns...I think because there is referrence to it in the hosts files. But we still cannot telnet using just mail. We need to use mail.mydomain
Kathleen
Regular Advisor

Re: Name Resolution

In regard to the /etc/resolv.conf file....are you talking in regard to the dns or the mail server, specifically
Kathleen
Regular Advisor

Re: Name Resolution

Ok....new finding. We can telnet to mail from any of our unix servers. When we try to telnet mail from within windows, it doesn't work.....

Any ideas?
John Collier
Esteemed Contributor
Solution

Re: Name Resolution

Kathleen,

If you can do what you want from any of the Unix boxes but can???t from the Windoze machines, then what worked for the Unix boxes will also work for the Windoze machines. I am, of course, referring to an entry in the ???hosts??? file on each of the M$ machines.

If yours is a small company with only a small handful of these types of systems, then this will not be a major undertaking for your M$ System Admins. If it is a large company, then perhaps your Domain Admins could write a script (or batch file as they are usually referred to in M$ speak) to automatically update each machines??? host file.

This would be a workable solution if nothing better comes along.

If your DNS is hosted on a HPUX box, this thread may be helpful to you:
http://forums.itrc.hp.com/cm/QuestionAnswer/1,,0x151e8f960573d611abdb0090277a778c,00.html

I???m searching for the host-file information on the Windoze machines right now???
"I expect to pass through this world but once. Any good, therefore, that I can do, or any kindness that I can show to any human being, let me do it now. Let me not defer or neglect it, for I shall not pass this way again." Stephen Krebbet, 1793-1855
Ron Kinner
Honored Contributor

Re: Name Resolution

The window hosts files on 2000 and probably XP are in winnt\system32\drivers\etc.

If you make the resolve.conf change then it should work without an entry in hosts if you have restarted the dns server after making the change.

You could set up a WINS box on the network to make it easier for your window boxes to find hosts or just check use DNS in the advanced network setup.

Ron
Mark Greene_1
Honored Contributor

Re: Name Resolution

What version of DNS? Apologies if I missed where you posted that.

In your DNS host information file, you need to define the mail server in an A record by IP address at the DOMAIN level. This should be one of the first lines right after your SOA record.

You can then setup a cname in the same file as "mail.domain.com". You will also need a reverse address setup in the in-addr.arpa domain.


You need to have a "domain" statement in your /etc/resolv.conf file to specify the default domain. Then go back and make sure that the fully qualified name in the DNS host file ends with a period, so the domain isn't tacked on a second time by named.

HTH
mark
the future will be a lot like now, only later
Mark Greene_1
Honored Contributor

Re: Name Resolution

Sorry, I knew I was going to miss something.

This part:

"Then go back and make sure that the fully qualified name in the DNS host file ends with a period, so the domain isn't tacked on a second time by named."

applies only to CNAME records, obviously.

mark
the future will be a lot like now, only later
John Collier
Esteemed Contributor

Re: Name Resolution

Kathleen,

Here???s what I found on the Windoze host files:

Try to locate any existing hosts file on your computer:
Windows 95/98/Me c:\windows\hosts
Windows NT/2000/XP Pro c:\winnt\system32\drivers\etc\hosts
Windows XP Home c:\windows\system32\drivers\etc\hosts
(you will need administrator access for Windows NT/2000/XP)
From there you should be able to find something along the lines of either ???lmhosts.sam??? or ???hosts.sam??? or simply a file named ???hosts???.

If you have a files simply named ???hosts??? then you are already using a host file on that machine and you just need to add the information you want the machine to act on to the end of that file. Before you make these changes, it would be highly recommended to make a backup copy of the original ???hosts??? file.

If it is something like ???lmhosts.sam??? then you are currently not using the host file on that machine and you will want to open the file, add your entries to it, and then do a ???Save As?????? to save the file with the name ???hosts??? (with no extension of any kind).

You can easily open and edit the above files using M$ Notepad ({Shitf+Right_Mouse_Button} and then select ???Open With??? from the dropdown tab or you can simply double-click on it and then choose ???Notepad??? from the options that come up)

When you finally do get this resolved, please let us know exactly what you did to resolve this issue (a few points would be appreciated as well ;-)
"I expect to pass through this world but once. Any good, therefore, that I can do, or any kindness that I can show to any human being, let me do it now. Let me not defer or neglect it, for I shall not pass this way again." Stephen Krebbet, 1793-1855
Kathleen
Regular Advisor

Re: Name Resolution

I will make sure to get points out there....

We were trying to avoid changing the host files on all of our windows pcs (we have MANY, MANY computers in our environment).

We were hoping that it could be done through changes or references in the DNS.
Mark Greene_1
Honored Contributor

Re: Name Resolution

Kathleen,

The host file need not exist on the PCs at all for this to work. You just have to have a "domain" statement in your /etc/resolv.conf file to specify the default domain. Do man on resolv.conf for the full explanation and syntax.

mark
the future will be a lot like now, only later
John Collier
Esteemed Contributor

Re: Name Resolution

Kathleen,

You never did tell us if the DNS servers are being hosted on HP-UX boxes or some other type of server. If they are on the HP-UX boxes, I found this link to the HP docs in another thread that could be very useful to your DNS Admin folks.

http://www.docs.hp.com/hpux/pdf/B2355-90147.pdf

If it???s on a different flavor of system, then there is still some more investigation to be done.



PS To give credit where credit is due, I didn???t personally come up with the link to the above PDF file. I found it on a reply by Con O'Kelly on this thread:

http://forums.itrc.hp.com/cm/QuestionAnswer/1,,0x008f227a6ab4d711900a0090279cd0f9,00.html

Thanks for the link Con!
"I expect to pass through this world but once. Any good, therefore, that I can do, or any kindness that I can show to any human being, let me do it now. Let me not defer or neglect it, for I shall not pass this way again." Stephen Krebbet, 1793-1855