LinuxQuestions.org
Download your favorite Linux distribution at LQ ISO.
Home Forums Tutorials Articles Register
Go Back   LinuxQuestions.org > Forums > Linux Forums > Linux - Distributions > Debian
User Name
Password
Debian This forum is for the discussion of Debian Linux.

Notices


Reply
  Search this Thread
Old 09-08-2005, 11:29 PM   #1
Akhran
Member
 
Registered: Aug 2005
Distribution: Debian 'lenny'
Posts: 208

Rep: Reputation: 30
How to update the domain name without reboot the server?


In the file /etc/resolv.conf, I have
Code:
search home.intranet
nameserver 192.168.1.1
In the file /etc/network/interfaces, I have the following lines at the end of the file
Code:
.
.
.
dns-search home.intranet
I would like to change the domain name from home.intranet to test.intranet. How should I go about doing it without restarting the server?

I have tried to update the resolv.conf by changing 'search home.intranet' to 'search test.intranet'. Then I edit the interfaces file by changing 'dns-search home.intranet to 'dns-search test.intranet' (is this step necessary?) Followed by a
Code:
/etc/init.d/networking restart
However, when I checked the domain name with
Code:
# dnsdomainname
it is still showing the old name.

Please advise, thanks !
 
Old 09-09-2005, 01:30 AM   #2
DaneM
Member
 
Registered: Oct 2003
Location: Chico, CA, USA
Distribution: Linux Mint
Posts: 881

Rep: Reputation: 130Reputation: 130
I'm not sure about Debian, but in SuSE it's in /etc/HOSTNAME. In Slackware it's the same but in lowercase.

HTH

--Dane
 
Old 09-09-2005, 02:14 AM   #3
Akhran
Member
 
Registered: Aug 2005
Distribution: Debian 'lenny'
Posts: 208

Original Poster
Rep: Reputation: 30
What I wanted to change is the name of the domain ie. from home.intranet -> test.intranet, not the hostname of the server.

Sorry for being ambiguous

Thanks for your reply!
 
Old 09-09-2005, 05:19 AM   #4
MiscGeek
Member
 
Registered: Jan 2003
Location: Georgia, US
Distribution: RHEL WS4
Posts: 189

Rep: Reputation: 30
Maybe a dumb question, but have you updated your name server?
 
Old 09-09-2005, 07:44 AM   #5
MensaWater
LQ Guru
 
Registered: May 2005
Location: Atlanta Georgia USA
Distribution: Redhat (RHEL), CentOS, Fedora, CoreOS, Debian, FreeBSD, HP-UX, Solaris, SCO
Posts: 7,831
Blog Entries: 15

Rep: Reputation: 1669Reputation: 1669Reputation: 1669Reputation: 1669Reputation: 1669Reputation: 1669Reputation: 1669Reputation: 1669Reputation: 1669Reputation: 1669Reputation: 1669
If all you want to do is change which domain you're searching for just add it to /etc/resolv.conf. If you want to change the domain of the host itself you need to do that separately. resolv.conf has nothing to do with the host's own domain but rather specifies what domains to append to host names when searching.

Also you can have more than one domain and nameserver in resolv.conf as for example:


search home.intranet test.intranet
nameserver 192.168.1.1
nameserver 192.168.1.2

So doing a nslookup (or dig as Linux prefers) for host name "billybob" it would first look for billybob.home.intranet and if not found then billybob.test.intranet.
 
  


Reply



Posting Rules
You may not post new threads
You may not post replies
You may not post attachments
You may not edit your posts

BB code is On
Smilies are On
[IMG] code is Off
HTML code is Off



Similar Threads
Thread Thread Starter Forum Replies Last Post
update - now won't reboot Alfie67 SUSE / openSUSE 6 03-31-2005 12:21 PM
update 9.1 to 9.2: SuseConfig on every Reboot ibert SUSE / openSUSE 1 02-14-2005 07:23 AM
Named slave update fails: "Server is not an authority for the domain" usernamenumber Linux - Networking 0 09-29-2004 10:42 PM
kernel update under YOU: need reboot? why? bruno buys Linux - Distributions 2 06-20-2004 06:58 PM
Red Hat Kernel does not update on reboot. Buckinator Linux - Software 4 08-23-2003 08:50 PM

LinuxQuestions.org > Forums > Linux Forums > Linux - Distributions > Debian

All times are GMT -5. The time now is 05:36 AM.

Main Menu
Advertisement
My LQ
Write for LQ
LinuxQuestions.org is looking for people interested in writing Editorials, Articles, Reviews, and more. If you'd like to contribute content, let us know.
Main Menu
Syndicate
RSS1  Latest Threads
RSS1  LQ News
Twitter: @linuxquestions
Open Source Consulting | Domain Registration