Commit Graph

22076 Commits

Author SHA1 Message Date
Sam Lang
0f7dadac5b client: Add symlink loop checking in path_walk()
If a loop exists in directories due to a symlink: /a/b/c -> /a
We now return -ELOOP from path_walk() instead of looping forever.

Signed-off-by: Sam Lang <sam.lang@inktank.com>
2012-11-05 17:19:41 -06:00
Sam Lang
60e54d6764 client: Fix path_walk() to support dir symlinks
Additions to Sage's commits that replace the path walked so
far with the symlinked directory path, rather than the remainder
of the path to walk.  This allows the dir symlink tests to
succeed.

Signed-off-by: Sam Lang <sam.lang@inktank.com>
2012-11-05 17:19:41 -06:00
Sam Lang
beaafe8528 test: Add tests for symlink pathological cases
The DirSyms test checks verifies that the new path_walk()
handling code properly walks through symlinked directories
even if the followsym flag is false.

The LoopSyms test checks that we correctly handle symlink
loops, where /a/b/c points back to /a.

Signed-off-by: Sam Lang <sam.lang@inktank.com>
2012-11-05 17:19:33 -06:00
tamil
e49969a67b test script for s3 tests
Signed-off-by: tamil <tamil.muthamizhan@inktank.com>
2012-11-04 16:59:27 -06:00
Sage Weil
80880eef6d client: always follow non-trailing symlinks
If we are walking /a/b/c and a or b is a symlink, follow it.  It's only
c that we don't follow when !followsym.

Signed-off-by: Sage Weil <sage@inktank.com>
2012-11-04 04:34:55 -08:00
Sage Weil
4fc67c5228 client: simplify path_walk() loop
Most paths were kludging around the for loop's i++.  Switch to a while
loop to avoid such tomfoolery.

Signed-off-by: Sage Weil <sage@inktank.com>
2012-11-04 04:34:20 -08:00
Sam Lang
a7e13681e7 test: Add symlink test for absolute paths
Signed-off-by: Sam Lang <sam.lang@inktank.com>
2012-11-01 20:17:00 -05:00
Sam Lang
4cd47c4c51 client: Fix state of symlink with absolute path
Symlinks that have an absolute path are not getting
properly dereferenced in path_walk() due to a bug
with the cur and next inode pointers, and because
the path position wasn't getting reset on the symlink
dereference.

Signed-off-by: Sam Lang <sam.lang@inktank.com>
2012-11-01 20:17:00 -05:00
John Wilkins
bc4e6b9a13 doc: Changed term "kernel object" to "kernel module". Added hyperlink to cephx.
Signed-off-by: John Wilkins <john.wilkins@inktank.com>
2012-11-01 15:56:04 -07:00
John Wilkins
019fee8224 doc: Improved the landing page for RBD.
Signed-off-by: John Wilkins <john.wilkins@inktank.com>
2012-11-01 15:30:39 -07:00
John Wilkins
536d7644f2 doc: Clarified text and added reference back to main RBD pages. Added sidebar.
Signed-off-by: John Wilkins <john.wilkins@inktank.com>
2012-11-01 15:30:00 -07:00
John Wilkins
2b2ac13714 doc: Changed RBD to librbd cache for accuracy.
Signed-off-by: John Wilkins <john.wilkins@inktank.com>
2012-11-01 15:29:06 -07:00
John Wilkins
a01b112d71 doc: changed --user to --id, and fixed a typo.
Signed-off-by: John Wilkins <john.wilkins@inktank.com>
2012-11-01 12:55:18 -07:00
Alex Elder
a7551e4d99 run_xfstests.sh: add optional iteration count
This adds a "-c <count>" option to the run_xfstests.sh script so
the full set of tests can be repeated more than once without having
to go through the setup process each time.

Signed-off-by: Alex Elder <elder@inktank.com>
Reviewed-by: Josh Durgin <josh.durgin@inktank.com>
Reviewed-by: Dan Mick <dan.mick@inktank.com>
2012-11-01 13:55:48 -05:00
John Wilkins
dfc57c4fa5 doc: minor edits to the index.
Signed-off-by: John Wilkins <john.wilkins@inktank.com>
2012-11-01 10:43:24 -07:00
John Wilkins
968b315a09 doc: Added layering to the snapshot section.
Signed-off-by: John Wilkins <john.wilkins@inktank.com>
2012-11-01 10:41:38 -07:00
Sage Weil
15ada1c7b2 doc: update notes on new rpm-based platforms
Signed-off-by: Sage Weil <sage@inktank.com>
2012-10-31 22:10:43 -07:00
Sage Weil
45005d3def doc: fix os-recommendations table
Signed-off-by: Sage Weil <sage@inktank.com>
2012-10-31 21:27:51 -07:00
John Wilkins
2d52d7c907 doc: Index entry for OS Recommendations
Signed-off-by: John Wilkins <john.wilkins@inktank.com>
2012-10-31 21:25:46 -07:00
Sage Weil
049e7fbe7b doc: update os-recommendations
Signed-off-by: Sage Weil <sage@inktank.com>
2012-10-31 21:24:56 -07:00
Sage Weil
651cbb540e Merge branch 'next' 2012-10-31 17:14:44 -07:00
Sage Weil
c435d314ca ceph-disk-activate: avoid duplicating mounts if already activated
If the given device is already mounted at the target location, do not
mount --move it again and create a bunch of dup entries in the /etc/mtab
and kernel mount table.

Signed-off-by: Sage Weil <sage@inktank.com>
2012-10-31 17:14:31 -07:00
Mike Ryan
3f08e96cc0 PG: requeue snap_trimmer after scrub finishes
Previously the snap_trimmer would continuously requeue itself until the
end of scrub. This degrades performance and fills up logs for No Good
Reason.

Signed-off-by: Mike Ryan <mike.ryan@inktank.com>
2012-10-31 15:42:03 -07:00
Mike Ryan
1bb65373df PG: requeue snap_trimmer after scrub finishes
Previously the snap_trimmer would continuously requeue itself until the
end of scrub. This degrades performance and fills up logs for No Good
Reason.

Signed-off-by: Mike Ryan <mike.ryan@inktank.com>
2012-10-31 15:34:46 -07:00
John Wilkins
310796a9dd doc: tiny syntax fix.
Signed-off-by: John Wilkins <john.wilkins@inktank.com>
2012-10-31 14:12:21 -07:00
John Wilkins
eac443e0f8 doc: Added internal anchor references.
Signed-off-by: John Wilkins <john.wilkins@inktank.com>
2012-10-31 14:11:50 -07:00
John Wilkins
3c034ae1fa doc: using remote copy
Signed-off-by: John Wilkins <john.wilkins@inktank.com>
2012-10-31 14:11:12 -07:00
Samuel Just
2857a7f49b Merge remote-tracking branch 'upstream/wip_dep_fix'
Reviewed-by: Josh Durgin <josh.durgin@inktank.com>
2012-10-31 11:37:21 -07:00
Samuel Just
1351e76c8e README: add libboost-program-options-dev
Signed-off-by: Samuel Just <sam.just@inktank.com>
2012-10-31 11:36:06 -07:00
Samuel Just
6bbe7db79d configure.ac: add program_options header check
Signed-off-by: Samuel Just <sam.just@inktank.com>
2012-10-31 10:27:33 -07:00
Samuel Just
fd4b839d04 Merge branch 'wip_journal_perf' 2012-10-30 13:31:45 -07:00
Samuel Just
9608a88b32 ReplicatedPG: actually delay op for backfill_pos
3f952afe5d neglected to
actually delay the op in ReplicatedPG::do_op.

Signed-off-by: Samuel Just <sam.just@inktank.com>
2012-10-30 13:31:10 -07:00
Samuel Just
550ef509ed Finisher: add perf counter for queue len
Signed-off-by: Samuel Just <sam.just@inktank.com>
2012-10-30 13:31:10 -07:00
Samuel Just
8d27edae03 FileJournal: rename queue_lock to finisher_lock
Signed-off-by: Samuel Just <sam.just@inktank.com>
2012-10-30 13:31:10 -07:00
Samuel Just
1a5b6263ed FileJournal: write_cond is not used
Signed-off-by: Samuel Just <sam.just@inktank.com>
2012-10-30 13:31:10 -07:00
Samuel Just
c6c8fce46b FileJournal: break writeq locking from queue_lock
This prevents the relatively long process of queueing
finishers from preventing op submission.

In submit_entry, we no longer check for full before placing
the write in the writeq, committed_thru should work anyway,
and we don't want to grab the required lock.

Signed-off-by: Samuel Just <sam.just@inktank.com>
2012-10-30 13:31:10 -07:00
Samuel Just
2646a8fe06 Throttle: reduce lock hold periods
Previously, we tended to dump a lot of log output under
the Throttle lock.  The log level for most log statements
has been reduced to 10.

Additionally, count and max are now atomic_t and can be
read without the Throttle lock.

Finally, most of the perf counter manipulations have been
moved outside of the lock.

Signed-off-by: Samuel Just <sam.just@inktank.com>
2012-10-30 13:31:10 -07:00
Samuel Just
bc91f9dd72 os: instrument submit lock, apply lock, queue_lock, write_lock
Adds Mutex perfcounter tracking to mutexes of interest.

Signed-off-by: Samuel Just <sam.just@inktank.com>
2012-10-30 13:31:10 -07:00
Samuel Just
2ed667ae9a FileStore: add op_throttle_lock
Avoid using op_tp lock for the op throttle.

Signed-off-by: Samuel Just <sam.just@inktank.com>
2012-10-30 13:31:10 -07:00
Samuel Just
542e1344b6 FileStore: don't lock op_tp in queue_op
Neither caller of queue_op can race.
1) in queue_transactions, already under submit lock
2) in _journaled_ahead, journal finisher is single threaded

Signed-off-by: Samuel Just <sam.just@inktank.com>
2012-10-30 13:31:10 -07:00
Samuel Just
a8ac453a82 perf_counters: add dec()
Signed-off-by: Samuel Just <sam.just@inktank.com>
2012-10-30 13:31:09 -07:00
Samuel Just
9601b29132 JournalingFileStore: move apply/commit sequencing to apply_manager
syncing the filestore requires a stable commit point (i.e., all ops
up to applied_seq must have been applied).  Previously, we used
journal_lock to atomically block new applies while waiting for
the remaining ones to finish.  This creates unnecessary contention.
We now use apply_manager to manage that state atomically with its
own lock.

Signed-off-by: Samuel Just <sam.just@inktank.com>
2012-10-30 13:31:09 -07:00
Samuel Just
1d9f5d27d6 JournalingFileStore: create submit_manager to order op submission
Previously, we ensured op ordering by queueing for journal and
the op queue under the journal lock.  All that is required is
that obtaining an op sequence, queueing for journal, and
(for parallel) queueing for application to the fs are done
atomically.  To that end, submit_manager now handles op submission.

Signed-off-by: Samuel Just <sam.just@inktank.com>
2012-10-30 13:31:09 -07:00
Samuel Just
117ac901ac JournalingObjectStore: remove force_commit, no longer needed
Signed-off-by: Samuel Just <sam.just@inktank.com>
2012-10-30 13:31:09 -07:00
Samuel Just
2d180e7b89 JournalingObjectStore: whitespace fix
Signed-off-by: Samuel Just <sam.just@inktank.com>
2012-10-30 13:31:09 -07:00
Samuel Just
c2c912b99e FileStore: remove trigger_commit
This is no longer used.

Signed-off-by: Samuel Just <sam.just@inktank.com>
2012-10-30 13:31:09 -07:00
Samuel Just
5326c2212a JournalingFileStore: pass -1 as the alignment if unimportant
Previously, data_align began at 0 and remained that way if no
transaction contained a large data segment.  This 0 was propagated
to prepare_single_write, which padded out most of a page to ensure
that the bl started with 0 alignment.  Passing -1 will ensure that
we don't prepad these small segments.

Signed-off-by: Samuel Just <sam.just@inktank.com>
2012-10-30 13:31:09 -07:00
Samuel Just
f7727dd598 FileStore: next_finish is not used
Signed-off-by: Samuel Just <sam.just@inktank.com>
2012-10-30 13:31:09 -07:00
Samuel Just
a268afa117 test/bench: add tp bench
Signed-off-by: Samuel Just <sam.just@inktank.com>
2012-10-30 13:31:09 -07:00
Samuel Just
e814d8fbe7 test/bench: small io benchmarker
Precreates objects and does writes to random offsets within
random objects.

Includes rados, filestore, and vanilla fs variants

Signed-off-by: Samuel Just <sam.just@inktank.com>
2012-10-30 13:31:09 -07:00