经过测试,加了 nft 的内核配置后,可以正常运行dockerd了。
> diff .config-bjr-addnft .config
1063d1062
< CONFIG_NETFILTER_NETLINK=y
1065d1063
< # CONFIG_NETFILTER_NETLINK_HOOK is not set
1098,1120c1096
< CONFIG_NF_TABLES=y
< # CONFIG_NF_TABLES_INET is not set
< # CONFIG_NF_TABLES_NETDEV is not set
< # CONFIG_NFT_NUMGEN is not set
< CONFIG_NFT_CT=y
< # CONFIG_NFT_CONNLIMIT is not set
< # CONFIG_NFT_LOG is not set
< # CONFIG_NFT_LIMIT is not set
< CONFIG_NFT_MASQ=y
< CONFIG_NFT_REDIR=y
< CONFIG_NFT_NAT=y
< # CONFIG_NFT_TUNNEL is not set
< # CONFIG_NFT_OBJREF is not set
< # CONFIG_NFT_QUOTA is not set
< # CONFIG_NFT_REJECT is not set
< CONFIG_NFT_COMPAT=y
< # CONFIG_NFT_HASH is not set
< # CONFIG_NFT_XFRM is not set
< # CONFIG_NFT_SOCKET is not set
< # CONFIG_NFT_OSF is not set
< # CONFIG_NFT_TPROXY is not set
< # CONFIG_NFT_SYNPROXY is not set
< # CONFIG_NF_FLOW_TABLE is not set
---
> # CONFIG_NF_TABLES is not set
1261,1264d1236
< CONFIG_NF_TABLES_IPV4=y
< # CONFIG_NFT_DUP_IPV4 is not set
< # CONFIG_NFT_FIB_IPV4 is not set
< # CONFIG_NF_TABLES_ARP is not set
1294d1265
< # CONFIG_NF_TABLES_IPV6 is not set
1302d1272
< # CONFIG_NF_TABLES_BRIDGE is not set
docker 运行正常
> docker ps
CONTAINER ID IMAGE COMMAND CREATED STATUS PORTS NAMES
ff206fdf473a rancher/k3s:v1.30.3-k3s1 "/bin/k3d-entrypoint…" 2 days ago Up 8 minutes k3d-freshncp-server-0
78f859e5c98b registry:2 "/entrypoint.sh /etc…" 2 days ago Up 8 minutes 0.0.0.0:39301->5000/tcp k3d-registry
> uname -a
Linux freshncp 6.1.75 #6 SMP Sun Aug 18 20:01:41 CST 2024 aarch64 aarch64 aarch64 GNU/Linux