# apt-get install uml-utilities
# cat /etc/ovs-ifup switch='br0' /sbin/ifconfig $1 0.0.0.0 up ovs-vsctl add-port ${switch} $1 # cat /etc/ovs-ifdown switch='br0' /sbin/ifconfig $1 0.0.0.0 down ovs-vsctl del-port ${switch $1}
# ovs-vsctl add-br br0 # ovs-vsctl show 269457f7-8c1e-48bd-b080-4a75d4017857 Bridge "br0" Port "br0" Interface "br0" type: internal ovs_version: "2.3.1"
# ovs-vsctl add-port br0 eth0
# kvm -m 512 -net nic,macaddr=00:11:22:EE:EE:EE -net \ tap,script=/etc/ovs-ifup,downscript=/etc/ovs-ifdown -drive \ file=/path/to/disk-image,boot=on
# ovs-dpctl show system@ovs-system: lookups: hit:3 missed:5 lost:0 flows: 0 masks: hit:5 total:0 hit/pkt:0.62 port 0: ovs-system (internal) port 1: br0 (internal) port 2: tap0 # ovs-ofctl show br0 ovs-ofctl show br0 OFPT_FEATURES_REPLY (xid=0x2): dpid:00007ebb14496e48 n_tables:254, n_buffers:256 capabilities: FLOW_STATS TABLE_STATS PORT_STATS QUEUE_STATS ARP_MATCH_IP actions: OUTPUT SET_VLAN_VID SET_VLAN_PCP STRIP_VLAN SET_DL_SRC SET_DL_DST ... 1(tap0): addr:ba:5a:79:fa:a3:b2 config: 0 state: 0 current: 10MB-FD COPPER speed: 10 Mbps now, 0 Mbps max LOCAL(br0): addr:7e:bb:14:49:6e:48 config: 0 state: 0 speed: 0 Mbps now, 0 Mbps max OFPT_GET_CONFIG_REPLY (xid=0x4): frags=normal miss_send_len=0
Copyrights © - Joinc, All Rights Reserved. Inherited From - Yundream Rebranded By - Joonphil
Contents
KVM과 OpenvSwitch
설정
Recent Posts
Archive Posts
Tags