Solved

RHEL, how do I change IP address

Posted on 2013-11-26
6
323 Views
Last Modified: 2013-12-04
I am running on RHEL 6.4

I do not have a GUI

How do I change my IP address

Thanks
0
Comment
Question by:Los Angeles1
6 Comments
 
LVL 12

Expert Comment

by:Chris Staunton
ID: 39678711
modify the /etc/sysconfig/network-scripts/ifcfg-eth?  generally ifcfg-eth0 file.
0
 
LVL 20

Expert Comment

by:Patrick Bogers
ID: 39678712
You have to change the IP address entry in /etc/sysconfig/network-scripts/ifcfg-eth0
save and run: service network restart
0
 
LVL 44

Expert Comment

by:Darr247
ID: 39678735
Another way is with DHCP reservations. What is acting as your DHCP server?
0
Master Your Team's Linux and Cloud Stack!

The average business loses $13.5M per year to ineffective training (per 1,000 employees). Keep ahead of the competition and combine in-person quality with online cost and flexibility by training with Linux Academy.

 
LVL 19

Accepted Solution

by:
xterm earned 500 total points
ID: 39678851
You would also need to change it in /etc/hosts, and /etc/sysconfig/network would need a hostname change if that too is changing (in addition to /etc/sysconfig/network-scripts/ifcfg-eth0)

However, if you're not comfortable using Unix text editors, just run the command "setup", and highlight the entry for "Network Configuration", and tab down to "Run Tool", and then go into "Device Configuration".

Once you "Save & Exit", the changes should take place right away but if not, run "service network restart"
0
 
LVL 25

Expert Comment

by:madunix
ID: 39680063
you can set #ifconfig eth0 192.168.1.1 netmask 255.255.255.0, but it will not permanent, for that you have to change the configuration file
/etc/sysconfig/network-scripts/ifcfg-eth0
You have to make changes in above file, according to the device ifcfg-eth0 , ifcfg-eth1 ...
0
 

Author Closing Comment

by:Los Angeles1
ID: 39695668
'setup' works great
0

Featured Post

Master Your Team's Linux and Cloud Stack

Come see why top tech companies like Mailchimp and Media Temple use Linux Academy to build their employee training programs.

Question has a verified solution.

If you are experiencing a similar issue, please ask a related question

Suggested Solutions

Title # Comments Views Activity
Backup & Restore 3 66
linux SFTP 8 60
Using Linux to replace Windows Server 2008 R2 for network drives 5 105
Trying to install php56 on CentOS 7 get GPG error 5 27
Linux users are sometimes dumbfounded by the severe lack of documentation on a topic. Sometimes, the documentation is copious, but other times, you end up with some obscure "it varies depending on your distribution" over and over when searching for …
It’s 2016. Password authentication should be dead — or at least close to dying. But, unfortunately, it has not traversed Quagga stage yet. Using password authentication is like laundering hotel guest linens with a washboard — it’s Passé.
Learn several ways to interact with files and get file information from the bash shell. ls lists the contents of a directory: Using the -a flag displays hidden files: Using the -l flag formats the output in a long list: The file command gives us mor…
Connecting to an Amazon Linux EC2 Instance from Windows Using PuTTY.

791 members asked questions and received personalized solutions in the past 7 days.

Join the community of 500,000 technology professionals and ask your questions.

Join & Ask a Question