Linux - net.ipv4.conf.all

Linux - net.ipv4.conf.all

arp_ignore我正在将ubuntu 16.04 服务器上的默认设置从默认值更改01.

我对该/proc/sys/net/ipv4/conf/目录的理解是,下面的文件all会影响所有接口,并且default会影响新创建的接口。

/proc/sys/net/ipv4/conf/all/arp_ignore更改to的值后1,其他文件仍设置为0

cat /proc/sys/net/ipv4/conf/*/arp_ignore
1
0
0
0

的值是否/proc/sys/net/ipv4/conf/all/arp_ignore只是覆盖接口特定文件而不是更改它们的值?

答案1

我发现了一些东西这里

    As far as I researched for IPv4 some time ago, the "default" value gets
copied to newly created interfaces only once.
"all" on the other hand allways gets applied in addition to the current
setting, but it depends on the exact setting, if its ORed, ANDed, or
whatevered:
    log_martians         OR
    accept_redirects     AND
    forwarding           ?
    mc_forwarding        AND
    medium_id
    proxy_arp            OR
    shared_media         OR
    secure_redirects     OR
    send_redirects       OR
    bootp_relay          AND
    accept_source_route  AND
    rp_filter            AND
    arp_filter           OR
    arp_announce         MAX
    arp_ignore           MAX
    arp_accept
    app_solicit
    disable_policy
    disable_xfrm
    tag
(see include/linux/inetdevice.h:83 for IN_DEV_{AND,OR,MAX}CONF)

Putting a new value in "all" doesn't change the value you read from
"$interface", but it only gets computed and used internally.

相关内容