LinuxQuestions.org
Welcome to the most active Linux Forum on the web.
Go Back   LinuxQuestions.org > Forums > Linux Forums > Linux - Networking
User Name
Password
Linux - Networking This forum is for any issue related to networks or networking.
Routing, network cards, OSI, etc. Anything is fair game.

Notices


Reply
  Search this Thread
Old 07-06-2003, 04:34 AM   #1
aherrys
Member
 
Registered: Jul 2003
Posts: 85

Rep: Reputation: 15
cannot change ip address ???


Hi,

I have a RH 7.2 box with the latest kernel (2.4.20-18.7). I used this box for trouble shooting network problem. I noticed that somehow when I move the machine from one network to another, and I need to change IP addres on the box, I CANNOT just simply do the following:
change the /etc/sysconfig/network-scripts/ifcfg-eth0 to point to my new IP address, broadcast and network
change the default gateway on /etc/sysconfig/network
go to /etc/init.d and do ./network restart (or even ./network stop and ./network start)

After I have done the above and run ifconfig, my IP address still hasn't changed. I have to reboot the machine before the changes I made on the ifcfg-eth0 and network files take effect. It is worst than winXp though...!!

I even tried ifconfig eth0 down/up but still the old address persist. The only other way I can make the change takes effect without rebooting is if I run ifconfig eth0 down and then issue command:
ifconfig eth0 xxx.xxx.xxx.xxx netmask xxx.xxx.xxx.xxx up
and the machine complains SIOCSIFADDR:FILE EXIST
and then run ifconfig eth0 up
If I do this the ifconfig then will report the correct new address.

I swear that on the old version of RH 7.2 kernel, (the orginal one that came out of the CD) didn't do this. On that one, I could just simply restart my eth0 and the changes I made took effect.

Anybody can shed a light on this and provide an elegant way to change the IP address ?

Thanks
 
  


Reply


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 Ip address luisator Linux - Newbie 3 06-02-2005 05:03 AM
won't change ip address xushi Solaris / OpenSolaris 4 05-14-2005 04:11 AM
Change IP address lvran Linux - Networking 2 10-16-2003 02:19 AM
How do you change the IP Address? Diablotrickster Slackware 4 08-28-2003 08:31 PM
Change IP address ust Linux - Networking 5 06-12-2003 01:18 PM

LinuxQuestions.org > Forums > Linux Forums > Linux - Networking

All times are GMT -5. The time now is 02:05 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
Open Source Consulting | Domain Registration