从配置调用到加入组的动作流程
那条配置出发的加入 no disable
我在dce中添加了一个部分的组播加入动作的处理,如下,
Breakpoint 2, ns3::UnixSocketFd::Setsockopt (this=0x7fffdc007ed0, level=0, optname=42, optval=0x7ffff0a2a440, optlen=136) at ../model/unix-socket-fd.cc:523
523 if (optlen < sizeof(struct group_req))
(gdb) bt
#0 ns3::UnixSocketFd::Setsockopt (this=0x7fffdc007ed0, level=0, optname=42, optval=0x7ffff0a2a440, optlen=136) at ../model/unix-socket-fd.cc:523
#1 0x00007ffff7a56cc1 in dce_setsockopt (fd=6, level=0, optname=42, optval=0x7ffff0a2a440, optlen=136) at ../model/dce-fd.cc:522
#2 0x00007ffff1a52623 in setsockopt () at ../model/libc-ns3.h:183
#3 0x00007ffff07a6f18 in setsockopt_ipv4_multicast (sock=6, optname=35, mcast_addr=33554656, ifindex=0) at sockopt.c:237
#4 0x00007ffff072fdd8 in mpls_socket_multicast_if_join (handle=-559038737, socket=0x7ffff06ff198, iff=0x7ffff070cad8, mult=0x7ffff070cb78) at impl_socket.c:399
#5 0x00007ffff07528d0 in ldp_if_startup (g=0x7ffff06fddc8, i=0x7ffff070cad8) at ldp_if.c:227
#6 0x00007ffff074881f in ldp_entity_startup (g=0x7ffff06fddc8, e=0x7ffff06feb58) at ldp_entity.c:160
#7 0x00007ffff074bebf in ldp_global_startup (g=0x7ffff06fddc8) at ldp_global.c:227
#8 0x00007ffff074235a in ldp_cfg_global_set (handle=0x7ffff06fddc8, g=0x7ffff0a2a640, flag=2) at ldp_cfg.c:214
#9 0x00007ffff0732a28 in ldp_startup (ldp=0x7ffff06fe248) at ldp.c:32
#10 0x00007ffff0732a7b in ldp_admin_state_finish (ldp=0x7ffff06fe248) at ldp.c:44
#11 0x00007ffff0733ac4 in no_ldp_disable (self=0x7ffff09d6ce0 <no_ldp_disable_cmd>, vty=0x7ffff06fd718, argc=0, argv=0x7ffff0a2a8f0) at ldp_vty.c:238
#12 0x00007ffff078aedc in cmd_execute_command_real (vline=0x7ffff06fdd38, filter=FILTER_STRICT, vty=0x7ffff06fd718, cmd=0x0) at command.c:2669
#13 0x00007ffff078b0a0 in cmd_execute_command_strict (vline=0x7ffff06fdd38, vty=0x7ffff06fd718, cmd=0x0) at command.c:2761
#14 0x00007ffff078b10c in config_from_file (vty=0x7ffff06fd718, fp=0x7fffdc0077b0, line_num=0x7ffff0a2aa90) at command.c:2781
#15 0x00007ffff0784cc4 in vty_read_file (confp=0x7fffdc0077b0) at vty.c:2256
#16 0x00007ffff0785291 in vty_read_config (config_file=0x662d90 "/usr/local/etc/ldpd.conf",
config_default_dir=0x7ffff09d67c0 <config_default> "/home/z/new/dce/build/etc/ldpd.conf") at vty.c:2438
#17 0x00007ffff0732790 in main (argc=5, argv=0x68ebe0) at ldp_main.c:239
#18 0x00007ffff79fde9f in ns3::DceManager::DoStartProcess (context=0x71d9a0) at ../model/dce-manager.cc:283
#19 0x00007ffff7a88604 in ns3::TaskManager::Trampoline (context=0x66cdf0) at ../model/task-manager.cc:274
#20 0x00007ffff7a845df in ns3::PthreadFiberManager::Run (arg=0x71dc90) at ../model/pthread-fiber-manager.cc:402
#21 0x000000318b2079d1 in start_thread () from /lib64/libpthread.so.0
#22 0x000000318a6e88fd in clone () from /lib64/libc.so.6
(gdb)
关于udp组播处理,ns3写了一部分, udpSocket->MulticastJoinGroup(mreq.imr_ifindex, ad);
但是我没有看懂。ns3没写完FIXME
我把加入组重写了一下。