doc: Change listed RBD cache defaults to actual defaults

Signed-off-by: Adam Crume <adamcrume@gmail.com>
osdc: Fix ObjectCounter::_readx perf counters

Signed-off-by: Adam Crume <adamcrume@gmail.com>
librbd: Add read-ahead

Signed-off-by: Adam Crume <adamcrume@gmail.com>
client: Replace client readahead logic with Readahead

Signed-off-by: Adam Crume <adamcrume@gmail.com>
when non-default striping is used, internal methods can operate on extra objects

Fixes: #9595

Signed-off-by: xinxin shu <xinxin.shu@intel.com>
add unittest for Striper::get_num_objects

Signed-off-by: xinxin shu <xinxin.shu@intel.com>
Merge pull request #2588 from xinxinsh/wip-9595

Fix #9595

Reviewed-by: Josh Durgin <josh.durgin@inktank.com>
Merge remote-tracking branch 'origin/wip-rbd-readahead'

Reviewed-by: Josh Durgin <josh.durgin@inktank.com>

Conflicts:
	src/client/Fh.h
cli: add verbose information related to argument parsing

Signed-off-by: Loic Dachary <loic-201408@dachary.org>
cli: do not parse injectargs arguments twice

The arguments of injectargs being valid ceph arguments, they are.
consumed when the ceph cli calls rados.conf_parse_argv(). It can be
worked around by obsuring them as in:

   ceph tell osd.0 injectargs '--osd_debug_drop_ping_probability 444'

where '--osd_debug_drop_ping_probability 444' is a single argument that
does not match any known argument. The trick is that it will be
evaluated again once it reaches the OSD or the MON and translated into
the expected list of arguments. Although it is clear once explained, it
is obscure and leads to strange combinations such as:

   ceph tell osd.0 injectargs '--osd_debug_op_order '

(note the extra space at the end) to set boolean parameters. A better
workaround is to add a -- marking the end of the options as in:

   ceph tell osd.0 -- injectargs --osd_debug_op_order

this one is unfortunately much less documented and the user does not
usually know the exact semantic of --, let alone where it should be
placed.

The simpler solution is to split the argument list in two if
"injectargs" is found. The arguments that show after the "injectargs"
argument is removed from the list of arguments until parsing is
complete. It implements the more intuitive syntax:

   ceph tell osd.0 injectargs --osd_debug_op_order

and the other forms are still valid for backward compatibility.

http://tracker.ceph.com/issues/9372 Fixes: #9372

Signed-off-by: Loic Dachary <loic-201408@dachary.org>
doc: update injectargs syntax

Modify the examples to use the simpler syntax, not involving -- or
grouping with quotes.

Signed-off-by: Loic Dachary <loic-201408@dachary.org>
cli: CEPH_ARGS must be before injectargs

It is incorrect to append the content of CEPH_ARGS to the argument list
when running injectargs. For instance if

  CEPH_ARGS='--log-file the.log' \
    ./ceph tell osd.0 injectargs --no-osd_debug_op_order

translates into

    ./ceph tell osd.0 injectargs --no-osd_debug_op_order \
                                 --log-file the.log

it ends up changing the log file of osd.0 which is probably unintended.
Instead CEPH_ARGS is inserted before injectargs and it translates into:

    ./ceph tell osd.0 --log-file the.log \
                      injectargs --no-osd_debug_op_order

Signed-off-by: Loic Dachary <loic-201408@dachary.org>