What are the ways to modify IP through the linux command line
This article mainly explains "what is the way to modify IP through the linux command line". The content in the article is simple and clear, and it is easy to learn and understand. Please follow the editor's train of thought to study and learn "what are the ways to modify IP through the linux command line".
This paper introduces the method of modifying IP through the linux command line. Modifying IP through the linux command line can be achieved in the following two ways.
Method 1:
Ifconfig eth0 192.168.1.18 netmask 255.255.255.0
Description: this method can make the change take effect immediately, and it will return to the original IP after restart.
Method 2:
Vi / etc/sysconfig/network-scripts/ifcfg-eth0
Note: this method takes effect after restart, and it is *.
If you want to change it immediately and * * takes effect, you can only use the above two methods at the same time.
Thank you for your reading, the above is the content of "modifying IP through the linux command line". After the study of this article, I believe you have a deeper understanding of what you have to modify IP through the linux command line, and the specific use needs to be verified in practice. Here is, the editor will push for you more related knowledge points of the article, welcome to follow!