John Easton
asked on
Linux Static IP register in Domain DNS
I am completely new to Linux and therefore I hope this is a simple query for those of you who know what they are doing.
Firstly the background. I have create a Virtual Server on Windows 2008 R2 on which I have installed Linux Mint 14. I have given it a fixed IP and opened up our firewall to allow internet access to this IP address. This all works fine and I have installed Apache, mySQL and PHP sucessfully.
My problem is with my network DNS. At present I can access my new linux box by IP, but it hasn't registered itself with our DNS server. Therefore when trying to access by name from another computer on our LAN it cannot find it.
I have set the network connection to use our domain name servers, however the resolv.conf file shows a nameserver of 127.0.1.1 which doesn't seem right to me.
Your help will be greatly appreciated.
Firstly the background. I have create a Virtual Server on Windows 2008 R2 on which I have installed Linux Mint 14. I have given it a fixed IP and opened up our firewall to allow internet access to this IP address. This all works fine and I have installed Apache, mySQL and PHP sucessfully.
My problem is with my network DNS. At present I can access my new linux box by IP, but it hasn't registered itself with our DNS server. Therefore when trying to access by name from another computer on our LAN it cannot find it.
I have set the network connection to use our domain name servers, however the resolv.conf file shows a nameserver of 127.0.1.1 which doesn't seem right to me.
Your help will be greatly appreciated.
ASKER
I set the static IP under Network, then Wired Network, the IP v4 Tab. I also set the DNS search and search domain here.
I tried added nameserver in resolv.conf but it is cleared when the server is restarted. The file has the header:
I should note that I am using the default GUI that came with Linux Mint which I believe is Cinnamon.
I tried added nameserver in resolv.conf but it is cleared when the server is restarted. The file has the header:
# Dynamic resolv.conf(5) file for glibc resolver(3) generated by resolvconf(8)
# DO NOT EDIT THIS FILE BY HAND -- YOUR CHANGES WILL BE OVERWRITTEN
I should note that I am using the default GUI that came with Linux Mint which I believe is Cinnamon.
Sounds like Networkmanager is running. Try the following -
# No nameservers found; try putting DNS servers into your
# ifcfg files in /etc/sysconfig/network-scripts like so:
#
# DNS1=xxx.xxx.xxx.xxx
# DNS2=xxx.xxx.xxx.xxx
# DOMAIN=lab.foo.com bar.foo.com
ASKER
Where do I make this change? I can't see a folder called sysconfig under etc.
ASKER CERTIFIED SOLUTION
membership
This solution is only available to members.
To access this solution, you must be a member of Experts Exchange.
ASKER
This had made some progress. I also added a dns-domain entry. The resolv.conf now shows the DNS servers I want, plus that 127.0.1.1 address.
Interestingly I can now ping the linux computer from my desktop, but it is still not listed in the DNS server (i.e. I cannot do an NSLookup).
Before giving the computer a static IP (i.e. it got one from DHCP) it did register in DNS - so I know it must be possible.
I think I'm going to call it a day for now and pick it up again tomorrow.
Interestingly I can now ping the linux computer from my desktop, but it is still not listed in the DNS server (i.e. I cannot do an NSLookup).
Before giving the computer a static IP (i.e. it got one from DHCP) it did register in DNS - so I know it must be possible.
I think I'm going to call it a day for now and pick it up again tomorrow.
ASKER
It think in order to save time I will simply add the record manually to DNS. It does mean that if I change the IP address in the future I will have to update DNS, but this is not going to happen too often I hope!
Try adding your DNS servers in resolv.conf -
Open in new window