Fix set_alloc_hint op cause KeyValueStore crash problem

Now KeyValueStore doesn't support set_alloc_hit op, the implementation of
_do_transaction need to consider decoding the arguments. Otherwise, the
arguments will be regarded as the next op.

Fix the same problem for MemStore.

Fix #8381

Reported-by: Xinxin Shu <xinxin.shu5040@gmail.com>
Signed-off-by: Haomai Wang <haomaiwang@gmail.com>
README: clean up some whitespace

Remove $ prefix, use tab consistently.

Signed-off-by: Sage Weil <sage@inktank.com>
README: move package dependencies into separate files

Sorted, with a short, simple command to paste.  Avoid the duplication of
the lists.

Signed-off-by: Sage Weil <sage@inktank.com>
Update architecture.rst:Calculating PG IDs

To Calculate PG ID, if I didn't get it wrong, CRUSH calculates the hash modulo 
the number of PGs instead of OSDs, according to osd/osd_types.cc:963 
ceph_stable_mod(pg.ps(), pg_num, pg_num_mask).

Signed-off-by: Kai Zhang <zakir.exe@gmail.com>
os/FileStore: fix journal-less operation

A few different fixes here:

- make the op_seq correct on start when there is no replay
- make an explicit 'no journal' case in queue_transaction (one that
  actually works).  Note that the 'trailing journal' mode is probably
  still broken.
- add a -J flag to vstart.sh for journalless operation

Signed-off-by: Sage Weil <sage@inktank.com>
os/FileStore: refactor backend instantiation

Use a factory method for creating the backend so that the logic is not
duplicated in mkfs() and _detect_fs().  Make the other fs-dependent logic
(xattr limits) key off of the fs_type magic.

Signed-off-by: Sage Weil <sage@inktank.com>
os/FileStore: include filestore backend, f_type in osd metadata

Report the FileStore backend and underlying fs type as part of the osd
metadata shared with the monitor.

Signed-off-by: Sage Weil <sage@inktank.com>
Improvements to radosgw docs
- Correct a typo (`rados-admin`) in admin docs
- Reorder sections in config so "above example" is in expected position
better error reporting on incompatible device requirements

Signed-off-by: Alfredo Deza <alfredo@deza.pe>
os: ObjectStore::collect_metadata unit tests

And an emacs-executable reminder about how to run a specific test.

Signed-off-by: Loic Dachary <loic@dachary.org>
os: FileStore::create_backend unit tests

Assert that the fs_type is mapped to a backend that claims to have the
matching name.

Signed-off-by: Loic Dachary <loic@dachary.org>
intial take on ceph-brag-client and tox. Python 2.7 passes

Signed-off-by: Alfredo Deza <alfredo@deza.pe>
add backport of collections.Counter for python2.6

Using Raymond Hettinger's MIT backport

Signed-off-by: Alfredo Deza <alfredo.deza@inktank.com>
remove unused variables, gets all tox envs passing

Signed-off-by: Alfredo Deza <alfredo.deza@inktank.com>
rest-api: key missing for per "rx" and "rwx"

commit 85a1cf31e6 and db266a3fb2 introduce new per "rx" and "rwx", but key missing for per "rx" and "rwx" in permmap

Signed-off-by: Ailing Zhang <ailzhang@cisco.com>
crush: add get_rule_weight_map

Calculate a weight map of OSDs for a given rule.

Signed-off-by: Sage Weil <sage@inktank.com>
vstart.sh: -e to create an ec pool called 'ec'

Signed-off-by: Sage Weil <sage@inktank.com>
mon: right justify df values

Signed-off-by: Sage Weil <sage@inktank.com>
mon: include 'max avail' in df output

Include an estimate of the maximum writeable space for each pool.  Note
that this value is a conservative estimate for that pool based on the
most-full OSD.  It is also potentially misleading as it is the available
space if *all* new data were written to this pool; one cannot (generally)
add up the available space for all pools.

Signed-off-by: Sage Weil <sage@inktank.com>
mon: set min_size to data chunk count for erasure pools

Make the min_size value meaningful for erasure pools.

Signed-off-by: Sage Weil <sage@inktank.com>