LinuxQuestions.org
Register a domain and help support LQ
Go Back   LinuxQuestions.org > Forums > Linux Forums > Linux - Newbie
User Name
Password
Linux - Newbie This Linux forum is for members that are new to Linux.
Just starting out and have a question? If it is not in the man pages or the how-to's this is the place!

Notices


Reply
  Search this Thread
Old 12-20-2006, 12:14 PM   #1
amministratore_g24ux
LQ Newbie
 
Registered: Dec 2006
Posts: 2

Rep: Reputation: 0
Change of network id


Just a simple question for most of you, guys.
I have just finished setting up a new Redhat Linux machine to act as mail server with a temporary IP address and name (the symbolic name just before the dot domain) in order to let the original old server run freely while I was preparing the new machine.
Now that everything seems to work fine, I want to shutdown the old machine and let the new one take its place: name and IP.
Where are ALL the places where the name and IP number are stored and must be changed? Which daemons are to be restarted? Please notice that I cannot find anything like ifconfig or similar programs; I ned to do everything manually.

Important running programs are
sendmail
tcpd (xinetd)
openssl (I will have to redo the certificate changing the name, I believe)
pop2d
pop3d
imapd
httpd
sshd
etc etc

Thank you very much
 
Old 12-20-2006, 06:46 PM   #2
Brian1
LQ Guru
 
Registered: Jan 2003
Location: Seymour, Indiana
Distribution: Distribution: RHEL 5 with Pieces of this and that. Kernel 2.6.23.1, KDE 3.5.8 and KDE 4.0 beta, Plu
Posts: 5,700

Rep: Reputation: 62
Are you changing to root with ' su ' or ' su - '. If ' su ' then it will not find ifconfig because it is not in the path. When you just su it changes to root but still ueses the users enviroment variables. Using su - is root and root's enviroment variables and /sbin is in the path of root. /sbin is not part of a users path.

Now mostly you should only need to down the nic and I assume it is eth0. Do the following as root
/sbin/ifdown eth0
/sbin/ifconfig and set the IP it will be now.
make sure the old server is down before bringing up the new server if using the same IP as the old server.
/sbin/ifup eth0

Now not sure if sendmail, pop3d, imapd will need editing.
For httpd if apache should not, sshd will not need changed.
I doubt any really need restarted but to restart sshd it would use a command like this as root. ' /sbin/service sshd restart ' Similiar for the rest.

Brian
 
Old 12-20-2006, 09:32 PM   #3
farslayer
LQ Guru
 
Registered: Oct 2005
Location: Willoughby, Ohio
Distribution: linuxdebian
Posts: 7,232
Blog Entries: 5

Rep: Reputation: 190Reputation: 190
Use the following guides to check and set your hostname properly.

http://www.cpqlinux.com/hostname.html

http://www.debianadmin.com/change-ho...x-machine.html
 
Old 12-23-2006, 09:41 AM   #4
amministratore_g24ux
LQ Newbie
 
Registered: Dec 2006
Posts: 2

Original Poster
Rep: Reputation: 0
Thank you for the suggestions but I think I have finally found the reply to my answer and would like to check with you.
As I expected there are two important files to edit/change in RedHat:
/etc/sysconfig/network
/etc/sysconfig/network-scripts/ifcfg-eth0

After the editing, some proper restart or reboot is obviously due.
Changing them appears to make the changes permanent even for future reboots. I just wonder if there are other hidden places somewhere else used by secondary programs.
 
Old 12-23-2006, 08:41 PM   #5
farslayer
LQ Guru
 
Registered: Oct 2005
Location: Willoughby, Ohio
Distribution: linuxdebian
Posts: 7,232
Blog Entries: 5

Rep: Reputation: 190Reputation: 190
Only all the other places listed in the link I posted for you....

No reboot should be necessary this is Linux not Windows..

at the most if you want to restart something do /etc/init.d/networking restart.
 
  


Reply

Tags
ip


Thread Tools Search this Thread
Search this Thread:

Advanced Search

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
change network settings mattsoftnet Linux - Networking 2 02-27-2006 09:01 AM
network name change>Suse10 N.V.M. Linux - Networking 0 02-01-2006 05:44 PM
change name on a network amon Linux - Networking 2 07-23-2005 11:53 AM
change of network options changes X spedsta Linux - Networking 2 06-17-2004 06:27 AM
Network card change jpc82 Linux - Networking 3 12-06-2001 09:31 AM


All times are GMT -5. The time now is 12:41 PM.

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
Facebook: linuxquestions Google+: linuxquestions
Open Source Consulting | Domain Registration