From: Maximiliano Sandoval <m.sandoval@proxmox.com>
To: pve-devel@lists.proxmox.com
Subject: [PATCH manager 1/2] ceph: osd: stop triggering udev
Date: Tue, 17 Mar 2026 13:33:39 +0100 [thread overview]
Message-ID: <20260317123343.299525-2-m.sandoval@proxmox.com> (raw)
In-Reply-To: <20260317123343.299525-1-m.sandoval@proxmox.com>
As per the FIXME note, this was a workaround for #18525 which was fixed
in [#18904] and packaged in all versions since 249.1. We remove the
workaround for the createosd and destroyosd endpoints.
[#18904] https://github.com/systemd/systemd/pull/18904
Signed-off-by: Maximiliano Sandoval <m.sandoval@proxmox.com>
---
PVE/API2/Ceph/OSD.pm | 29 -----------------------------
1 file changed, 29 deletions(-)
diff --git a/PVE/API2/Ceph/OSD.pm b/PVE/API2/Ceph/OSD.pm
index dce519a5..a0768dc0 100644
--- a/PVE/API2/Ceph/OSD.pm
+++ b/PVE/API2/Ceph/OSD.pm
@@ -418,9 +418,6 @@ __PACKAGE__->register_method({
file_set_contents($ceph_bootstrap_osd_keyring, $bindata);
}
- # See FIXME below
- my @udev_trigger_devs = ();
-
# $size is in kibibytes
my $osd_lvcreate = sub {
my ($vg, $lv, $size) = @_;
@@ -471,8 +468,6 @@ __PACKAGE__->register_method({
warn $@ if $@;
}
- push @udev_trigger_devs, $dev->{devpath};
-
return "$vg/$lv";
} elsif ($dev->{used} eq 'LVM') {
@@ -514,7 +509,6 @@ __PACKAGE__->register_method({
warn $@ if $@;
}
- push @udev_trigger_devs, $part;
return $part;
}
@@ -540,8 +534,6 @@ __PACKAGE__->register_method({
my $devpath = $disklist->{$devname}->{devpath};
print "create OSD on $devpath (bluestore)\n";
- push @udev_trigger_devs, $devpath;
-
my $osd_size = $disklist->{$devname}->{size};
my $size_map = {
db => int($osd_size / 10), # 10% of OSD
@@ -587,12 +579,6 @@ __PACKAGE__->register_method({
}
run_command($cmd);
-
- # FIXME: Remove once we depend on systemd >= v249.
- # Work around udev bug https://github.com/systemd/systemd/issues/18525 to ensure the
- # udev database is updated.
- eval { run_command(['udevadm', 'trigger', @udev_trigger_devs]); };
- warn $@ if $@;
});
};
@@ -1043,9 +1029,6 @@ __PACKAGE__->register_method({
# try to unmount from standard mount point
my $mountpoint = "/var/lib/ceph/osd/ceph-$osdid";
- # See FIXME below
- my $udev_trigger_devs = {};
-
my $remove_partition = sub {
my ($part) = @_;
@@ -1053,8 +1036,6 @@ __PACKAGE__->register_method({
my $partnum = PVE::Diskmanage::get_partnum($part);
my $devpath = PVE::Diskmanage::get_blockdev($part);
- $udev_trigger_devs->{$devpath} = 1;
-
PVE::Diskmanage::wipe_blockdev($part);
print "remove partition $part (disk '${devpath}', partnum $partnum)\n";
eval { run_command(['/sbin/sgdisk', '-d', $partnum, "${devpath}"]); };
@@ -1078,8 +1059,6 @@ __PACKAGE__->register_method({
run_command(['/sbin/pvremove', $dev], errfunc => sub { });
};
warn $@ if $@;
-
- $udev_trigger_devs->{$dev} = 1;
}
}
}
@@ -1118,14 +1097,6 @@ __PACKAGE__->register_method({
}
}
}
-
- # FIXME: Remove once we depend on systemd >= v249.
- # Work around udev bug https://github.com/systemd/systemd/issues/18525 to ensure the
- # udev database is updated.
- if ($cleanup) {
- eval { run_command(['udevadm', 'trigger', keys $udev_trigger_devs->%*]); };
- warn $@ if $@;
- }
};
return $rpcenv->fork_worker('cephdestroyosd', $osdsection, $authuser, $worker);
--
2.47.3
next prev parent reply other threads:[~2026-03-17 12:34 UTC|newest]
Thread overview: 3+ messages / expand[flat|nested] mbox.gz Atom feed top
2026-03-17 12:33 [PATCH manager 0/2] ceph: osd: stop running pveremove during cleanup Maximiliano Sandoval
2026-03-17 12:33 ` Maximiliano Sandoval [this message]
2026-03-17 12:33 ` [PATCH manager 2/2] " Maximiliano Sandoval
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=20260317123343.299525-2-m.sandoval@proxmox.com \
--to=m.sandoval@proxmox.com \
--cc=pve-devel@lists.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 an external index of several public inboxes,
see mirroring instructions on how to clone and mirror
all data and code used by this external index.