If the test is run against a cluster started with vstart.sh (which is
the case for make check), the --asok-does-not-need-root disables the use
of sudo and allows the test to run without requiring privileged user
permissions.
John Spray [Tue, 29 Apr 2014 15:22:51 +0000 (16:22 +0100)]
mon: warn in newfs if crash_replay_interval=0
This is the setting we would apply to data pools
created automatically, so notify the user if they're
failing to use it for data pools they have created
by hand.
Signed-off-by: John Spray <john.spray@inktank.com>
John Spray [Tue, 29 Apr 2014 14:39:45 +0000 (15:39 +0100)]
osdmap: Don't create FS pools by default
Because many Ceph users don't use the filesystem,
don't create the 'data' and 'metadata' pools by
default -- they will be created by newfs if
they are needed.
Signed-off-by: John Spray <john.spray@inktank.com>
Ilya Dryomov [Wed, 25 Jun 2014 16:23:44 +0000 (20:23 +0400)]
krbd: rework the unmap retry loop
The retry loop in the unmap path turned out to be insufficient for
doing long fsx -K runs. Replace it with a single retry and then call
out to 'udevadm settle' if the retry doesn't help.
Andrey Kuznetsov [Fri, 27 Jun 2014 06:33:58 +0000 (10:33 +0400)]
[RGW, memory leak] Memory leak in RGW has been fixed: deletion of allocated pointer to pointer to Log object has been added to "on_exit" handler.
Memory leaks detector report:
$ valgrind --leak-check=full /usr/bin/radosgw -c /etc/ceph/ceph.conf -n
client.radosgw.gateway -
...
==16986== 8 bytes in 1 blocks are definitely lost in loss record 14 of 83
==16986== at 0x4A075BC: operator new(unsigned long) (vg_replace_malloc.c:298)
==16986== by 0x58980B8: ceph::log::Log::set_flush_on_exit() (in /usr/lib64/librados.so.2.0.0)
==16986== by 0x6BE3CA: global_init(std::vector<char const*, std::allocator<char const*> >*, st
==16986== by 0x5B6B0A: main (in /usr/bin/radosgw)
...
Andrey Kuznetsov [Thu, 19 Jun 2014 13:59:31 +0000 (17:59 +0400)]
[RGW, memory leak] Memory leak in RGW GC (losing pointer during allocating Ceph-context) has been fixed.
Memory leaks detector report:
...
==117947== 11,725 (200 direct, 11,525 indirect) bytes in 25 blocks are definitely lost in loss
record 82 of 82
==117947== at 0x4A075BC: operator new(unsigned long) (vg_replace_malloc.c:298)
==117947== by 0x687CC1: RGWGC::process(int, int) (in /usr/bin/radosgw)
==117947== by 0x6884D1: RGWGC::process() (in /usr/bin/radosgw)
==117947== by 0x68875C: RGWGC::GCWorker::entry() (in /usr/bin/radosgw)
==117947== by 0x55F890A: Thread::_entry_func(void*) (in /usr/lib64/librados.so.2.0.0)
==117947== by 0x34D46079D0: start_thread (in /lib64/libpthread-2.12.so)
==117947== by 0x34D42E8B6C: clone (in /lib64/libc-2.12.so)
...
Andrey Kuznetsov [Thu, 19 Jun 2014 13:56:01 +0000 (17:56 +0400)]
[RGW, memory leaks] Memory leak in RGW initialization (Inserting new connection into connections map w/o check) has been fixed.
Memory leaks detector report:
$ valgrind --leak-check=full /usr/bin/radosgw -c /etc/ceph/ceph.conf -n
client.radosgw.gateway -f
...
=16986== 1,262 (48 direct, 1,214 indirect) bytes in 1 blocks are definitely lost in loss record 81
of 83
==16986== at 0x4A075BC: operator new(unsigned long) (vg_replace_malloc.c:298)
==16986== by 0x618F0D: RGWRados::init_complete() (in /usr/bin/radosgw)
==16986== by 0x618FE6: RGWRados::initialize() (in /usr/bin/radosgw)
==16986== by 0x63BB23: RGWRados::initialize(CephContext*, bool) (in /usr/bin/radosgw)
==16986== by 0x634D20: RGWStoreManager::init_storage_provider(CephContext*, bool) (in
/usr/bin/radosgw)
==16986== by 0x5B8970: RGWStoreManager::get_storage(CephContext*, bool) (in /usr/bin/radosgw)
==16986== by 0x5B6D5D: main (in /usr/bin/radosgw)
...
Ilya Dryomov [Thu, 26 Jun 2014 13:34:19 +0000 (17:34 +0400)]
map-unmap.sh: fail if 'rbd rm' fails
Fail if 'rbd rm' fails - most probably it'd fail with "image still has
watchers" and in that case it's a bug in the kernel client which we do
want to notice. Also nuke the trap-based error handling - cleanup() is
half-baked and not really necessary here.
Ilya Dryomov [Thu, 26 Jun 2014 13:34:19 +0000 (17:34 +0400)]
map-unmap.sh: drop the get_id() logic
Take advantage of the fact that 'rbd map' will now talk to udev and
output the device that got assigned by the kernel to the newly created
mapping. Drop the get_id() cruft, udevadm settle and chown calls.
Ilya Dryomov [Fri, 27 Jun 2014 18:43:39 +0000 (22:43 +0400)]
test_librbd_fsx: use private RNG context
It is at the core of fsx to be able to reproduce the exact op sequence
that lead to a failure. Use reentrant glibc RNG functions to make sure
that nothing else has to chance to mess up the sequence.
Yehuda Sadeh [Mon, 16 Jun 2014 18:48:24 +0000 (11:48 -0700)]
rgw: allocate enough space for bucket instance id
Fixes: #8608
Backport: dumpling, firefly
Bucket instance id is a concatenation of zone name, rados instance id,
and a running counter. We need to allocate enough space to account zone
name length.
Danny Al-Gaaf [Thu, 26 Jun 2014 03:22:02 +0000 (05:22 +0200)]
common/fd.cc: fix possible out-of-bounds write
Read max 'sizeof(target) - 1' to not write out of bound
later on the 'target[r] = 0;' call in case we read the
full PATH_MAX.
CID 1128416 (#1 of 1): Out-of-bounds write (OVERRUN)
overrun-local: Overrunning array target of 4096 bytes
at byte offset 4096 using index r (which evaluates to 4096).
Signed-off-by: Danny Al-Gaaf <danny.al-gaaf@bisect.de>
Commit 7dc93a9651f602d9c46311524fc6b54c2f1ac595 fixed an incorrect
behavior with the OSD's 'osd bench' value hard-caps. The test wasn't
appropriately modified unfortunately.
Signed-off-by: Joao Eduardo Luis <joao.luis@inktank.com>
osd: OSD: better explanation on 'max_count' calculation for 'osd bench'
'max_count' is the maximum number of bytes that we are to allow for an
'osd bench' command. This value is a hard-cap that takes into account
a predefined throughput, the 'osd bench' duration and, for a rather large
block size, can be taken as the amount of bytes that we would ever be
able to write in that period of time.
The explanation wasn't appropriate enough, hence this patch, which
hopefully will avoid confusion in the future.
Signed-off-by: Joao Eduardo Luis <joao.luis@inktank.com>
qa/workunits: cephtool: split into properly indented functions
The test was a big sequence of commands being run and it has been growing
organically for a while, even though it has maintained a sense of
locality with regard to the portions being tested.
This patch intends to split the commands into functions, allowing for a
better semantic context and easier expansion. On the other hand, this
will also allow us to implement mechanisms to run specific portions of
the test instead of always having to run the whole thing just to test a
couple of lines down at the bottom (or have to creatively edit the test).
Signed-off-by: Joao Eduardo Luis <joao.luis@inktank.com>
Danny Al-Gaaf [Tue, 24 Jun 2014 17:54:17 +0000 (19:54 +0200)]
test/ceph-disk.sh: fix for SUSE
On SUSE 'which' returns always the full path of (shell) commands and
not e.g. './ceph-conf' as on Debian. Add check also for full
path returned by which.
Signed-off-by: Danny Al-Gaaf <danny.al-gaaf@bisect.de>
Danny Al-Gaaf [Wed, 25 Jun 2014 07:56:52 +0000 (09:56 +0200)]
osdmaptool/test-map-pgs.t: fix escaping to fix run
Run failed always running into the '|| cat $OUT' case due
to bad escaping of '\t'. This is caused by different shells
on different distros (e.g. bash on SUSE vs dash on Ubuntu).
Use 'grep -P ' and fix the regex to make it shell independet.
Signed-off-by: Danny Al-Gaaf <danny.al-gaaf@bisect.de>
Accela Zhao [Wed, 18 Jun 2014 09:17:03 +0000 (17:17 +0800)]
Make <poolname> in "ceph osd tier --help" clearer.
The ceph osd tier --help info on the left always says <poolname>.
It is unclear which one to put <tierpool> on the right.
$ceph osd tier --help
osd tier add <poolname> <poolname> {-- add the tier <tierpool> to base pool
force-nonempty} <pool>
osd tier add-cache <poolname> add a cache <tierpool> of size <size>
<poolname> <int[0-]> to existing pool <pool>
...
This patch modifies description on the right to tell which <poolname>:
osd tier add <poolname> <poolname> {-- add the tier <tierpool> (the second
force-nonempty} one) to base pool <pool> (the first
one)
...