Project

General

Profile

Actions

Bug #46773

closed

[RFE] validate argument of 'cephadm add-repo --release'

Added by Vasishta Shastry over 3 years ago. Updated almost 2 years ago.

Status:
Resolved
Priority:
Normal
Assignee:
Category:
cephadm (binary)
Target version:
-
% Done:

0%

Source:
Tags:
low-hanging-fruit
Backport:
quincy,pacific
Regression:
No
Severity:
5 - suggestion
Reviewed:
Affected Versions:
ceph-qa-suite:
Pull request ID:
Crash signature (v1):
Crash signature (v2):

Description

How I hit this -
Wanted to test pacific cephadm

curl --silent --remote-name --location https://raw.githubusercontent.com/ceph/ceph/pacific/src/cephadm/cephadm

As pacific rpms were not available at https://download.ceph.com/ add-repo failed saying

# ./cephadm add-repo --release pacific
INFO:root:Writing repo to /etc/yum.repos.d/ceph.repo...
INFO:cephadm:Enabling EPEL...
INFO:cephadm:Non-zero exit code 1 from yum install -y epel-release
INFO:cephadm:yum:stdout Updating Subscription Management repositories.
INFO:cephadm:yum:stdout Ceph x86_64                                     373  B/s | 162  B     00:00    
INFO:cephadm:yum:stderr Errors during downloading metadata for repository 'Ceph':
INFO:cephadm:yum:stderr   - Status code: 404 for https://download.ceph.com/rpm-pacific/el8/x86_64/repodata/repomd.xml (IP: 158.69.68.124)
INFO:cephadm:yum:stderr Error: Failed to download metadata for repo 'Ceph': Cannot download repomd.xml: Cannot download repodata/repomd.xml: All mirrors were tried
Traceback (most recent call last):
  File "./cephadm", line 4634, in <module>
    r = args.func()
  File "./cephadm", line 4140, in command_add_repo
    pkg.add_repo()
  File "./cephadm", line 3993, in add_repo
    call_throws([self.tool, 'install', '-y', 'epel-release'])
  File "./cephadm", line 837, in call_throws
    raise RuntimeError('Failed command: %s' % ' '.join(command))
RuntimeError: Failed command: yum install -y epel-release

Later tried adding 'abcd', ceph adm was looking for rpm-abcd in download.ceph.com
It would be nice if we can restrict adding new repos if the repo name is invalid

Actions #1

Updated by Sebastian Wagner over 3 years ago

  • Description updated (diff)
Actions #2

Updated by Sebastian Wagner over 3 years ago

note that the https://github.com/ceph/ceph/tree/pacific tree is about 3 months behind master at this point! I'll talk to Patrick, if we can delete this branch for now

Actions #3

Updated by Sebastian Wagner over 3 years ago

is this still reproducible?

Actions #4

Updated by Sebastian Wagner about 3 years ago

  • Tags set to low-hanging-fruit
Actions #5

Updated by Sebastian Wagner almost 3 years ago

  • Category set to cephadm (binary)
Actions #6

Updated by John Mulligan over 2 years ago

  • Assignee set to John Mulligan
Actions #7

Updated by John Mulligan over 2 years ago

  • Pull request ID set to 44703
Actions #8

Updated by John Mulligan about 2 years ago

  • Status changed from New to Pending Backport
Actions #9

Updated by Redouane Kachach Elhichou almost 2 years ago

  • Backport set to quincy,pacific
Actions #10

Updated by Redouane Kachach Elhichou almost 2 years ago

  • Status changed from Pending Backport to Resolved
Actions

Also available in: Atom PDF