ip6tables 基本配置

2021-09-27 05:12:17 字數 1756 閱讀 2697

[root@gs ~]# ip6tables -nvl

chain input (policy drop 893 packets, 64296 bytes)

pkts bytes target prot opt in out source destination

2630 229k accept all * * ::/0 ::/0 state related,established

52 6408 accept tcp * * ::/0 ::/0 tcp dpt:80

901 107k accept tcp * * ::/0 ::/0 tcp dpt:443

64 4304 accept all * * ::/0 fe80::/16

1582 103k accept all * * fe80::/16 ::/0

chain forward (policy accept 543 packets, 224k bytes)

pkts bytes target prot opt in out source destination

chain output (policy accept 13718 packets, 1042k bytes)

pkts bytes target prot opt in out source destination

[root@gs ~]#

[root@gs ~]# cat /etc/sysconfig/ip6tables

*nat

:prerouting accept [1044:157083]

:input accept [0:0]

:output accept [4:416]

:postrouting accept [4:416]

commit

*filter

:input drop [0:0]

:forward accept [0:0]

:output accept [0:0]

-a input -m state --state related,established -j accept

-a input -p tcp -m tcp --dport 80 -j accept

-a input -p tcp -m tcp --dport 443 -j accept

-a input -d fe80::0/16 -j accept

-a input -s fe80::0/16 -j accept

commit

這裡要放行fe80::/16的資料報,主要原因是在資料通訊的時候,會有使用大量的fe80的位址進行通訊。如果不放通會影響使用。

這個fe80的位址是個神奇的位址,無法捨棄,在很多地方都需要使用,需要繼續理解。

RedHat6 配置IP位址

對於乙個機器來說,不能上網就像被禁錮的人,想出去了解世界,想讓世界了解你都是不可能的。據有關人士指出,rhce考試的時候ip如果配置不好,你連題目都拿不到 注定你的錢白花了 ip設定是網路配置的基礎,絕大多數的網路服務均建立在ip基礎上 目前ipv4 耳熟能詳的有dhcp dns ftp等,以及建立...

centOS6配置靜態IP

vim etc sysconfig network scripts ifcfg eth0 device eth0 bootproto static hwaddr 00 0c 29 c5 9d 1e ipv6init yes nm controlled yes onboot yes type ethe...

CentOS6靜態IP配置

在新裝系統後,需配置靜態ip 1 使用dhcp獲取ip 檢視當前是否聯網 ifconfig 取得當前ip,以及子網掩碼 netstat rn 獲取閘道器位址 以0.0.0.0開頭的行為預設閘道器位址 禁用dhcp和ipv6 service networkmanager stop service ip...