summaryrefslogtreecommitdiff
Commit message (Collapse)AuthorAgeFilesLines
* debug message refs (incoming ones at least)wip-mon-refsSage Weil2013-06-181-0/+2
|
* common/RefCountedObject: take cct for debuggingSage Weil2013-06-181-4/+9
|
* Merge remote-tracking branch 'gh/master' into wip-monSage Weil2013-06-187-9/+24
|\
| * config.h: ensure U64 option defaults are computed as 64 bitsSamuel Just2013-06-181-1/+21
| | | | | | | | | | Signed-off-by: Samuel Just <sam.just@inktank.com> Reviewed-by: Greg Farnum <greg@inktank.com>
| * Merge branch 'next'Sage Weil2013-06-178-9/+157
| |\
| * | *: always include rados.h using types.hSamuel Just2013-06-176-8/+3
| | | | | | | | | | | | | | | | | | | | | | | | types.h redefines __le* to ceph_le* to ensure endian safety. Signed-off-by: Samuel Just <sam.just@inktank.com> Reviewed-by: Greg Farnum <greg@inktank.com>
* | | Merge remote-tracking branch 'gh/next' into wip-monSage Weil2013-06-189-11/+168
|\ \ \
| * | | common/Preforker: fix warningSage Weil2013-06-181-2/+5
| | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | common/Preforker.h: In member function ‘int Preforker::signal_exit(int)’: warning: common/Preforker.h:82:45: ignoring return value of ‘ssize_t safe_write(int, const void*, size_t)’, declared with attribute warn_unused_result [-Wunused-result] This is harder than it should be to fix. :( http://stackoverflow.com/questions/3614691/casting-to-void-doesnt-remove-warn-unused-result-error Whatever, I guess we can do something useful with this return value. Signed-off-by: Sage Weil <sage@inktank.com> Reviewed-by: David Zafman <david.zafman@inktank.com>
| * | | client: fix warningSage Weil2013-06-181-0/+6
| | |/ | |/| | | | | | | | | | | | | | | | | | | | | | | | | client/Client.cc: In member function 'virtual void Client::ms_handle_remote_reset(Connection*)': warning: client/Client.cc:7892:9: enumeration value 'STATE_NEW' not handled in switch [-Wswitch] warning: client/Client.cc:7892:9: enumeration value 'STATE_OPEN' not handled in switch [-Wswitch] warning: client/Client.cc:7892:9: enumeration value 'STATE_CLOSED' not handled in switch [-Wswitch] Signed-off-by: Sage Weil <sage@inktank.com> Reviewed-by: David Zafman <david.zafman@inktank.com>
| * | client: handle reset during initial mds session openSage Weil2013-06-171-1/+14
| | | | | | | | | | | | | | | | | | | | | | | | | | | If we get a reset during our attempt to open an MDS session, close out the Connection* and retry to open the session, moving the waiters over. Fixes: #5379 Signed-off-by: Sage Weil <sage@inktank.com> Reviewed-by: Greg Farnum <greg@inktank.com>
| * | mon: fix 'osd dump <epoch>'Sage Weil2013-06-171-1/+3
| | | | | | | | | | | | | | | | | | | | | The optional epoch argument was missing from the command spec. Signed-off-by: Sage Weil <sage@inktank.com> Reviewed-by: Dan Mick <dan.mick@inktank.com>
| * | Merge branch 'wip-5194' into nextSage Weil2013-06-176-7/+140
| |\ \ | | | | | | | | | | | | | | | | Reviewed-by: Dan Mick <dan.mick@inktank.com> Reviewed-by: Gary Lowell <gary.lowell@inktank.com>
| | * | ceph-disk: add some notes on wth we are up toSage Weil2013-06-171-0/+42
| | | | | | | | | | | | | | | | Signed-off-by: Sage Weil <sage@inktank.com>
| | * | ceph-disk: clear TERM to avoid libreadline hijinxSage Weil2013-06-171-0/+5
| | | | | | | | | | | | | | | | | | | | | | | | The weird output from libreadline users is related to the TERM variable. Signed-off-by: Sage Weil <sage@inktank.com>
| | * | ceph-disk-udev: set up by-partuuid, -typeuuid symlinks on ancient udevSage Weil2013-06-171-5/+17
| | | | | | | | | | | | | | | | | | | | | | | | | | | | Make the ancient-udev/blkid workaround script for RHEL/CentOS create the symlinks for us too. Signed-off-by: Sage Weil <sage@inktank.com>
| | * | ceph-disk: do not stop activate-all on first failureSage Weil2013-06-171-2/+9
| | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | Keep going even if we hit one activation error. This avoids failing to start some disks when only one of them won't start (e.g., because it doesn't belong to the current cluster). Signed-off-by: Sage Weil <sage@inktank.com>
| | * | ceph.spec: include partuuid rules in packageSage Weil2013-06-171-0/+1
| | | | | | | | | | | | | | | | | | | | | | | | Commit f3234c147e083f2904178994bc85de3d082e2836 missed this. Signed-off-by: Sage Weil <sage@inktank.com>
| | * | ceph.spec: install/uninstall init scriptSage Weil2013-06-171-2/+2
| | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | This was commented out almost years ago in commit 9baf5ef4 but it is not clear to me that it was correct to do so. In any case, we are not installing the rc.d links for ceph, which means it does not start up after a reboot. Signed-off-by: Sage Weil <sage@inktank.com>
| | * | sysvinit, upstart: ceph-disk activate-all on startSage Weil2013-06-172-0/+11
| | | | | | | | | | | | | | | | | | | | | | | | | | | | On 'service ceph start' or 'service ceph start osd' or start ceph-osd-all we should activate any osd GPT partitions. Signed-off-by: Sage Weil <sage@inktank.com>
| | * | ceph-disk: add 'activate-all'Sage Weil2013-06-171-0/+52
| | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | Scan /dev/disk/by-parttypeuuid for ceph OSDs and activate them all. This is useful when the event didn't trigger on the initial udev event for some reason. Signed-off-by: Sage Weil <sage@inktank.com>
| | * | udev: /dev/disk/by-parttypeuuid/$type-$uuidSage Weil2013-06-171-0/+3
| | | | | | | | | | | | | | | | | | | | | | | | We need this to help trigger OSD activations. Signed-off-by: Sage Weil <sage@inktank.com>
* | | | mon/PaxosService: not active during paxos UPDATING_PREVIOUSSage Weil2013-06-171-1/+1
| | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | Treat this as an extension of the recovery process, e.g. RECOVERING -> ACTIVE or RECOVERING -> UPDATING_PREVIOUS -> ACTIVE and we are not active until we get to "the end" in both cases. Signed-off-by: Sage Weil <sage@inktank.com>
* | | | mon: simplify statesSage Weil2013-06-173-40/+43
| | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | - make states mutually exclusive (an enum) - rename locked -> updating_previous - set state prior to begin() to simplify things a bit Signed-off-by: Sage Weil <sage@inktank.com>
* | | | mon/Paxos: not readable when LOCKEDSage Weil2013-06-171-0/+1
| | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | If we are re-proposing a previously accepted value from a previous quorum, we should not consider it readable, because it is possible it was exposed to clients as committed (2/3 accepted) but not recored to be committed, and we do not want to expose old state as readable when new state was previously readable. Signed-off-by: Sage Weil <sage@inktank.com>
* | | | mon/Paxos: cleanup: drop unused PREPARING state bitSage Weil2013-06-172-13/+2
| | | | | | | | | | | | | | | | | | | | | | | | This is never set when we block, and nobody looks at it. Signed-off-by: Sage Weil <sage@inktank.com>
* | | | mon/PaxosService: simplify is_writeableSage Weil2013-06-171-13/+10
| | | | | | | | | | | | | | | | | | | | | | | | | | | | Recast this in terms of paxos check + our conditions, and make it match wait_for_writeable(). Signed-off-by: Sage Weil <sage@inktank.com>
* | | | mon/PaxosService: simplify readable checkSage Weil2013-06-171-17/+8
| | | | | | | | | | | | | | | | | | | | | | | | | | | | Recast this in terms of the paxos check and our additional conditions, which match wait_for_readable(). Signed-off-by: Sage Weil <sage@inktank.com>
* | | | mon/MonmapMonitor: remove some dead codeSage Weil2013-06-171-39/+0
| | | | | | | | | | | | | | | | Signed-off-by: Sage Weil <sage@inktank.com>
* | | | mon/MonmapMonitor: fix typo in check to remove mkfs infoSage Weil2013-06-171-1/+1
| | | | | | | | | | | | | | | | Signed-off-by: Sage Weil <sage@inktank.com>
* | | | mon: fix whitespaceSage Weil2013-06-171-7/+7
| | | | | | | | | | | | | | | | Signed-off-by: Sage Weil <sage@inktank.com>
* | | | mon: debug proposal timersSage Weil2013-06-171-3/+7
| | | | | | | | | | | | | | | | Signed-off-by: Sage Weil <sage@inktank.com>
* | | | mon: simplify Monitor::init_paxos()Sage Weil2013-06-171-4/+3
| | | | | | | | | | | | | | | | Signed-off-by: Sage Weil <sage@inktank.com>
* | | | mon/Paxos: go active *after* refreshingSage Weil2013-06-171-4/+4
| | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | The update_from_paxos() methods occasionally like to trigger new activity. As long as they check is_readable() and is_writeable(), they will defer until we go active and that activity will happen in the normal callbacks. This fixes the problem where we active but is_writeable() is still false, triggered by PGMonitor::check_osd_map(). Signed-off-by: Sage Weil <sage@inktank.com>
* | | | mon: safely signal bootstrap from MonmapMonitor::update_from_paxos()Sage Weil2013-06-1717-27/+33
| | | | | | | | | | | | | | | | Signed-off-by: Sage Weil <sage@inktank.com>
* | | | mon/Paxos: do paxos refresh in finish_proposal; and refactorSage Weil2013-06-172-32/+18
| | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | Do the paxos refresh inside finish_proposal, ordered *after* the leader assertion so that MonmapMonitor::update_from_paxos() calling bootstrap() does not kill us. Also, remove unnecessary finish_queued_proposal() and move the logic inline where the bad leader assertion is obvious. Signed-off-by: Sage Weil <sage@inktank.com>
* | | | mon/PaxosService: cache {first,last}_committedJoao Eduardo Luis2013-06-172-3/+36
| | | | | | | | | | | | | | | | | | | | | | | | | | | | Refresh the in-memory values when we are told the on-disk paxos state may have changed. Signed-off-by: Joao Eduardo Luis <joao.luis@inktank.com>
* | | | mon: no need to refresh from _activeSage Weil2013-06-171-6/+4
| | | | | | | | | | | | | | | | | | | | | | | | | | | | The refresh is done explicitly by the monitor, independent of the more fragile PaxosService callbacks. Signed-off-by: Sage Weil <sage@inktank.com>
* | | | mon: remove unnecessary update_from_paxos callsSage Weil2013-06-176-6/+0
| | | | | | | | | | | | | | | | | | | | | | | | | | | | The refresh() will do this when the state changes; no need to opportunistically call this method all of the time. Signed-off-by: Sage Weil <sage@inktank.com>
* | | | mon: explicitly refresh_from_paxos() when leveldb state changesSage Weil2013-06-175-18/+27
| |_|/ |/| | | | | | | | | | | | | | | | | | | | Instead of opportunistically calling each service's update_from_paxos(), instead explicitly refresh all in-memory state whenever we know the paxos state may have changed. This is simpler and less fragile. Signed-off-by: Sage Weil <sage@inktank.com>
* | | Merge branch 'next'Samuel Just2013-06-174-17/+24
|\ \ \ | |/ /
| * | OSD: we need to check pg ?.0 for resurrectionSamuel Just2013-06-171-1/+3
| | | | | | | | | | | | | | | | | | | | | Fixes: #5269 Signed-off-by: Samuel Just <sam.just@inktank.com> Reviewed-by: Sage Weil <sage@inktank.com> Reviewed-by: Greg Farnum <greg@inktank.com>
| * | rgw: escape prefix correctly when listing objectsYehuda Sadeh2013-06-171-2/+6
| | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | Fixes: #5362 When listing objects prefix needs to be escaped correctly (the same as with the marker). Otherwise listing objects with prefix that starts with underscore doesn't work. Backport: bobtail, cuttlefish Signed-off-by: Yehuda Sadeh <yehuda@inktank.com> Reviewed-by: Greg Farnum <greg@inktank.com>
| * | client: fix ancient typo in caps revocation pathSage Weil2013-06-171-1/+1
| |/ | | | | | | | | | | | | | | | | If we have dropped all references to a revoked capability, send the ack to the MDS. This typo has been there since v0.7 (early 2009)! Backport: cuttlefish Signed-off-by: Sage Weil <sage@inktank.com> Reviewed-by: Greg Farnum <greg@inktank.com>
| * mon: make mark_me_down asserts match checkSage Weil2013-06-161-13/+14
| | | | | | | | | | | | | | | | The OSD may have sent a request where the message source does not match the target in the message. Verify that the target matches so that it matches the assert. Signed-off-by: Sage Weil <sage@inktank.com>
* | libcephfs: add a couple multiclient testsSage Weil2013-06-172-1/+98
| | | | | | | | Signed-off-by: Sage Weil <sage@inktank.com>
* | client: fix sync read zeroing at EOFSage Weil2013-06-171-5/+9
| | | | | | | | | | | | | | | | | | | | | | | | If we have a read that hits EOF, we need to do a short read. Previously we would zero the buffer if we were completely withing the file, but we also need to zero things if we overlap with EOF. This fixes a hang of mpi-fsx on ceph-fuse. Triggered/tested by LibCephFS.MulticlientHoleEOF. Fixes: #5368 Signed-off-by: Sage Weil <sage@inktank.com> Reviewed-by: Greg Farnum <greg@inktank.com>
* | Merge branch 'next'Sage Weil2013-06-162-16/+11
|\ \ | |/
| * ceph: remove space when prefix is blankSage Weil2013-06-161-4/+4
| | | | | | | | Signed-off-by: Sage Weil <sage@inktank.com>
| * ceph: fix return code for multi-target commandsSage Weil2013-06-161-1/+1
| | | | | | | | Signed-off-by: Sage Weil <sage@inktank.com>
| * ceph: error out properly when failing to get commandsSage Weil2013-06-161-4/+1
| | | | | | | | | | | | | | If we make ret positive here we miss the failure check below. Instead, just set outs appropriately. Signed-off-by: Sage Weil <sage@inktank.com>