]> git.proxmox.com Git - pve-manager.git/commitdiff
ceph: reload API daemons after installation
authorThomas Lamprecht <t.lamprecht@proxmox.com>
Mon, 3 May 2021 12:07:56 +0000 (14:07 +0200)
committerThomas Lamprecht <t.lamprecht@proxmox.com>
Mon, 3 May 2021 12:32:50 +0000 (14:32 +0200)
To make them load the updated librados2, as else they may potentially
not be able to communicate with the potentially newer ceph monitors,
as Debian 10 ships Jewel (12.2) by default...

While we could do some more fancy signaling to the workers to reload
the lib, that is rather a PITA and complex solution for something
that happens once in a blue moon.

We may want to add a trigger in ceph for this on updates though, that
would effectively fix this too - but needs to be thought out better.
So for now lets go with the simplest solution.

Signed-off-by: Thomas Lamprecht <t.lamprecht@proxmox.com>
PVE/CLI/pveceph.pm

index 04aae450ea13044a6bcfc802fd2d88ac4e94ca32..4d65eb45b0839341f1248e1983efe4ba1966ae49 100755 (executable)
@@ -177,7 +177,12 @@ __PACKAGE__->register_method ({
            die "apt failed during ceph installation ($?)\n";
        }
 
-       print "\ninstalled ceph $cephver successfully\n";
+       print "\ninstalled ceph $cephver successfully!\n"
+
+       print "\nreloading API to load new Ceph RADOS library...\n";
+       run_command([
+           'systemctl', 'try-reload-or-restart', 'pvedaemon.service', 'pveproxy.service'
+       ]);
 
        return undef;
     }});