ipip学习记录-凯发app官方网站

凯发app官方网站-凯发k8官网下载客户端中心 | | 凯发app官方网站-凯发k8官网下载客户端中心
  • 博客访问: 413380
  • 博文数量: 124
  • 博客积分: 0
  • 博客等级: 民兵
  • 技术积分: 872
  • 用 户 组: 普通用户
  • 注册时间: 2018-03-29 14:38
个人简介

默默的一块石头

文章分类

全部博文(124)

文章存档

2022年(26)

2021年(10)

2020年(28)

2019年(60)

我的朋友
相关博文
  • ·
  • ·
  • ·
  • ·
  • ·
  • ·
  • ·
  • ·
  • ·
  • ·

分类: linux

2022-07-07 17:01:40

ipv4的情况下:
ping 10.10.200.10 -c 8

ip_finish_output2()-->___neigh_create()-->arp_constructor()
static int arp_constructor(struct neighbour *neigh)
{
 ......
if (!dev->header_ops) {
neigh->nud_state = nud_noarp;
neigh->ops = &arp_direct_ops;
neigh->output = neigh_direct_output;

......
}
static const struct neigh_ops arp_direct_ops = {
.family =af_inet,
.output =neigh_direct_output,
.connected_output =neigh_direct_output,
};

int neigh_direct_output(struct neighbour *neigh, struct sk_buff *skb)
{
return dev_queue_xmit(skb);
}
export_symbol(neigh_direct_output);

jul  7 16:29:29 chro kernel: [  279.227770] cpu: 9 pid: 5317 comm: ping not tainted 5.4.1 #104
jul  7 16:29:29 chro kernel: [  279.227772] hardware name: machenike f117-x/x15cn, bios 008.t14 01/26/2021
jul  7 16:29:29 chro kernel: [  279.227773] call trace:
jul  7 16:29:29 chro kernel: [  279.227778]  dump_stack 0x6d/0x95
jul  7 16:29:29 chro kernel: [  279.227788]  ipip_tunnel_xmit 0x4d/0x170 [ipip]
jul  7 16:29:29 chro kernel: [  279.227794]  dev_hard_start_xmit 0x96/0x200
jul  7 16:29:29 chro kernel: [  279.227801]  __dev_queue_xmit 0x775/0xa10
jul  7 16:29:29 chro kernel: [  279.227809]  ? _raw_write_unlock_bh 0x1a/0x20
jul  7 16:29:29 chro kernel: [  279.227813]  ? vprintk_func 0x47/0xc0
jul  7 16:29:29 chro kernel: [  279.227817]  dev_queue_xmit 0x10/0x20
jul  7 16:29:29 chro kernel: [  279.227821]  ? dev_queue_xmit 0x10/0x20
jul  7 16:29:29 chro kernel: [  279.227825]  neigh_direct_output 0x11/0x20
jul  7 16:29:29 chro kernel: [  279.227828]  ip_finish_output2 0x1fe/0x900
jul  7 16:29:29 chro kernel: [  279.227833]  __ip_finish_output 0xfa/0x1c0
jul  7 16:29:29 chro kernel: [  279.227836]  ? __ip_finish_output 0xfa/0x1c0
jul  7 16:29:29 chro kernel: [  279.227840]  ip_finish_output 0x2c/0xa0
jul  7 16:29:29 chro kernel: [  279.227845]  ip_output 0x6d/0xe0
jul  7 16:29:29 chro kernel: [  279.227849]  ? __ip_finish_output 0x1c0/0x1c0
jul  7 16:29:29 chro kernel: [  279.227855]  ip_local_out 0x3b/0x50
jul  7 16:29:29 chro kernel: [  279.227861]  ip_send_skb 0x19/0x40
jul  7 16:29:29 chro kernel: [  279.227865]  ip_push_pending_frames 0x33/0x40
jul  7 16:29:29 chro kernel: [  279.227872]  raw_sendmsg 0x9e5/0xcc0
jul  7 16:29:29 chro kernel: [  279.227878]  ? pat_enabled 0x20/0x20
jul  7 16:29:29 chro kernel: [  279.227887]  ? _cond_resched 0x19/0x40
jul  7 16:29:29 chro kernel: [  279.227892]  ? aa_sk_perm 0x43/0x190
jul  7 16:29:29 chro kernel: [  279.227899]  inet_sendmsg 0x64/0x70
jul  7 16:29:29 chro kernel: [  279.227906]  ? inet_sendmsg 0x64/0x70
jul  7 16:29:29 chro kernel: [  279.227912]  sock_sendmsg 0x5c/0x70
jul  7 16:29:29 chro kernel: [  279.227918]  __sys_sendto 0x13f/0x180
jul  7 16:29:29 chro kernel: [  279.227925]  ? handle_mm_fault 0xcb/0x210
jul  7 16:29:29 chro kernel: [  279.227930]  ? __do_page_fault 0x2be/0x4d0
jul  7 16:29:29 chro kernel: [  279.227938]  __x64_sys_sendto 0x28/0x30
jul  7 16:29:29 chro kernel: [  279.227945]  do_syscall_64 0x57/0x190
jul  7 16:29:29 chro kernel: [  279.227952]  entry_syscall_64_after_hwframe 0x44/0xa9

ip_finish_output2()-->___neigh_create()-->arp_constructor()-->neigh_direct_output()-->dev_hard_start_xmit()-->ipip_tunnel_xmit()-->ip_tunnel_xmit()-->iptunnel_xmit()-->ip_local_out()-->ip_finish_output2()-->___neigh_create()-->arp_constructor()
ip_finish_output2()-->___neigh_create()-->arp_constructor()

static int arp_constructor(struct neighbour *neigh)
{
 ......
else {
if (dev->header_ops->cache)
neigh->ops = &arp_hh_ops;
else
neigh->ops = &arp_generic_ops;

if (neigh->nud_state & nud_valid)
neigh->output = neigh->ops->connected_output;
else
neigh->output = neigh->ops->output;
}
return 0;
}

static const struct neigh_ops arp_generic_ops = {
.family =af_inet,
.solicit =arp_solicit,
.error_report =arp_error_report,
.output =neigh_resolve_output,
.connected_output =neigh_connected_output,
};

jul  7 16:29:29 chro kernel: [  279.229426] call trace:
jul  7 16:29:29 chro kernel: [  279.229432]  dump_stack 0x6d/0x95
jul  7 16:29:29 chro kernel: [  279.229438]  arp_send_dst.part.20 0x39/0x90
jul  7 16:29:29 chro kernel: [  279.229443]  arp_solicit 0x120/0x300
jul  7 16:29:29 chro kernel: [  279.229450]  ? skb_clone 0x56/0xc0
jul  7 16:29:29 chro kernel: [  279.229457]  ? __skb_clone 0x2e/0x130
jul  7 16:29:29 chro kernel: [  279.229463]  neigh_probe 0x52/0x70
jul  7 16:29:29 chro kernel: [  279.229469]  __neigh_event_send 0x1a2/0x350
jul  7 16:29:29 chro kernel: [  279.229474]  neigh_resolve_output 0x128/0x1c0
jul  7 16:29:29 chro kernel: [  279.229479]  ip_finish_output2 0x1fe/0x900
jul  7 16:29:29 chro kernel: [  279.229497]  ? nf_ct_deliver_cached_events 0xa9/0x110 [nf_conntrack]
jul  7 16:29:29 chro kernel: [  279.229505]  __ip_finish_output 0xfa/0x1c0
jul  7 16:29:29 chro kernel: [  279.229508]  ? __ip_finish_output 0xfa/0x1c0
jul  7 16:29:29 chro kernel: [  279.229513]  ip_finish_output 0x2c/0xa0
jul  7 16:29:29 chro kernel: [  279.229517]  ip_output 0x6d/0xe0
jul  7 16:29:29 chro kernel: [  279.229522]  ? __ip_finish_output 0x1c0/0x1c0
jul  7 16:29:29 chro kernel: [  279.229526]  ip_local_out 0x3b/0x50
jul  7 16:29:29 chro kernel: [  279.229532]  iptunnel_xmit 0x174/0x200
jul  7 16:29:29 chro kernel: [  279.229541]  ip_tunnel_xmit 0x683/0x940 [ip_tunnel]
jul  7 16:29:29 chro kernel: [  279.229552]  ipip_tunnel_xmit 0x166/0x170 [ipip]
jul  7 16:29:29 chro kernel: [  279.229557]  dev_hard_start_xmit 0x96/0x200
jul  7 16:29:29 chro kernel: [  279.229562]  __dev_queue_xmit 0x775/0xa10
jul  7 16:29:29 chro kernel: [  279.229569]  ? _raw_write_unlock_bh 0x1a/0x20
jul  7 16:29:29 chro kernel: [  279.229574]  ? vprintk_func 0x47/0xc0
jul  7 16:29:29 chro kernel: [  279.229580]  dev_queue_xmit 0x10/0x20
jul  7 16:29:29 chro kernel: [  279.229584]  ? dev_queue_xmit 0x10/0x20
jul  7 16:29:29 chro kernel: [  279.229590]  neigh_direct_output 0x11/0x20
jul  7 16:29:29 chro kernel: [  279.229594]  ip_finish_output2 0x1fe/0x900
jul  7 16:29:29 chro kernel: [  279.229600]  __ip_finish_output 0xfa/0x1c0
jul  7 16:29:29 chro kernel: [  279.229604]  ? __ip_finish_output 0xfa/0x1c0
jul  7 16:29:29 chro kernel: [  279.229608]  ip_finish_output 0x2c/0xa0
jul  7 16:29:29 chro kernel: [  279.229613]  ip_output 0x6d/0xe0
jul  7 16:29:29 chro kernel: [  279.229617]  ? __ip_finish_output 0x1c0/0x1c0
jul  7 16:29:29 chro kernel: [  279.229622]  ip_local_out 0x3b/0x50
jul  7 16:29:29 chro kernel: [  279.229627]  ip_send_skb 0x19/0x40
jul  7 16:29:29 chro kernel: [  279.229631]  ip_push_pending_frames 0x33/0x40
jul  7 16:29:29 chro kernel: [  279.229637]  raw_sendmsg 0x9e5/0xcc0
jul  7 16:29:29 chro kernel: [  279.229643]  ? pat_enabled 0x20/0x20
jul  7 16:29:29 chro kernel: [  279.229652]  ? _cond_resched 0x19/0x40
jul  7 16:29:29 chro kernel: [  279.229657]  ? aa_sk_perm 0x43/0x190
jul  7 16:29:29 chro kernel: [  279.229663]  inet_sendmsg 0x64/0x70
jul  7 16:29:29 chro kernel: [  279.229670]  ? inet_sendmsg 0x64/0x70
jul  7 16:29:29 chro kernel: [  279.229678]  sock_sendmsg 0x5c/0x70
jul  7 16:29:29 chro kernel: [  279.229684]  __sys_sendto 0x13f/0x180
jul  7 16:29:29 chro kernel: [  279.229692]  ? handle_mm_fault 0xcb/0x210
jul  7 16:29:29 chro kernel: [  279.229697]  ? __do_page_fault 0x2be/0x4d0
jul  7 16:29:29 chro kernel: [  279.229705]  __x64_sys_sendto 0x28/0x30
jul  7 16:29:29 chro kernel: [  279.229713]  do_syscall_64 0x57/0x190
jul  7 16:29:29 chro kernel: [  279.229720]  entry_syscall_64_after_hwframe 0x44/0xa9

阅读(705) | 评论(0) | 转发(0) |
给主人留下些什么吧!~~
")); function link(t){ var href= $(t).attr('href'); href ="?url=" encodeuricomponent(location.href); $(t).attr('href',href); //setcookie("returnouturl", location.href, 60, "/"); }
网站地图