iptables route target 設定問題 - Linux

Dorothy avatar
By Dorothy
at 2008-08-18T02:39

Table of Contents

小弟我安裝了patch-o-matic-ng裡面所提供的 ROUTE target
目的是為了把封包導向到所指定的介面上。說明如下

The target can be or not a final target. It has to be used inside the
mangle table.

ROUTE target options:
--oif ifname Send the packet out using `ifname' network interface.
--iif ifname Change the packet's incoming interface to `ifname'.
--gw ip Route the packet via this gateway.
--continue Route the packet and continue traversing the rules.
--tee Route a copy of the packet, but continue traversing
the rules with the original packet, undisturbed.




但是目前遇到一個問題,只要在PREROUTING內設定之後會發現整個網路都不動了...。
例如 iptables -t mangle -A PREROUTING -p icmp -j ROUTING --oif eth0

之後再ping就會發現ping不出去...。 但是設在POSTROUTING則不會發生此問題。
不過好像也就單純把封包丟向eth0而已,就算source ip不是eth0的ip也不會去重填封包的
source ip。

設在PREROUTING網路就不通有辦法解決嗎?
又如果希望能夠做到可以重填source ip的話要設在哪呢?

--
Tags: Linux

All Comments

apt-get install ,有辦法可看到軟體的版本嗎?

Lily avatar
By Lily
at 2008-08-18T01:33
我用apt-cache search搜尋軟體 有找到我要的軟體 但它沒有列出版本 有辦法在安裝前,看到軟體的版本嗎? - ...

關於Linux的證照(LPI)

Suhail Hany avatar
By Suhail Hany
at 2008-08-18T00:12
想請問一個非Linux的問題 Linux的證照分為哪些呢? 又,如果考這些證照一定要補習嗎? 最近看到書店有在賣LPIC-1的書 不知道買這個書有可能自修考證照嗎? 謝謝:) -- ▊ ◥ thePainter. ◤ ▎ ...

兩個關於ubuntu 8.04安裝的問題

Odelette avatar
By Odelette
at 2008-08-18T00:09
小弟這兩天開始接觸大家推薦的ubuntu 抓了8.04 cd版本下來安裝 在winxp介面下裝好了 可是在安裝選單明明是選繁體中文 可是進ubuntu怎麼是簡體中文的呀 上網搜尋了文章 可是大家的語言設定都跟小弟電腦上的不一樣呀 找不到怎麼下載成繁體中文 後來重裝了英文版本 也是遇到一樣問題 orz 現在 ...

CP950 in kernel 2.4

Bethany avatar
By Bethany
at 2008-08-17T23:56
請問一下,我所使用的 kernel 是 2.4.20,但是裡面我找不到 CP950 的 Native Language Support,請問有 patch 檔可以加入嗎? 感謝回答~ - ...

ubuntu8.04連線問題

Brianna avatar
By Brianna
at 2008-08-17T23:22
使用sudo pppoeconf連線後 還是無法上網 點選連線狀態圖示 出現這樣對話盒: http://www.wretch.cc/album/show.php?i=blacksun0924andamp;b=2andamp;f=1657769768andamp;p=4 要如何解決??? -- 我不 ...