From: Joel Newkirk Subject: Re: fwmarks Date: Sat, 1 Mar 2003 17:00:13 -0500 Sender: netfilter-admin@lists.netfilter.org Message-ID: <200303011700.13142.netfilter@newkirk.us> References: <1046551463.804.39.camel@debian> Reply-To: netfilter@newkirk.us Mime-Version: 1.0 Content-Transfer-Encoding: quoted-printable Return-path: In-Reply-To: <1046551463.804.39.camel@debian> Errors-To: netfilter-admin@lists.netfilter.org List-Help: List-Post: List-Subscribe: , List-Id: List-Unsubscribe: , List-Archive: Content-Type: text/plain; charset="us-ascii" To: Esteban , netfilter@lists.netfilter.org On Saturday 01 March 2003 03:44 pm, Esteban wrote: > i have a trnasparent squid and a nat rule to redirect ports.. > iptables -t nat -A PREROUTING -i eth0 -p tcp --dport 80 -j REDIRECT > --to-port 3128 > > then squid looks for the webpages on the two gateways (multipath). > now i would like to fwmark paquets generated by squid and thru a > routeing table route only www packages to the gw i want. > > i tryed > iptables -t mangle -A PREROUTING -p tcp --dport 80 -j MARK --set-mark > 2 If the traffic is coming from (IE squid is running on) the firewall box=20 itself then outbound traffic from squid never goes through PREROUTING. =20 Try: iptables -t mangle -A OUTPUT -p tcp --dport 80 -j MARK --set-mark 2 instead. j