Linux - NewbieThis 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
Welcome to LinuxQuestions.org, a friendly and active Linux Community.
You are currently viewing LQ as a guest. By joining our community you will have the ability to post topics, receive our newsletter, use the advanced search, subscribe to threads and access many other special features. Registration is quick, simple and absolutely free. Join our community today!
Note that registered members see fewer ads, and ContentLink is completely disabled once you log in.
If you have any problems with the registration process or your account login, please contact us. If you need to reset your password, click here.
Having a problem logging in? Please visit this page to clear all LQ-related cookies.
Get a virtual cloud desktop with the Linux distro that you want in less than five minutes with Shells! With over 10 pre-installed distros to choose from, the worry-free installation life is here! Whether you are a digital nomad or just looking for flexibility, Shells can put your Linux machine on the device that you want to use.
Exclusive for LQ members, get up to 45% off per month. Click here for more info.
What is your distribution? Usually, the IP address of an interface is stored in a configuration file, that deals with networking. For example, in Slackware, it's /etc/rc.d/rc.inet1.conf In other distributions it's different.
Usually, there are tools to change the IP and other things without editing these files directly. Like the netconfig in Slackware.
I think you need to do some research into IP Addresses, or more specifically how you're getting your IP Address. Are you using DHCP? If so, where ever your DHCP server (or zero-config stuff) is, thats where you want to change it. If you're setting your own IP address, and not using DHCP, /etc/networks/interfaces is the place to look.
What is your distribution? Usually, the IP address of an interface is stored in a configuration file, that deals with networking. For example, in Slackware, it's /etc/rc.d/rc.inet1.conf In other distributions it's different.
Usually, there are tools to change the IP and other things without editing these files directly. Like the netconfig in Slackware.
hi There,
I am using RHEL5, and as you have already told us thta it depends upon distribution, so what could be the location for rhel5?
I think you need to do some research into IP Addresses, or more specifically how you're getting your IP Address. Are you using DHCP? If so, where ever your DHCP server (or zero-config stuff) is, thats where you want to change it. If you're setting your own IP address, and not using DHCP, /etc/networks/interfaces is the place to look.
You can set it with ifconfig, too.
What do you need to change it for?
Hi There,
I am using rhel5 and i already tried ifconfig, but it is not working at all. Ipconfig is not good for linux at all. I tried accessing /etc/network/interfaces as well, but there is no such route either with user or with root...
This syntax assumes you are logged in as root. "N.N.N.N" should be replaced by your desired IP address (for example 192.168.1.128) and "M.M.M.M" should be replaced by the desired subnet mask (for example 255.255.255.0).
This will not be persistent across reboots. If you need to make your changes permanent, look at the file named
LinuxQuestions.org is looking for people interested in writing
Editorials, Articles, Reviews, and more. If you'd like to contribute
content, let us know.