* Li Zhijian (lizhij...@cn.fujitsu.com) wrote: > On 08/05/2015 06:42 PM, Dr. David Alan Gilbert wrote: > >* zhanghailiang (zhang.zhanghaili...@huawei.com) wrote: > >>Implement colo nic device interface configure() > >>add a script to configure nic devices: > >>${QEMU_SCRIPT_DIR}/colo-proxy-script.sh > >> > >>Cc: Stefan Hajnoczi <stefa...@redhat.com> > >>Cc: Jason Wang <jasow...@redhat.com> > >>Signed-off-by: zhanghailiang <zhang.zhanghaili...@huawei.com> > >>Signed-off-by: Li Zhijian <lizhij...@cn.fujitsu.com> > >>--- > >I've not quite got this working right yet; after a failover, the secondary > >hasn't connected the tap to the right bridge; I'm still trying to figure > >that out. > at failover, colo will execute the qemu script(default: /etc/qemu-ifup) to > bring up tap > please check /etc/qemu-ifup > > Further more, qemu downscript *must* be specified and the downscript is > needed to > reset you networking configuration which is configured by qemu-ifup script > > following is a /etc/qemu-ifup and /etc/qemu-ifdown sample(both primary and > secondary) > root@master# cat /etc/qemu-ifup > #!/bin/sh > switch=br0 > if [ -n "$1" ]; then > ip link set $1 up > brctl addif ${switch} $1 > fi > root@master# cat /etc/qemu-ifdown > !/bin/sh > switch=br0 > if [ -n "$1" ]; then > brctl delif ${switch} $1 > fi
Yes, it was my ifup/down scripts that were wrong - the change since your v7 release, was that in the previous version the secondary's ifup script specified the br1 bridge, where as in this new version it specifies the br0 bridge. (The diagram is probably a bit misleading now as well, in that what is labelled as 'br1' is I think the 'colobr0' in the new v8) Dave > > > > >>+ > >>+secondary_uninstall() > >>+{ > >>+ brctl delif $br $phy_if > >>+ brctl delif $br $virt_if > >>+ brctl addif $failover_br $virt_if > >>+ > >>+ /usr/local/sbin/iptables -t mangle -D PREROUTING -m physdev > >>--physdev-in \ > >>+ $virt_if -j SECCOLO --index $index > >I think this is new in this version; don't you still need the SECCOLO > >mangle to fixup the sequence number of packets in existing connections so > >they > >match the numbers that the PMY used? > > the kernel part code will help us to adjust sequence once we initialized > the > seq offest to kernel, so after failover, we don't need the SECCOLO mangle > anymore > > Best regards. > Li Zhijian > > > > >Dave > > > >>+ /usr/local/sbin/ip6tables -t mangle -D PREROUTING -m physdev > >>--physdev-in \ > >>+ $virt_if -j SECCOLO --index $index > >>+} > >>+ > >>+if [ $# -ne 5 ]; then > >>+ script_usage > >>+ exit 1 > >>+fi > >>+ > >>+if [ "x$side" != "xprimary" ] && [ "x$side" != "xsecondary" ]; then > >>+ script_usage > >>+ exit 2 > >>+fi > >>+ > >>+if [ "x$action" != "xinstall" ] && [ "x$action" != "xuninstall" ]; then > >>+ script_usage > >>+ exit 3 > >>+fi > >>+ > >>+${side}_${action} > >>-- > >>1.8.3.1 > >> > >> > >-- > >Dr. David Alan Gilbert / dgilb...@redhat.com / Manchester, UK > >. > > > > -- Dr. David Alan Gilbert / dgilb...@redhat.com / Manchester, UK