Home>Article>Operation and Maintenance> How to change ip address in linux

How to change ip address in linux

青灯夜游
青灯夜游 Original
2022-03-09 17:21:44 98833browse

Modification method: 1. Right-click the mouse on the desktop and select "Open Terminal"; 2. In the terminal window, execute the "vi /etc/sysconfig/network-scripts/ifcfg-eth0" command; 3. In edit mode, just modify the values of IPADDR, NETMASK and other items.

How to change ip address in linux

#The operating environment of this tutorial: Red Hat Enterprise Linux 6.1 system, Dell G3 computer.

linux modify ip address

1. Log in to the linux operating system and enter the interface

How to change ip address in linux

2. Right-click on the desktop to open the terminal.

How to change ip address in linux

3. Execute theifconfig -acommand in the terminal to view the IP address

How to change ip address in linux

as shown below Saw the ip address.

How to change ip address in linux

4. Enter in the terminal:vi /etc/sysconfig/network-scripts/ifcfg-eth0

How to change ip address in linux

5. After pressing Enter, start editing and fill in the IP address, subnet mask, gateway, DNS, etc. Among them, the "information in the red box" is a must. That’s it

How to change ip address in linux

#Related recommendations: "Linux Video Tutorial"

The above is the detailed content of How to change ip address in linux. For more information, please follow other related articles on the PHP Chinese website!

Statement:
The content of this article is voluntarily contributed by netizens, and the copyright belongs to the original author. This site does not assume corresponding legal responsibility. If you find any content suspected of plagiarism or infringement, please contact admin@php.cn