2013-07-09 29 views
3

我設立一個單一節點上的OpenStack的安裝,但配置它,所以我可以爲各種服務(新星,快捷爲主)以後添加更多的節點。爲此,我使用2以太網連接:eth0用於與互聯網和eth1用於內部通信進行通信(未目前因爲單節點安裝使用)(以下this guide)。如何配置的vSwitch與OpenStack的

從我的路由器橋接進入OpenStack的虛擬網絡,我使用openVSwitch,並且已經配置了2座橋樑如下

#br-int will be used for VM integration 
ovs-vsctl add-br br-int 

#br-ex is used to make to access the internet 
ovs-vsctl add-br br-ex 

然後配置我的/ etc /網絡/接口:

# VM internet Access 
auto eth0 
iface eth0 inet manual 
up ifconfig eth0 0.0.0.0 up 
up ip link set eth0 promisc on 
down ip link set eth0 promisc off 
down ifconfig eth0 down 

# add a static ip to the host machine to facilitate interet access 
auto br-ex 
iface br-ex inet static 
address 192.168.100.51 
netmask 255.255.255.0 
gateway 192.168.100.1 
dns-nameservers 8.8.8.8 

我重新啓動我的機器上並運行

ovs-vsctl add-port br-ex eth0 

的連接橋樑,以ETH 0。現在

,我可以在我的本地子網中的計算機進行通信,但我無法通過我的路由器進行通信。我認爲這是一個路由器問題,但我不確定。另外,如果是路由器問題,可以調用允許此設置工作的設置是什麼?

編輯: 我發現了一個引導here它說讓過去的路由器的問題可能是由於路由 - 這裏是我的路由表

Kernel IP routing table 
Destination  Gateway   Genmask   Flags Metric Ref Use Iface 
default   192.168.1.200 0.0.0.0   UG 0  0  0 br-ex 
10.10.100.0  *    255.255.255.0 U  0  0  0 eth1 
192.168.1.0  *    255.255.255.0 U  0  0  0 br-ex 

回答

2

這個問題確實是通過改變路由表來解決。問題是,我的網關竟是192.168.1.1。我用ip route del default刪除默認的記錄,並與ip route add default 192.168.1.1 dev br-ex

將在缺省路由網關我固定的問題