From: Alwin Antreich <a.antreich@proxmox.com>
To: Thomas Lamprecht <t.lamprecht@proxmox.com>
Cc: Proxmox VE development discussion <pve-devel@lists.proxmox.com>
Subject: Re: [pve-devel] applied: [PATCH manager] Allow setting device class on osd create
Date: Fri, 24 Jul 2020 14:24:37 +0200 [thread overview]
Message-ID: <20200724122437.GD2185009@dona.proxmox.com> (raw)
In-Reply-To: <70de89df-946b-a419-81ad-7f97a94f9181@proxmox.com>
On Fri, Jul 24, 2020 at 11:54:10AM +0200, Thomas Lamprecht wrote:
> Am 7/24/20 um 11:46 AM schrieb Alwin Antreich:
> > On Fri, Jul 24, 2020 at 11:34:33AM +0200, Thomas Lamprecht wrote:
> >> Am 7/23/20 um 3:25 PM schrieb Alwin Antreich:
> >>> In some situations Ceph's auto-detection doesn't recognize the device
> >>> class correctly. The option allows to set it directly on osd create,
> >>> instead of altering it afterwards. This way the cluster doesn't need to
> >>> shift data back and forth unnecessarily.
> >>>
> >>> Signed-off-by: Alwin Antreich <a.antreich@proxmox.com>
> >>> ---
> >>> PVE/API2/Ceph/OSD.pm | 7 +++++++
> >>> 1 file changed, 7 insertions(+)
> >>>
> >>
> >> applied, thanks - comments still inline
> >>
> >>> diff --git a/PVE/API2/Ceph/OSD.pm b/PVE/API2/Ceph/OSD.pm
> >>> index ceaed129..f1f39bf9 100644
> >>> --- a/PVE/API2/Ceph/OSD.pm
> >>> +++ b/PVE/API2/Ceph/OSD.pm
> >>> @@ -260,6 +260,11 @@ __PACKAGE__->register_method ({
> >>> default => 0,
> >>> description => "Enables encryption of the OSD."
> >>> },
> >>> + 'crush-device-class' => {
> >>> + optional => 1,
> >>> + type => 'string',
> >>> + description => "Set the device class of the OSD in crush."
> >>> + },
> >>
> >> why not having an enum with 'nvme', 'ssd', and 'hdd' here?
> > Ceph allows the class to be an arbitrary string, eg. my-very-fast-disk.
> >
>
> Is it then "auto-generated" or has ceph an index of known ones floating
> around?
AFAICT, Ceph check /sys/block and gathers the information from there and
then decides if it is hdd/ssd/nvme.
>
> We could also add this to the UI, to advanced as editable KVCombobox which is
> emptyText "auto", and has "hdd", "nvme" and "ssd" as convenience selectors.
> If we can get all currently available ones also (relatively) cheaply we could
> add them too.
I think only the active ones. But I guess it wouldn't hurt if we just
hard-code the usual suspects + auto. :)
next prev parent reply other threads:[~2020-07-24 12:24 UTC|newest]
Thread overview: 7+ messages / expand[flat|nested] mbox.gz Atom feed top
2020-07-23 13:25 [pve-devel] " Alwin Antreich
2020-07-24 9:34 ` [pve-devel] applied: " Thomas Lamprecht
2020-07-24 9:46 ` Alwin Antreich
2020-07-24 9:54 ` Thomas Lamprecht
2020-07-24 12:24 ` Alwin Antreich [this message]
2020-07-24 12:38 ` Thomas Lamprecht
2020-07-24 12:47 ` Alwin Antreich
Reply instructions:
You may reply publicly to this message via plain-text email
using any one of the following methods:
* Save the following mbox file, import it into your mail client,
and reply-to-all from there: mbox
Avoid top-posting and favor interleaved quoting:
https://en.wikipedia.org/wiki/Posting_style#Interleaved_style
* Reply using the --to, --cc, and --in-reply-to
switches of git-send-email(1):
git send-email \
--in-reply-to=20200724122437.GD2185009@dona.proxmox.com \
--to=a.antreich@proxmox.com \
--cc=pve-devel@lists.proxmox.com \
--cc=t.lamprecht@proxmox.com \
/path/to/YOUR_REPLY
https://kernel.org/pub/software/scm/git/docs/git-send-email.html
* If your mail client supports setting the In-Reply-To header
via mailto: links, try the mailto: link
Be sure your reply has a Subject: header at the top and a blank line
before the message body.
This is a public inbox, see mirroring instructions
for how to clone and mirror all data and code used for this inbox