ubuntu 13.04
修改機器名
開啟檔案 /etc/hostname 寫入機器名
然後執行命令
$ sudo hostname -f /etc/hostname
檢視當前網絡卡資訊
ifconfig -a
在虛擬機器中,除了修改虛擬機器的網絡卡的mac位址外,還要在系統裡面去修改
/etc/udev/rules.d/70-persistent-net.rules
刪除原來的 eth0 的配置,然後將 eth1 修改為 eth0
設定ip位址或者dhcp
/etc/network/inte***ces
auto eth0
iface eth0 inet static
address 192.168.1.1
netmask 255.255.255.0
gateway 192.168.1.253
dns-nameservers 8.8.8.8 114.114.114.144
auto eth0
iface eth0 inet dhcp
修改機器名ok,mac位址未通過
Linux 機器名修改
這幾天在弄 dubbo 服務,用到了zookeeper,因為使用的是xenserver,然後使用的模板裝的虛擬機器和系統,結果就出現了好幾臺伺服器使用相同的機器名的情況,當初為了方便就沒有去修改,結果使用 zookeeper 集群的時候,問題乙個乙個的出現了,總會出現集群鏈結問題。找了很久最後確定應...
ubuntu修改mac位址
首先必須關閉網絡卡裝置,否則會報告系統忙,無法更改。ifconfig eth0 down 修改 mac 位址,這一步較 windows 中的修改要簡單。ifconfig eth0 hw ether 重新啟用網絡卡 ifconfig eht0 up 如果計算機每次啟動都要修改mac位址 修改你的源,並...
ubuntu下修改mac位址
臨時 ifconfig eth0 down ifconfig eth0 hw ether x ifconfig eth0 up 永久 1 編輯 etc init.d rc.local 檔案 sudo gedit etc init.d rc.local 2 在此配置檔案的最後面加上如 ubuntu 修...