Package: vrrpd Version: 1.0-1 Severity: normal Tags: patch When vrrp becomes active it changes its mac address, causing all routes with this interface to dissapear. After that it restores only routes within the main routing table.
In configurations with source routing it's necessary to use other tables to route packages, e.g.: ip rule add from 10.1.1.0/24 table 201 ip route add default via 72.14.207.1 table 201 This route dissapear after vrrp comes up. Attached is a patch that will not correct this. -- System Information: Debian Release: 4.0 APT prefers stable APT policy: (500, 'stable') Architecture: i386 (i686) Shell: /bin/sh linked to /bin/bash Kernel: Linux 2.6.18-5-xen-686 Locale: LANG=es_ES.UTF-8, LC_CTYPE=es_ES.UTF-8 (charmap=UTF-8) Versions of packages vrrpd depends on: ii libc6 2.3.6.ds1-13etch4 GNU C Library: Shared libraries vrrpd recommends no packages. -- no debconf information
diff -Nurb vrrpd-1.0.orig/iproute.c vrrpd-1.0/iproute.c --- vrrpd-1.0.orig/iproute.c 2008-02-12 10:07:52.000000000 +0000 +++ vrrpd-1.0/iproute.c 2008-02-12 10:11:51.000000000 +0000 @@ -92,8 +92,8 @@ rtarg = (struct rt_entry *)arg; /* Just lookup the Main routing table */ - if (r->rtm_table != RT_TABLE_MAIN) - return 0; +// if (r->rtm_table != RT_TABLE_MAIN) +// return 0; /* init len value */ len -= NLMSG_LENGTH(sizeof(*r)); @@ -141,6 +141,7 @@ if (tb[RTA_IIF]) entry->iif = *(int *) RTA_DATA(tb[RTA_IIF]); if (tb[RTA_PRIORITY]) entry->prio = *(int *) RTA_DATA(tb[RTA_PRIORITY]); if (tb[RTA_METRICS]) entry->metrics = *(int *) RTA_DATA(tb[RTA_METRICS]); + entry->table = r->rtm_table; /* save this entry */ rtarg = rt_append(rtarg, entry); @@ -192,6 +193,7 @@ req.n.nlmsg_len = NLMSG_LENGTH(sizeof(struct rtmsg)); req.n.nlmsg_flags = NLM_F_REQUEST | NLM_F_CREATE; req.n.nlmsg_type = RTM_NEWROUTE; + req.r.rtm_table = r->table; memcpy(&req.r, r->rtm, sizeof(struct rtmsg)); diff -Nurb vrrpd-1.0.orig/iproute.h vrrpd-1.0/iproute.h --- vrrpd-1.0.orig/iproute.h 2008-02-12 10:07:52.000000000 +0000 +++ vrrpd-1.0/iproute.h 2008-02-12 10:09:22.000000000 +0000 @@ -51,6 +51,7 @@ int oif; int prio; int metrics; + unsigned char table; struct rt_entry *next; };