All of lore.kernel.org
 help / color / mirror / Atom feed
From: Aleksandar Milivojevic <amilivojevic@pbl.ca>
To: Netfilter Users <netfilter@lists.netfilter.org>
Subject: Re: No PREROUTING for OUTPUT?
Date: Mon, 18 Oct 2004 09:51:07 -0500	[thread overview]
Message-ID: <4173D85B.8060908@pbl.ca> (raw)
In-Reply-To: <5FCB4E67C52322BD4ABBF882@[10.0.0.4]>

Kenneth Porter wrote:
> Can anyone confirm that the PREROUTING chain is absent from the OUTPUT 
> packet path? I wanted to tag my UDP packets with TOS Minimize-Delay so 
> that they'd go in my high-priority traffic shaping queues, but if 
> PREROUTING isn't used in the output path, the packets can't be tagged 
> until after they've been through the shaper. (Isn't the shaper part of 
> "routing decision" in the diagrams?)

The equivalent of PREROUTING chain for locally generated packets would 
be OUTPUT chain.  It exists in filter, nat, and mangle tables.  I'd 
guess what you need is something like:

    iptables -t mangle -A OUTPUT -p udp -j TOS --set-tos Minimize-Delay
    iptables -t mangle -A PREROUTING -p udp -j TOS --set-tos Minimize-Delay

First line would handle locally generated packets, second would handle 
forwarded packets (it would catch incoming too, but I guess it can be 
safely ignored in this case).

-- 
Aleksandar Milivojevic <amilivojevic@pbl.ca>    Pollard Banknote Limited
Systems Administrator                           1499 Buffalo Place
Tel: (204) 474-2323 ext 276                     Winnipeg, MB  R3T 1L7


  reply	other threads:[~2004-10-18 14:51 UTC|newest]

Thread overview: 5+ messages / expand[flat|nested]  mbox.gz  Atom feed  top
2004-10-17 19:54 No PREROUTING for OUTPUT? Kenneth Porter
2004-10-18 14:51 ` Aleksandar Milivojevic [this message]
     [not found] <5FCB4E67C52322BD4ABBF882@10.0.0.4>
2004-10-17 20:31 ` George Alexandru Dragoi
2004-10-17 21:10   ` Kenneth Porter
     [not found]   ` <06B6B683FC4088203BA6B8D7@10.0.0.4>
2004-10-18 11:11     ` George Alexandru Dragoi

Reply instructions:

You may reply publicly to this message via plain-text email
using any one of the following methods:

* Save the following mbox file, import it into your mail client,
  and reply-to-all from there: mbox

  Avoid top-posting and favor interleaved quoting:
  https://en.wikipedia.org/wiki/Posting_style#Interleaved_style

* Reply using the --to, --cc, and --in-reply-to
  switches of git-send-email(1):

  git send-email \
    --in-reply-to=4173D85B.8060908@pbl.ca \
    --to=amilivojevic@pbl.ca \
    --cc=netfilter@lists.netfilter.org \
    /path/to/YOUR_REPLY

  https://kernel.org/pub/software/scm/git/docs/git-send-email.html

* If your mail client supports setting the In-Reply-To header
  via mailto: links, try the mailto: link
Be sure your reply has a Subject: header at the top and a blank line before the message body.
This is an external index of several public inboxes,
see mirroring instructions on how to clone and mirror
all data and code used by this external index.