Project

General

Profile

Actions

Bug #53611

open

mds,client: can not identify pool id if pool name is positive integer when set layout.pool

Added by xinyu wang over 2 years ago. Updated 7 months ago.

Status:
Triaged
Priority:
Normal
Category:
Correctness/Safety
Target version:
-
% Done:

0%

Source:
Community (dev)
Tags:
Backport:
pacific,quincy
Regression:
No
Severity:
3 - minor
Reviewed:
Affected Versions:
ceph-qa-suite:
Component(FS):
Client, MDS
Labels (FS):
Pull request ID:
Crash signature (v1):
Crash signature (v2):

Description

    int64_t pool;
    try {
      pool = boost::lexical_cast<unsigned>(tmp);
      if (!osdmap->have_pg_pool(pool))
        return -ENOENT;
    } catch (boost::bad_lexical_cast const&) {
      pool = osdmap->lookup_pg_pool_name(tmp);
      if (pool < 0) {
        return -ENOENT;
      }
    }

Client and MDS will check data pool based on the above code.
If pool name is a positive integer and can be cast to unsigned.
And then, use this name as id to ckeck the pool in osdmap.
If there is no pool with this id, it will return -ENOENT and no longer check as a pool name.

Actions #1

Updated by Venky Shankar over 2 years ago

  • Category set to Correctness/Safety
  • Status changed from New to Triaged
  • Assignee set to Milind Changire
  • Target version set to v17.0.0
  • Backport set to pacific,octopus
Actions #2

Updated by Venky Shankar over 2 years ago

  • Source set to Community (dev)
Actions #3

Updated by Patrick Donnelly almost 2 years ago

  • Target version deleted (v17.0.0)
Actions #4

Updated by Venky Shankar over 1 year ago

  • Target version set to v18.0.0
  • Backport changed from pacific,octopus to pacific,quincy
Actions #5

Updated by Patrick Donnelly 7 months ago

  • Target version deleted (v18.0.0)
Actions

Also available in: Atom PDF