diff options
-rwxr-xr-x | debian/rules | 3 | ||||
-rw-r--r-- | debian/vyatta-quagga.preinst | 6 | ||||
-rw-r--r-- | lib/smux.c | 18 | ||||
-rw-r--r-- | lib/smux.h | 2 |
4 files changed, 20 insertions, 9 deletions
diff --git a/debian/rules b/debian/rules index ba47d987..e89dc246 100755 --- a/debian/rules +++ b/debian/rules @@ -18,6 +18,7 @@ PACKAGE=vyatta-quagga PKGDIR=$(CURDIR)/debian/$(PACKAGE) BUILD_STAMP=debian/build-stamp CFLAGS = -Wall -g +WANT_SNMP=1 ifneq (,$(findstring noopt,$(DEB_BUILD_OPTIONS))) CFLAGS += -O0 @@ -107,7 +108,7 @@ install: build install -D --mode=0644 debian/lintian $(PKGDIR)/usr/share/lintian/overrides/$(PACKAGE) ifeq ($(WANT_SNMP), 1) - install -D --mode=0644 zebra/GNOME-PRODUCT-ZEBRA-MIB $(PKGDIR)/usr/share/snmp/mibs + install -D --mode=0644 zebra/GNOME-PRODUCT-ZEBRA-MIB $(PKGDIR)/usr/share/snmp/mibs/GNOME-PRODUCT-ZEBRA-MIB.txt endif diff --git a/debian/vyatta-quagga.preinst b/debian/vyatta-quagga.preinst index 4222ef3b..af61947a 100644 --- a/debian/vyatta-quagga.preinst +++ b/debian/vyatta-quagga.preinst @@ -71,6 +71,12 @@ if [ "$1" = "install" ]; then EOF fi done + + + echo "smux peer .1.3.6.1.4.1.3317.1.2.5" >> $ETC_DIR/ospfd.conf + echo "smux peer .1.3.6.1.4.1.3317.1.2.2" >> $ETC_DIR/bgpd.conf + echo "smux peer .1.3.6.1.4.1.3317.1.2.3" >> $ETC_DIR/ripd.conf + if [ ! -e $ETC_DIR/vtysh.conf ] ; then touch $ETC_DIR/vtysh.conf chown quagga:quaggavty $ETC_DIR/vtysh.conf @@ -1179,7 +1179,10 @@ smux_connect (struct thread *t) int ret; if (debug_smux) - zlog_debug ("SMUX connect try %d", fail + 1); + { + fail = fail + 1; + zlog_debug ("SMUX connect try %d", fail); + } /* Clear thread poner of myself. */ smux_connect_thread = NULL; @@ -1188,8 +1191,9 @@ smux_connect (struct thread *t) smux_sock = smux_socket (); if (smux_sock < 0) { - if (++fail < SMUX_MAX_FAILURE) - smux_event (SMUX_CONNECT, 0); + zlog_warn ("SMUX socket/connection creation error"); + // if (++fail < SMUX_MAX_FAILURE) + smux_event (SMUX_CONNECT, 0); return 0; } @@ -1200,8 +1204,8 @@ smux_connect (struct thread *t) zlog_warn ("SMUX open message send failed: %s", safe_strerror (errno)); close (smux_sock); smux_sock = -1; - if (++fail < SMUX_MAX_FAILURE) - smux_event (SMUX_CONNECT, 0); + // if (++fail < SMUX_MAX_FAILURE) + smux_event (SMUX_CONNECT, 0); return -1; } @@ -1212,8 +1216,8 @@ smux_connect (struct thread *t) zlog_warn ("SMUX register message send failed: %s", safe_strerror (errno)); close (smux_sock); smux_sock = -1; - if (++fail < SMUX_MAX_FAILURE) - smux_event (SMUX_CONNECT, 0); + // if (++fail < SMUX_MAX_FAILURE) + smux_event (SMUX_CONNECT, 0); return -1; } @@ -39,7 +39,7 @@ #define SMUX_SET (ASN_CONTEXT | ASN_CONSTRUCTOR | 3) #define SMUX_TRAP (ASN_CONTEXT | ASN_CONSTRUCTOR | 4) -#define SMUX_MAX_FAILURE 3 +// #define SMUX_MAX_FAILURE 3 /* Structures here are mostly compatible with UCD SNMP 4.1.1 */ #define MATCH_FAILED (-1) |