2014年9月5日 星期五

架設gre 在ubuntu 13.10

安裝Dhcp Server
sudo apt-get install isc-dhcp-server

設定dhcp interface
sudo vim /etc/default/isc-dhcp-server
  • 增加interface name
INTERFACE="gre2"

設定Dhcp range
sudo vim /etc/dhcp/dhcpd.conf

subnet 10.118.251.0 netmask 255.255.255.0 {
    range dynamic-bootp 10.118.251.100 10.118.251.250;
    option routers 10.118.251.163;
}

Restart Dhcp Server
sudo service isc-dhcp-server restart
(Bruce有發現這個指令,啟動後都要放到最後執行)

設定gre
#Ubuntu side and do following command for GRE
sudo ip link add gre2 type gretap remote 172.16.95.33(CM side ip addr) local 172.16.1.118(gre server(local) side ip addr)
sudo ifconfig gre2 10.118.251.163(refrence by /etc/dhcp/dhcpd.conf)
sudo ifconfig gre2 up
sudo ifconfig gre2 down
sudo ip link del gre6
sudo service isc-dhcp-server restart(Bruce發現這個指令,啟動後都要放到最後執行)

gre server side: eth0 ip address is 172.16.1.118


FAQ:
這封郵件來自 Evernote。Evernote 是您專屬的工作空間,免費下載 Evernote

透過Facebook分享

沒有留言: