亚洲av成人无遮挡网站在线观看,少妇性bbb搡bbb爽爽爽,亚洲av日韩精品久久久久久,兔费看少妇性l交大片免费,无码少妇一区二区三区

  免費(fèi)注冊 查看新帖 |

Chinaunix

  平臺 論壇 博客 文庫
12下一頁
最近訪問板塊 發(fā)新帖
查看: 55353 | 回復(fù): 17
打印 上一主題 下一主題

[網(wǎng)絡(luò)管理] iptables: No chain/target/match by that name. [復(fù)制鏈接]

論壇徽章:
0
跳轉(zhuǎn)到指定樓層
1 [收藏(0)] [報(bào)告]
發(fā)表于 2012-01-15 15:21 |只看該作者 |倒序?yàn)g覽
本帖最后由 xuanhan863 于 2012-01-17 16:40 編輯

在做rule: iptables -t nat -A PREROUTING -p tcp --destination-port 80 -j REDIRECT --to-port 7000

提示: iptables: No chain/target/match by that name.

內(nèi)核 2.6.39.  iptables v1.4.12.1  是編譯進(jìn)kernel的.

什么原因呢?

論壇徽章:
381
CU十二周年紀(jì)念徽章
日期:2014-01-04 22:46:58CU大;照
日期:2013-03-13 15:32:35CU大;照
日期:2013-03-13 15:38:15CU大牛徽章
日期:2013-03-13 15:38:52CU大;照
日期:2013-03-14 14:08:55CU大;照
日期:2013-04-17 11:17:19CU大;照
日期:2013-04-17 11:17:32CU大;照
日期:2013-04-17 11:17:37CU大牛徽章
日期:2013-04-17 11:17:42CU大;照
日期:2013-04-17 11:17:47CU大;照
日期:2013-04-17 11:17:52CU大;照
日期:2013-04-17 11:17:56
2 [報(bào)告]
發(fā)表于 2012-01-15 16:01 |只看該作者
lsmod看下iptables的模塊加載了沒有

論壇徽章:
0
3 [報(bào)告]
發(fā)表于 2012-01-15 18:31 |只看該作者
回復(fù) 2# chenyx


    iptables 沒編譯成模塊.

論壇徽章:
381
CU十二周年紀(jì)念徽章
日期:2014-01-04 22:46:58CU大;照
日期:2013-03-13 15:32:35CU大;照
日期:2013-03-13 15:38:15CU大;照
日期:2013-03-13 15:38:52CU大牛徽章
日期:2013-03-14 14:08:55CU大;照
日期:2013-04-17 11:17:19CU大;照
日期:2013-04-17 11:17:32CU大牛徽章
日期:2013-04-17 11:17:37CU大牛徽章
日期:2013-04-17 11:17:42CU大;照
日期:2013-04-17 11:17:47CU大;照
日期:2013-04-17 11:17:52CU大;照
日期:2013-04-17 11:17:56
4 [報(bào)告]
發(fā)表于 2012-01-15 21:02 |只看該作者
你的iptables的模塊(比如ip_tables)是編譯進(jìn)內(nèi)核了嗎(是*,不是M)?
看你在1樓的描述,應(yīng)該是M,你試試modprobe加載ip_tables ,ip_nat模塊,看看你的那個(gè)規(guī)則能不能正確執(zhí)行

論壇徽章:
0
5 [報(bào)告]
發(fā)表于 2012-01-15 22:55 |只看該作者
iptables --version
iptables -t nat -L
iptables -t nat -A PREROUTING -i eth0 -p tcp --dport 80 -j DNAT --to 192.168.0.1
看看哪一步的時(shí)候出錯(cuò)。

論壇徽章:
0
6 [報(bào)告]
發(fā)表于 2012-01-16 10:52 |只看該作者
回復(fù) 4# chenyx


    我剛開始以為是以M的形式存在的. 所以也嘗試了modprobe ip_tables && modprobe ip_nat, 但問題依舊.
    后來我看kernel .config, 發(fā)現(xiàn)是*, 編譯進(jìn)內(nèi)核的.

論壇徽章:
0
7 [報(bào)告]
發(fā)表于 2012-01-16 10:55 |只看該作者
回復(fù) 5# marsaber


    這三步都沒輸出錯(cuò)誤..

    localhost stranger # iptables --version
        iptables v1.4.12.1
    localhost stranger # iptables -t nat -L
        Chain PREROUTING (policy ACCEPT)
        target     prot opt source               destination         

        Chain INPUT (policy ACCEPT)
        target     prot opt source               destination         

        Chain OUTPUT (policy ACCEPT)
        target     prot opt source               destination         

        Chain POSTROUTING (policy ACCEPT)
        target     prot opt source               destination         
    localhost stranger # iptables -t nat -A PREROUTING -i eth0 -p tcp --dport 80 -j DNAT --to 192.168.0.1

論壇徽章:
0
8 [報(bào)告]
發(fā)表于 2012-01-16 21:33 |只看該作者
那有可能是你的“-j REDIRECT --to-port 7000”出問題了。
這個(gè)我沒有用過,你再好好看看。

論壇徽章:
0
9 [報(bào)告]
發(fā)表于 2012-01-16 21:43 |只看該作者
[root@CentOS6 ~]# iptables -t nat -L -n
Chain PREROUTING (policy ACCEPT)
target     prot opt source               destination

Chain INPUT (policy ACCEPT)
target     prot opt source               destination

Chain OUTPUT (policy ACCEPT)
target     prot opt source               destination

Chain POSTROUTING (policy ACCEPT)
target     prot opt source               destination
[root@CentOS6 ~]# iptables -t nat -A PREROUTING -p tcp --dport 80 -j REDIRECT --to-port 7000
[root@CentOS6 ~]# iptables -t nat -L -n
Chain PREROUTING (policy ACCEPT)
target     prot opt source               destination
REDIRECT   tcp  --  0.0.0.0/0            0.0.0.0/0            tcp dpt:80 redir ports 7000

Chain INPUT (policy ACCEPT)
target     prot opt source               destination

Chain OUTPUT (policy ACCEPT)
target     prot opt source               destination

Chain POSTROUTING (policy ACCEPT)
target     prot opt source               destination
[root@CentOS6 ~]#

我的木有問題,我的內(nèi)核是3.0的,iptables是1.4.12

論壇徽章:
0
10 [報(bào)告]
發(fā)表于 2012-01-17 10:57 |只看該作者
回復(fù) 8# marsaber


    您是說語法錯(cuò)誤,或者端口被占用?  我嘗試了REDIRECT到別的端口, 依舊 iptables: No chain/target/match by that name.
您需要登錄后才可以回帖 登錄 | 注冊

本版積分規(guī)則 發(fā)表回復(fù)

  

北京盛拓優(yōu)訊信息技術(shù)有限公司. 版權(quán)所有 京ICP備16024965號-6 北京市公安局海淀分局網(wǎng)監(jiān)中心備案編號:11010802020122 niuxiaotong@pcpop.com 17352615567
未成年舉報(bào)專區(qū)
中國互聯(lián)網(wǎng)協(xié)會會員  聯(lián)系我們:huangweiwei@itpub.net
感謝所有關(guān)心和支持過ChinaUnix的朋友們 轉(zhuǎn)載本站內(nèi)容請注明原作者名及出處

清除 Cookies - ChinaUnix - Archiver - WAP - TOP