1 2 3 4 5 6 7
| root@ubuntu:/home/sscc# sysctl -p net.ipv4.ip_forward = 1 net.ipv4.conf.all.send_redirects = 1 net.ipv4.conf.all.accept_source_route = 1 sysctl: cannot stat /proc/sys/net/bridge/bridge-nf-call-arptables: 没有那个文件或目录 sysctl: cannot stat /proc/sys/net/bridge/bridge-nf-call-iptables: 没有那个文件或目录 sysctl: cannot stat /proc/sys/net/bridge/bridge-nf-call-ip6tables: 没有那个文件或目录
|
解决办法:
1 2 3 4 5 6 7 8 9 10 11
| root@ubuntu:/home/sscc# modprobe br_netfilter root@ubuntu:/home/sscc# ls /proc/sys/net/bridge/ bridge-nf-call-arptables bridge-nf-call-iptables bridge-nf-filter-vlan-tagged bridge-nf-call-ip6tables bridge-nf-filter-pppoe-tagged bridge-nf-pass-vlan-input-dev root@ubuntu:/home/sscc# sysctl -p net.ipv4.ip_forward = 1 net.ipv4.conf.all.send_redirects = 1 net.ipv4.conf.all.accept_source_route = 1 net.bridge.bridge-nf-call-arptables = 0 net.bridge.bridge-nf-call-iptables = 0 net.bridge.bridge-nf-call-ip6tables = 0
|
错误原因
The /proc/sys/net/bridge/* files are only created after br_netfilter
(kernel module) is loaded: