Ubuntu VS CentOS Networking Commands



To Set the network IP in one line.

$ sudo ifconfig eth0 192.168.1.20 netmask 255.255.255.0
$ sudo route add -net 192.168.1.0 netmask 255.255.255.0 gw 192.168.1.1



Ubuntu Restart networking service:
 GUI Network Manager:  NetworkManager
/etc/network/interfaces
---
auto eth0
iface eth0 inet static
address 192.168.1.4
netmask 255.255.255.0
broadcast 192.168.1.255
gateway 192.168.1.1

---

/etc/init.d/networking restart


Centos networking Service
IF Setting: /etc/sysconfig/networking/ifcfg-eth0
service network restart


留言

這個網誌中的熱門文章

tw quote

三重幫 - 2013-09-11

FPDF Big5 Font