
Solarflare
Server
Adapter
User
Guide
Solarflare
Adapters
on
Linux
Issue
20
©
Solarflare
Communications
2017
84
Global
Flow
Count
Configure
the
number
of
simultaneous
flows
that
will
be
managed
by
RFS.
The
suggested
flow
count
will
depend
on
the
expected
number
of
active
connections
at
any
given
time
and
may
be
less
than
the
number
of
open
connections.
The
value
is
rounded
up
to
the
nearest
power
of
two.
#
echo
32768
>
/proc/sys/net/core/rps_sock_flow_entries
Per
Queue
Flow
Count
For
each
adapter
interface
there
will
exist
a
‘queue’
directory
containing
one
‘rx’
or
‘tx’
subdirectory
for
each
queue
associated
with
the
interface.
For
RFS
only
the
receive
queues
are
relevant.
#
cd
/sys/class/net/eth3/queue
Within
each
‘rx’
subdirectory,
the
rps_flow_cnt
file
holds
the
number
of
entries
in
the
per
‐
queue
flow
table.
If
only
a
single
queue
is
used
then
rps_flow_cnt
will
be
the
same
as
rps_sock_flow_entries
.
When
multiple
queues
are
configured
the
count
will
be
equal
to
rps_sock_flow_entries
/
N
where
N
is
the
number
of
queues,
for
example:
rps_sock_flow_entries
=
32768
and
there
are
16
queues
then
rps_flow_cnt
for
each
queue
will
be
configured
as
2048.
#
echo
2048
>
/sys/class/net/eth3/queues/rx
‐
0/rps_flow_cnt
#
echo
2048
>
/sys/class/net/eth3/queues/rx
‐
1/rps_flow_cnt
Disable
RFS
To
turn
off
RFS
using
the
following
command:
#
ethtool
‐
K
<devname>
ntuple
off
3.18
Solarflare
Accelerated
RFS
(SARFS)
The
Solarflare
Accelerated
RFS
feature
directs
TCP
flows
to
queues
processed
on
the
same
CPU
core
as
the
user
process
which
is
consuming
the
flow.
By
querying
the
CPU
when
a
TCP
packet
is
sent,
the
transmit
queue
can
be
selected
from
the
interrupt
associated
with
the
correct
CPU
core.
A
hardware
filter
directs
the
receive
flow
to
the
same
queue.
SARFS
is
provided
for
servers
that
do
not
support
standard
Linux
ARFS.
For
details
of
Linux
ARFS,
refer
to
the
previous
section.
Additional
information
can
be
found
at
the
following
link:
https://access.redhat.com/documentation/en
‐
US/Red_Hat_Enterprise_Linux/6/
html/Performance_Tuning_Guide/network
‐
acc
‐
rfs.html
Overall
SARFS
can
improve
bandwidth,
especially
for
smaller
packets
and
because
core
assignment
is
not
subject
to
the
semi
‐
random
selection
of
transmit
and
receive
queues,
both
bandwidth
and
latency
become
more
consistent.