Compiling for IPv6
Hi all, I'd like to set up an IPv6 instance of BIRD for our members, but I'm having some troubles with make. When I issue ./configure --enable-ipv6 everything goes fine, but the subsequent make at a certain poing gives these errors: [...] gcc -I../ -I../.. -g -O2 -Wall -Wstrict-prototypes -Wno-parentheses -Wno-pointer-sign -o bitops.o -c bitops.c gcc -I../ -I../.. -g -O2 -Wall -Wstrict-prototypes -Wno-parentheses -Wno-pointer-sign -o checksum.o -c checksum.c gcc -I../ -I../.. -g -O2 -Wall -Wstrict-prototypes -Wno-parentheses -Wno-pointer-sign -o event.o -c event.c event.c: In function ‘ev_run_list’: ../lib/lists.c:132: warning: dereferencing pointer ‘({anonymous})’ does break strict-aliasing rules ../lib/lists.c:115: note: initialized from here gcc -I../ -I../.. -g -O2 -Wall -Wstrict-prototypes -Wno-parentheses -Wno-pointer-sign -o io.o -c io.c io.c: In function ‘sysio_process_rx_cmsgs’: io.c:704: error: dereferencing pointer to incomplete type io.c:705: error: dereferencing pointer to incomplete type io.c: In function ‘sk_read’: io.c:1380: error: invalid application of ‘sizeof’ to incomplete type ‘struct in6_pktinfo’ make[2]: *** [io.o] Error 1 make[2]: Leaving directory `/usr/local/src/bird-1.2.2/obj/lib' make[1]: *** [subdir] Error 2 make[1]: Leaving directory `/usr/local/src/bird-1.2.2/obj' make: *** [all] Error 2 [r...@rs1 bird-1.2.2]# On the same machine BIRD compiles successfully without the v6 option. Am I missing something basic here? The box runs on a Fedora 12. Thanks a lot, Simone. -- This message has been scanned for viruses and dangerous content by MailScanner, and is believed to be clean.
bird6 segfault
Hello, Starting to configure bird6 for iBGP and ran in a repeatable crash running 1.2.2 from ppa on ubuntu 10.04 LTS x64. as soon as i configure in a protocol bgp it's neighbor like: neighbor 2A00:1388:::3 as MYAS; bird6 crashes i unset the ulimit core to produce a core file, but no debugging info is included: # gdb `which bird6` core GNU gdb (GDB) 7.1-ubuntu Copyright (C) 2010 Free Software Foundation, Inc. License GPLv3+: GNU GPL version 3 or later http://gnu.org/licenses/gpl.html This is free software: you are free to change and redistribute it. There is NO WARRANTY, to the extent permitted by law. Type show copying and show warranty for details. This GDB was configured as x86_64-linux-gnu. For bug reporting instructions, please see: http://www.gnu.org/software/gdb/bugs/... Reading symbols from /usr/sbin/bird6...(no debugging symbols found)...done. [New Thread 16308] warning: Can't read pathname for load map: Input/output error. Reading symbols from /lib/librt.so.1...(no debugging symbols found)...done. Loaded symbols for /lib/librt.so.1 Reading symbols from /lib/libc.so.6...(no debugging symbols found)...done. Loaded symbols for /lib/libc.so.6 Reading symbols from /lib/libpthread.so.0...(no debugging symbols found)...done. Loaded symbols for /lib/libpthread.so.0 Reading symbols from /lib64/ld-linux-x86-64.so.2...(no debugging symbols found)...done. Loaded symbols for /lib64/ld-linux-x86-64.so.2 Core was generated by `bird6'. Program terminated with signal 11, Segmentation fault. #0 0x7f4c985bddd5 in ?? () (gdb) bt #0 0x7f4c985bddd5 in ?? () #1 0x7f4c985be22f in ?? () #2 0x7f4c9859ec33 in ?? () #3 0x7f4c98596850 in ?? () #4 0x7f4c985bc447 in ?? () #5 0x7f4c985be458 in ?? () #6 0x7f4c985c1cec in main () (gdb) network on the interface is: 2a00:1388:::2/124 as soon i change the IP a little so it leaves the /124 it doesn't crash anymore. i've a succesfull eBGP setup. Now to try to debug the situation i tried to compile a 1.2.2 ipv6 version from source, but i run stuck at the moment: ran: bird-1.2.2# ./configure --sysconfdir=/ --enable-debug --enable-ipv6 checking for gcc... gcc checking for C compiler default output file name... a.out checking whether the C compiler works... yes checking whether we are cross compiling... no checking for suffix of executables... checking for suffix of object files... o checking whether we are using the GNU C compiler... yes checking whether gcc accepts -g... yes checking for gcc option to accept ISO C89... none needed checking for library containing clock_gettime... -lrt checking build system type... x86_64-unknown-linux-gnu checking host system type... x86_64-unknown-linux-gnu checking for gcc... (cached) gcc checking whether we are using the GNU C compiler... (cached) yes checking whether gcc accepts -g... (cached) yes checking for gcc option to accept ISO C89... (cached) none needed checking what CFLAGS should we use... -g -O2 -Wall -Wstrict-prototypes -Wno-parentheses -Wno-pointer-sign checking how to run the C preprocessor... gcc -E checking for a BSD-compatible install... /usr/bin/install -c checking for ranlib... ranlib checking for flex... flex checking for bison... bison checking for gm4... no checking for m4... m4 checking Linux kernel version... VERSION: UTS_RELEASE checking which OS configuration should we use... ./sysdep/cf/linux-v6.h checking system-dependent directories... sysdep/linux/netlink sysdep/linux sysdep/unix lib checking protocols... ok checking for linux/rtnetlink.h... yes checking for grep that handles long lines and -e... /bin/grep checking for egrep... /bin/grep -E checking for ANSI C header files... yes checking for sys/types.h... yes checking for sys/stat.h... yes checking for stdlib.h... yes checking for string.h... yes checking for memory.h... yes checking for strings.h... yes checking for inttypes.h... yes checking for stdint.h... yes checking for unistd.h... yes checking syslog.h usability... yes checking syslog.h presence... yes checking for syslog.h... yes checking alloca.h usability... yes checking alloca.h presence... yes checking for alloca.h... yes checking whether 'struct sockaddr' has sa_len... no checking whether byte ordering is bigendian... no checking for char... yes checking size of char... 1 checking for short int... yes checking size of short int... 2 checking for int... yes checking size of int... 4 checking for long int... yes checking size of long int... 8 checking for 8-bit type... char checking for 16-bit type... short int checking for 32-bit type... int checking usual alignment of structures... 16 checking characteristics of time_t... 64-bit signed checking for struct ip_mreqn... yes checking for dmalloc_debug in -ldmalloc... no checking for malloc in -lefence... no checking for add_history in -lhistory... yes checking for tgetent in -lncurses... yes checking for rl_callback_read_char in -lreadline... yes checking for rl_crlf in
Re: bird6 segfault
Hello, an update. added listen bgp v6only; in the global section of my bird6.conf seems to solve it. a mistery still why it kept running with exchange connection then, that put me on the wrong foot. i'd always saw a bird6: sk_open: bind: Address already in use which i ignored for later research as my IX connection was actually working. so that seems to be sovled (for me), but question about compile stays open. Regards, Arjan Filius On Fri, 28 May 2010, Arjan Filius wrote: Hello, Starting to configure bird6 for iBGP and ran in a repeatable crash running 1.2.2 from ppa on ubuntu 10.04 LTS x64. as soon as i configure in a protocol bgp it's neighbor like: neighbor 2A00:1388:::3 as MYAS; bird6 crashes i unset the ulimit core to produce a core file, but no debugging info is included: # gdb `which bird6` core GNU gdb (GDB) 7.1-ubuntu Copyright (C) 2010 Free Software Foundation, Inc. License GPLv3+: GNU GPL version 3 or later http://gnu.org/licenses/gpl.html This is free software: you are free to change and redistribute it. There is NO WARRANTY, to the extent permitted by law. Type show copying and show warranty for details. This GDB was configured as x86_64-linux-gnu. For bug reporting instructions, please see: http://www.gnu.org/software/gdb/bugs/... Reading symbols from /usr/sbin/bird6...(no debugging symbols found)...done. [New Thread 16308] warning: Can't read pathname for load map: Input/output error. Reading symbols from /lib/librt.so.1...(no debugging symbols found)...done. Loaded symbols for /lib/librt.so.1 Reading symbols from /lib/libc.so.6...(no debugging symbols found)...done. Loaded symbols for /lib/libc.so.6 Reading symbols from /lib/libpthread.so.0...(no debugging symbols found)...done. Loaded symbols for /lib/libpthread.so.0 Reading symbols from /lib64/ld-linux-x86-64.so.2...(no debugging symbols found)...done. Loaded symbols for /lib64/ld-linux-x86-64.so.2 Core was generated by `bird6'. Program terminated with signal 11, Segmentation fault. #0 0x7f4c985bddd5 in ?? () (gdb) bt #0 0x7f4c985bddd5 in ?? () #1 0x7f4c985be22f in ?? () #2 0x7f4c9859ec33 in ?? () #3 0x7f4c98596850 in ?? () #4 0x7f4c985bc447 in ?? () #5 0x7f4c985be458 in ?? () #6 0x7f4c985c1cec in main () (gdb) network on the interface is: 2a00:1388:::2/124 as soon i change the IP a little so it leaves the /124 it doesn't crash anymore. i've a succesfull eBGP setup. Now to try to debug the situation i tried to compile a 1.2.2 ipv6 version from source, but i run stuck at the moment: ran: bird-1.2.2# ./configure --sysconfdir=/ --enable-debug --enable-ipv6 checking for gcc... gcc checking for C compiler default output file name... a.out checking whether the C compiler works... yes checking whether we are cross compiling... no checking for suffix of executables... checking for suffix of object files... o checking whether we are using the GNU C compiler... yes checking whether gcc accepts -g... yes checking for gcc option to accept ISO C89... none needed checking for library containing clock_gettime... -lrt checking build system type... x86_64-unknown-linux-gnu checking host system type... x86_64-unknown-linux-gnu checking for gcc... (cached) gcc checking whether we are using the GNU C compiler... (cached) yes checking whether gcc accepts -g... (cached) yes checking for gcc option to accept ISO C89... (cached) none needed checking what CFLAGS should we use... -g -O2 -Wall -Wstrict-prototypes -Wno-parentheses -Wno-pointer-sign checking how to run the C preprocessor... gcc -E checking for a BSD-compatible install... /usr/bin/install -c checking for ranlib... ranlib checking for flex... flex checking for bison... bison checking for gm4... no checking for m4... m4 checking Linux kernel version... VERSION: UTS_RELEASE checking which OS configuration should we use... ./sysdep/cf/linux-v6.h checking system-dependent directories... sysdep/linux/netlink sysdep/linux sysdep/unix lib checking protocols... ok checking for linux/rtnetlink.h... yes checking for grep that handles long lines and -e... /bin/grep checking for egrep... /bin/grep -E checking for ANSI C header files... yes checking for sys/types.h... yes checking for sys/stat.h... yes checking for stdlib.h... yes checking for string.h... yes checking for memory.h... yes checking for strings.h... yes checking for inttypes.h... yes checking for stdint.h... yes checking for unistd.h... yes checking syslog.h usability... yes checking syslog.h presence... yes checking for syslog.h... yes checking alloca.h usability... yes checking alloca.h presence... yes checking for alloca.h... yes checking whether 'struct sockaddr' has sa_len... no checking whether byte ordering is bigendian... no checking for char... yes checking size of char... 1 checking for short int... yes checking size of short int... 2 checking for int... yes checking size of int... 4 checking for long int... yes checking size of long int... 8
Re: Compiling for IPv6
Hi Simone, Am 28.05.2010 11:51, schrieb Simone Morandini: I'd like to set up an IPv6 instance of BIRD for our members, but I'm having some troubles with make. When I issue ./configure --enable-ipv6 everything goes fine, but the subsequent make at a certain poing gives these errors: Try without ospf: ./configure --enable-ipv6 --with-protocols=bgp,pipe,static Rgds, Stefan
Re: Compiling for IPv6
On 28.5.2010 11:51, Simone Morandini wrote: Hi all, I'd like to set up an IPv6 instance of BIRD for our members, but I'm having some troubles with make. When I issue ./configure --enable-ipv6 everything goes fine, but the subsequent make at a certain poing gives these errors: [...] gcc -I../ -I../.. -g -O2 -Wall -Wstrict-prototypes -Wno-parentheses -Wno-pointer-sign -o bitops.o -c bitops.c gcc -I../ -I../.. -g -O2 -Wall -Wstrict-prototypes -Wno-parentheses -Wno-pointer-sign -o checksum.o -c checksum.c gcc -I../ -I../.. -g -O2 -Wall -Wstrict-prototypes -Wno-parentheses -Wno-pointer-sign -o event.o -c event.c event.c: In function ‘ev_run_list’: ../lib/lists.c:132: warning: dereferencing pointer ‘({anonymous})’ does break strict-aliasing rules ../lib/lists.c:115: note: initialized from here gcc -I../ -I../.. -g -O2 -Wall -Wstrict-prototypes -Wno-parentheses -Wno-pointer-sign -o io.o -c io.c io.c: In function ‘sysio_process_rx_cmsgs’: io.c:704: error: dereferencing pointer to incomplete type io.c:705: error: dereferencing pointer to incomplete type io.c: In function ‘sk_read’: io.c:1380: error: invalid application of ‘sizeof’ to incomplete type ‘struct in6_pktinfo’ make[2]: *** [io.o] Error 1 make[2]: Leaving directory `/usr/local/src/bird-1.2.2/obj/lib' make[1]: *** [subdir] Error 2 make[1]: Leaving directory `/usr/local/src/bird-1.2.2/obj' make: *** [all] Error 2 [r...@rs1 bird-1.2.2]# On the same machine BIRD compiles successfully without the v6 option. Am I missing something basic here? The box runs on a Fedora 12. Hi Simone, this is a known bug. It is fixed differently in current git repository, but you can for example use my hot fix from Fedora RPMs. (Attached). Ondrej Thanks a lot, Simone. diff -uNr bird-1.2.2.orig/sysdep/linux/sysio.h bird-1.2.2/sysdep/linux/sysio.h --- bird-1.2.2.orig/sysdep/linux/sysio.h2010-04-09 21:40:57.0 +0200 +++ bird-1.2.2/sysdep/linux/sysio.h 2010-04-09 23:09:11.085478940 +0200 @@ -10,6 +10,12 @@ #ifdef IPV6 +struct in6_pktinfo +{ + struct in6_addr ipi6_addr; /* src/dst IPv6 address */ + unsigned int ipi6_ifindex; /* send/recv interface index */ +}; + #ifndef IPV6_UNICAST_HOPS /* Needed on glibc 2.0 systems */ #include linux/in6.h
Re: bird6 segfault
On Fri, May 28, 2010 at 02:26:51PM +0200, Arjan Filius wrote: Hello, Hello, thanks for the bugreport. an update. added listen bgp v6only; in the global section of my bird6.conf seems to solve it. a mistery still why it kept running with exchange connection then, that put me on the wrong foot. network on the interface is: 2a00:1388:::2/124 as soon i change the IP a little so it leaves the /124 it doesn't crash anymore. Which address you used when it didn't crash? i'd always saw a bird6: sk_open: bind: Address already in use which i ignored for later research as my IX connection was actually working. It worked because although setting listening (passive) socket failed, it also tried outgoing (active) connection. It crashed after these messages, or these messages appeared only when it didn't crash? so that seems to be sovled (for me), but question about compile stays open. http://marc.info/?l=bird-usersm=127505567110354w=2 It would be useful if you could compile it and make a backtrace from the core dump. -- Elen sila lumenn' omentielvo Ondrej 'SanTiago' Zajicek (email: santi...@crfreenet.org) OpenPGP encrypted e-mails preferred (KeyID 0x11DEADC3, wwwkeys.pgp.net) To err is human -- to blame it on a computer is even more so. signature.asc Description: Digital signature