Set static IP for Linux
2014-08-30 20:38
211 查看
Get your ifconfig name for example (eth0, eth1, eth15). Here we use eth15 as exmple
Add the following content to the file /etc/network/interfaces
$: sudo vi /etc/network/interfaces
address 192.168.1.100
netmask 255.255.255.0
network 192.168.1.0
broadcast 192.168.1.255
gateway 192.168.1.1
Restart network
$: sudo /etc/init.d/networking restart
You can see that your IP is changed to 192.168.1.100.
Also we need to restart networking every time we restart the OS.But I haven't got the method.
Add the following content to the file /etc/network/interfaces
$: sudo vi /etc/network/interfaces
address 192.168.1.100
netmask 255.255.255.0
network 192.168.1.0
broadcast 192.168.1.255
gateway 192.168.1.1
Restart network
$: sudo /etc/init.d/networking restart
You can see that your IP is changed to 192.168.1.100.
Also we need to restart networking every time we restart the OS.But I haven't got the method.
相关文章推荐
- Set static ip for ubuntu
- set specital termimal(https://wiki.archlinux.org/index.php/Color_Bash_Prompt#List_of_colors_for_pro)
- Linux DNS Server 配置 -- for Oracle 11gR2 RAC SCAN IP
- Set up SSH for Git and Mercurial on Mac OSX/Linux
- 【github】2015.09.09 linux 命令行设置代理,连接github(Linux command line set http proxy for connecting github)
- linux C Get/Set IP Address
- Openstack部署总结之:部署过程中“Error: Local ip for ovs agent must be set when tunneling is enabled”的问题
- Static IP Configuration for CentOS 6.5
- Linux Set Up Routing with ip Command
- oracle 10g rac for linux (ASM) 修改modify public IP and vip
- Configuring Linux / Raspberry Pi with a static IP address
- static ip settings for opensuse
- setup static IP addr for ubuntu or centos
- Deploying OpenFire for IM (instant message) service (TCP/IP service) with database MySQL , client Spark on linux部署OpenFire IM 消息中间件服务
- Linux DNS Server 配置 -- for Oracle 11gR2 RAC SCAN IP
- set proxy for svn on linux server
- How to Set Classpath for Java on Windows and Linux
- Openstack部署总结:“部署过程Error: Local ip for ovs agent must be set when tunneling is enabled”问题