Sunday, December 31, 2017

Re: renice and network forwarding

Hi Lads,
Sorry for the delay some other project work got in my way
@martin Please find my responses to your queries in line


On 4 December 2017 at 10:09, Martin Pieuchot <mpi@openbsd.org> wrote:
>
> The thread responsible for processing packets being forwarded is
> 'softnet'. Like almost all others kernel threads is has a higher
> priority than userland processes. So renice is useless in that case.
>
> This thread already uses as much CPU time as possible. What is your
> problem? What do you want to achieve?

I just wanted to squeeze more performance out of a router I thought
(wrongly) that if OpenBSD out of the box was for general computing
that some CPU
time would be sacrificed by default to accomodate general user loads,
Disk i/o Graphics etc..
Thanks for the carlification about the kernel threads vs userland threads


>
> There's no such performance tweak. However note that if you're
> bridging interfaces you might suffer. That's because nobody did
> the work to take the bridge(4) out of the KERNEL_LOCK(). So it's
> a totally different issue than the forwarding path.

Yes Im using the Bridge to bridge a group of individual vlan interfaces from
a wholesale provider and then merge them onto the one vlan interface.
so forwarding in bridge is limited by performance of 1 CPU for bridge
forwarding

Just to clarify can I double performance by running 2 Bridges and splitting load
instead of using 1x uplink bridged to 100 vlans on one bridge
use 2x uplinks each into their own bridge and then each bridge with
50vlans each
would that provide improved performance or is it one thread / process
for bridge forwarding
regardless the number of bridges

>
>> Also is the softnet process (as seen by command top -SH) only
>> interrupt handling of packets ?
>
> It's processing all incoming packets.
>
Thanks
>> or does it cover processing (e.g. forwarding if enabled ) (either
>> bridging or routing depending on network config)
>
> All of them but some configurations work better because they don't
> require to grab the KERNEL_LOCK().
>
>> any advice welcome ...
>
> What do you want to achieve? Better performances? With which setup?
In this case Im simply using OpenBSD as a bridging devices to combine
(bridge) a load of vlans
into 1vlan, each vlan is isolated using pf to limit broadcast domains..

>
> Cheers,
> Martin



--
Kindest regards,
Tom Smyth

Mobile: +353 87 6193172
The information contained in this E-mail is intended only for the
confidential use of the named recipient. If the reader of this message
is not the intended recipient or the person responsible for
delivering it to the recipient, you are hereby notified that you have
received this communication in error and that any review,
dissemination or copying of this communication is strictly prohibited.
If you have received this in error, please notify the sender
immediately by telephone at the number above and erase the message
You are requested to carry out your own virus check before
opening any attachment.

No comments:

Post a Comment