kohler / click

The Click modular router: fast modular packet processing and analysis
Other
740 stars 321 forks source link

Click linux-module not building #405

Closed alinaSarwar closed 6 years ago

alinaSarwar commented 6 years ago

Sir,

I have been working with click routers on kernel level from the past week. They were executing absolutely fine on linux kernel 3.13. However, yesterday I tried to install it on another machine with the same kernel but got the following error after sudo make:

/usr/bin/ld: libclick.a(error.o): bad reloc symbol index (0x10004d >= 0x11a) for offset 0x10000004003b4c in section .debug_info' libclick.a: could not read symbols: Bad value collect2: ld returned 1 exit status make[1]: [click] Error 1 make[1]: Leaving directory/users/alina13/project/click/userlevel' make: [userlevel] Error 2

Configuration carries out without any error but I am still unable to make the click modular router. Could anyone please point towards the mistake I might be making.

alinaSarwar commented 6 years ago

I configured the click modular router with userlevel disabled. I was able to make the modular router and install a NAT on the machine. However, when the packets pass through the machine it causes the machine to crash. The system log has the following errors:

**nodec login: [ 189.785539] click: starting router thread pid 2207 (ffff880319ef9400)^M [ 202.439800] BUG: unable to handle kernel NULL pointer dereference at 0000000000000008^M [ 202.447636] IP: [] bnx2_start_xmit+0x249/0x770 [bnx2]^M [ 202.454256] PGD 0 ^M [ 202.456271] Oops: 0002 [#1] SMP ^M [ 202.459510] Modules linked in: click(OX) proclikefs(OX) nfsv3 ipod(OX) ib_iser rdma_cm ib_cm iw_cm ib_sa ib_mad ib_core ib_addr iscsi_tcp libiscsi_tcp libiscsi scsi_transport_iscsi nfsd nfs_acl auth_rpcgss nfs fscache 8021q lockd mrp garp stp sunrpc llc psmouse gpio_ich ipmi_si dcdbas serio_raw i7core_edac edac_core lp joydev acpi_power_meter lpc_ich mac_hid parport hid_generic usbhid hid mptsas mptscsih mptbase scsi_transport_sas bnx2^M [ 202.498523] CPU: 0 PID: 2207 Comm: kclick Tainted: G IOX 3.13.0-117-generic #164~precise1-Ubuntu^M [ 202.508073] Hardware name: Dell Inc. PowerEdge R710/00W9X3, BIOS 2.1.15 09/02/2010^M [ 202.515629] task: ffff88031c423000 ti: ffff88031c2b4000 task.ti: ffff88031c2b4000^M [ 202.523097] RIP: 0010:[] [] bnx2_start_xmit+0x249/0x770 [bnx2]^M [ 202.532140] RSP: 0018:ffff88031c2b5ce8 EFLAGS: 00010246^M [ 202.537440] RAX: 0000000000000000 RBX: ffff880319095c00 RCX: 0000000000000000^M [ 202.544561] RDX: 0000000036a73a46 RSI: 0000000000000000 RDI: ffff88031da21098^M [ 202.551683] RBP: ffff88031c2b5d48 R08: 0000000000000000 R09: 0000000000000000^M [ 202.558804] R10: ffff880036849018 R11: 0000000000154858 R12: 0000000000000000^M [ 202.565926] R13: 000000000000003c R14: ffff8803193124c0 R15: ffff880319310000^M [ 202.573049] FS: 0000000000000000(0000) GS:ffff880323200000(0000) knlGS:0000000000000000^M [ 202.581125] CS: 0010 DS: 0000 ES: 0000 CR0: 000000008005003b^M [ 202.586859] CR2: 0000000000000008 CR3: 0000000001c0d000 CR4: 00000000000007f0^M [ 202.593981] Stack:^M [ 202.595986] 0000000036a73a46 ffff880318d81a00 0000000000000100 0000000000000000^M [ 202.603403] ffff880319b6be00 ffff880300000000 ffff88031c2b5d38 ffff880036a72000^M [ 202.610819] ffff880319310000 ffff880319095c00 0000000000000006 ffff880318d81000^M [ 202.618238] Call Trace:^M [ 202.620825] [] _ZN8ToDevice12queue_packetEP6PacketP12netdev_queue+0x10e/0x230 [click]^M [ 202.630405] [] _ZN8ToDevice8run_taskEP4Task+0xad/0x380 [click]^M [ 202.637982] [] _ZN12RouterThread6driverEv+0x2c4/0x490 [click]^M [ 202.645488] [] _ZL11click_schedPv+0x107/0x200 [click]^M [ 202.652298] [] ? _Z19click_cleanup_schedv+0x180/0x180 [click]^M [ 202.659684] [] kthread+0xc9/0xe0^M [ 202.664553] [] ? flush_kthread_worker+0xb0/0xb0^M [ 202.670724] [] ret_from_fork+0x58/0x90^M [ 202.676113] [] ? flush_kthread_worker+0xb0/0xb0^M [ 202.682281] Code: 0f 85 ec 01 00 00 4d 8b 86 60 03 00 00 41 0f b6 c4 48 89 d6 48 8d 0c 40 48 c1 e0 04 48 c1 ee 20 c7 45 b8 00 00 00 00 49 8d 0c c8 <48> 89 51 08 48 89 19 49 03 86 58 03 00 00 89 30 8b 75 c8 89 50 ^M [ 202.701735] RIP [] bnx2_start_xmit+0x249/0x770 [bnx2]^M [ 202.708438] RSP ^M [ 202.711917] CR2: 0000000000000008^M [ 202.715225] ---[ end trace 8de0a075e6b25cbb ]---^M [ 202.723499] Kernel panic - not syncing: Fatal exception in interrupt^M [ 202.730047] Kernel Offset: 0x0 from 0xffffffff81000000 (relocation range: 0xffffffff80000000-0xffffffff9fffffff)^M [ 202.743865] ------------[ cut here ]------------^M [ 202.748476] WARNING: CPU: 0 PID: 2207 at /build/linux-lts-trusty-OgFyRr/linux-lts-trusty-3.13.0/arch/x86/kernel/smp.c:124 native_smp_send_reschedule+0x5e/0x60()^M [ 202.762796] Modules linked in: click(OX) proclikefs(OX) nfsv3 ipod(OX) ib_iser rdma_cm ib_cm iw_cm ib_sa ib_mad ib_core ib_addr iscsi_tcp libiscsi_tcp libiscsi scsi_transport_iscsi nfsd nfs_acl auth_rpcgss nfs fscache 8021q lockd mrp garp stp sunrpc llc psmouse gpio_ich ipmi_si dcdbas serio_raw i7core_edac edac_core lp joydev acpi_power_meter lpc_ich mac_hid parport hid_generic usbhid hid mptsas mptscsih mptbase scsi_transport_sas bnx2^M [ 202.801785] CPU: 0 PID: 2207 Comm: kclick Tainted: G D IOX 3.13.0-117-generic #164~precise1-Ubuntu^M [ 202.811334] Hardware name: Dell Inc. PowerEdge R710/00W9X3, BIOS 2.1.15 09/02/2010^M [ 202.818889] 0000000000000000 ffff880323203d18 ffffffff81765bf5 0000000000000000^M [ 202.826309] 000000000000007c ffff880323203d58 ffffffff8106e2fc ffff880323213200^M [ 202.833726] 0000000000000001 0000000000000000 ffff880323233180 ffff880323213180^M [ 202.841142] Call Trace:^M [ 202.843579] [] dump_stack+0x64/0x82^M [ 202.849338] [] warn_slowpath_common+0x8c/0xc0^M [ 202.855335] [] warn_slowpath_null+0x1a/0x20^M [ 202.861157] [] native_smp_send_reschedule+0x5e/0x60^M [ 202.867675] [] trigger_load_balance+0x17e/0x1f0^M [ 202.873846] [] scheduler_tick+0xaf/0xf0^M [ 202.879323] [] update_process_times+0x61/0x80^M [ 202.885322] [] tick_sched_handle.isra.12+0x33/0x70^M [ 202.891752] [] tick_sched_timer+0x4c/0x80^M [ 202.897402] [] __run_hrtimer+0x77/0x270^M [ 202.902879] [] ? ktime_get_update_offsets+0x52/0xf0^M [ 202.909396] [] ? tick_nohz_handler+0xa0/0xa0^M [ 202.915305] [] hrtimer_interrupt+0x107/0x260^M [ 202.921217] [] local_apic_timer_interrupt+0x3b/0x60^M [ 202.927735] [] smp_apic_timer_interrupt+0x43/0x60^M [ 202.934078] [] apic_timer_interrupt+0x6d/0x80^M [ 202.940072] [] ? panic+0x19e/0x1e1^M [ 202.945742] [] ? panic+0x100/0x1e1^M [ 202.950784] [] oops_end+0x14a/0x160^M [ 202.955914] [] no_context+0x1be/0x1cd^M [ 202.961218] [] bad_area_nosemaphore+0x1d3/0x1f2^M [ 202.967560] [] bad_area_nosemaphore+0x13/0x15^M [ 202.973556] [] do_page_fault+0x3c2/0x580^M [ 202.979393] [] ? click_lalloc+0x3c/0x70 [click]^M [ 202.985664] [] ? click_lfree+0x1c/0x40 [click]^M [ 202.991895] [] ? _ZN13HashContainerI15IPRewriterEntry3HCaIS0_EE6rehashEj+0xfb/0x220 [click]^M [ 203.001992] [] ? _ZN14IPRewriterBase10store_flowEP14IPRewrite_H3bca1ae860+0x3e1/0x520 [click]^M [ 203.012267] [] ? _ZN13FullNoteQueue4pushEiP6Packet+0x2a7/0x2b0 [click]^M [ 203.020432] [] do_page_fault+0x1a/0x70^M [ 203.025822] [] page_fault+0x28/0x30^M [ 203.030954] [] ? bnx2_start_xmit+0x249/0x770 [bnx2]^M [ 203.037473] [] ? bnx2_start_xmit+0x218/0x770 [bnx2]^M [ 203.044104] [] _ZN8ToDevice12queue_packetEP6PacketP12netdev_queue+0x10e/0x230 [click]^M [ 203.053683] [] _ZN8ToDevice8run_taskEP4Task+0xad/0x380 [click]^M [ 203.061258] [] _ZN12RouterThread6driverEv+0x2c4/0x490 [click]^M [ 203.068762] [] _ZL11click_schedPv+0x107/0x200 [click]^M [ 203.075573] [] ? _Z19click_cleanup_schedv+0x180/0x180 [click]^M [ 203.082957] [] kthread+0xc9/0xe0^M [ 203.087826] [] ? flush_kthread_worker+0xb0/0xb0^M [ 203.093996] [] ret_from_fork+0x58/0x90^M [ 203.099384] [] ? flush_kthread_worker+0xb0/0xb0^M [ 203.105552] ---[ end trace 8de0a075e6b25cbc ]---^M [ 203.110167] ------------[ cut here ]------------^M [ 203.114778] WARNING: CPU: 0 PID: 2207 at /build/linux-lts-trusty-OgFyRr/linux-lts-trusty-3.13.0/kernel/time/tick-broadcast.c:604 tick_handle_oneshot_broadcast+0x1cf/0x200()^M [ 203.130138] Modules linked in: click(OX) proclikefs(OX) nfsv3 ipod(OX) ib_iser rdma_cm ib_cm iw_cm ib_sa ib_mad ib_core ib_addr iscsi_tcp libiscsi_tcp libiscsi scsi_transport_iscsi nfsd nfs_acl auth_rpcgss nfs fscache 8021q lockd mrp garp stp sunrpc llc psmouse gpio_ich ipmi_si dcdbas serio_raw i7core_edac edac_core lp joydev acpi_power_meter lpc_ich mac_hid parport hid_generic usbhid hid mptsas mptscsih mptbase scsi_transport_sas bnx2^M [ 203.169124] CPU: 0 PID: 2207 Comm: kclick Tainted: G D W IOX 3.13.0-117-generic #164~precise1-Ubuntu^M [ 203.178672] Hardware name: Dell Inc. PowerEdge R710/00W9X3, BIOS 2.1.15 09/02/2010^M [ 203.186227] 0000000000000000 ffff880323203df8 ffffffff81765bf5 0000000000000000^M [ 203.193645] 000000000000025c ffff880323203e38 ffffffff8106e2fc ffff880323203e18^M [ 203.201062] 7fffffffffffffff 000000000000dce0 0000000000000000 ffffffff81f06b20^M [ 203.208478] Call Trace:^M [ 203.210916] [] dump_stack+0x64/0x82^M [ 203.216672] [] warn_slowpath_common+0x8c/0xc0^M [ 203.222668] [] warn_slowpath_null+0x1a/0x20^M [ 203.228492] [] tick_handle_oneshot_broadcast+0x1cf/0x200^M [ 203.235443] [] timer_interrupt+0x15/0x20^M [ 203.241006] [] handle_irq_event_percpu+0x65/0x250^M [ 203.247349] [] handle_irq_event+0x48/0x70^M [ 203.252999] [] handle_edge_irq+0x77/0x110^M [ 203.258647] [] handle_irq+0x22/0x40^M [ 203.263775] [] do_IRQ+0x5a/0xe0^M [ 203.268558] [] common_interrupt+0x6d/0x6d^M [ 203.274204] [] ? panic+0x19e/0x1e1^M [ 203.279870] [] ? panic+0x100/0x1e1^M [ 203.284912] [] oops_end+0x14a/0x160^M [ 203.290040] [] no_context+0x1be/0x1cd^M [ 203.295342] [] bad_area_nosemaphore+0x1d3/0x1f2^M [ 203.301685] [] bad_area_nosemaphore+0x13/0x15^M [ 203.307680] [] do_page_fault+0x3c2/0x580^M [ 203.313515] [] ? click_lalloc+0x3c/0x70 [click]^M [ 203.319784] [] ? click_lfree+0x1c/0x40 [click]^M [ 203.326015] [] ? _ZN13HashContainerI15IPRewriterEntry3HCaIS0_EE6rehashEj+0xfb/0x220 [click]^M [ 203.336114] [] ? _ZN14IPRewriterBase10store_flowEP14IPRewrite_H3bca1ae860+0x3e1/0x520 [click]^M [ 203.346391] [] ? _ZN13FullNoteQueue4pushEiP6Packet+0x2a7/0x2b0 [click]^M [ 203.354554] [] do_page_fault+0x1a/0x70^M [ 203.359943] [] page_fault+0x28/0x30^M [ 203.365077] [] ? bnx2_start_xmit+0x249/0x770 [bnx2]^M [ 203.371597] [] ? bnx2_start_xmit+0x218/0x770 [bnx2]^M [ 203.378228] [] _ZN8ToDevice12queue_packetEP6PacketP12netdev_queue+0x10e/0x230 [click]^M [ 203.387809] [] _ZN8ToDevice8run_taskEP4Task+0xad/0x380 [click]^M [ 203.395386] [] _ZN12RouterThread6driverEv+0x2c4/0x490 [click]^M [ 203.402889] [] _ZL11click_schedPv+0x107/0x200 [click]^M [ 203.409701] [] ? _Z19click_cleanup_schedv+0x180/0x180 [click]^M [ 203.417086] [] kthread+0xc9/0xe0^M [ 203.421955] [] ? flush_kthread_worker+0xb0/0xb0^M [ 203.428126] [] ret_from_fork+0x58/0x90^M [ 203.433515] [] ? flush_kthread_worker+0xb0/0xb0^M [ 203.439684] ---[ end trace 8de0a075e6b25cbd ]---^M**

Please could anyone explain the problem i might be making if someone has had a similar problem.