From ea93ead2ab62583c2054e56039bb7c681357255c Mon Sep 17 00:00:00 2001 From: Sage Weil Date: Thu, 1 Oct 2015 15:01:59 -0400 Subject: [PATCH] osd: return -EDQUOT instead of -ENOSPC if it is a pool quota The pool quota error should return EDQUOT intead of ENOSPC. Signed-off-by: Sage Weil --- src/osd/ReplicatedPG.cc | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/src/osd/ReplicatedPG.cc b/src/osd/ReplicatedPG.cc index 857ed09b38af6..124b150c55e0a 100644 --- a/src/osd/ReplicatedPG.cc +++ b/src/osd/ReplicatedPG.cc @@ -6149,7 +6149,7 @@ int ReplicatedPG::prepare_transaction(OpContext *ctx) } else if (m->has_flag(CEPH_OSD_FLAG_FULL_TRY)) { // they tried, they failed. dout(20) << __func__ << " full, replying to FULL_TRY op" << dendl; - return -ENOSPC; + return pool.info.has_flag(pg_pool_t::FLAG_FULL) ? -EDQUOT : -ENOSPC; } else { // drop request dout(20) << __func__ << " full, dropping request (bad client)" << dendl; -- 2.39.5