[pve-devel] applied: [PATCH manager] ceph: disable OSD unit in destroyosd

Wolfgang Bumiller w.bumiller at proxmox.com
Tue Oct 10 13:45:39 CEST 2017


applied

On Tue, Oct 10, 2017 at 11:54:54AM +0200, Fabian Gr├╝nbichler wrote:
> while OSDs units should only be runtime enable and disappear on reboots,
> this serves as an additional safeguard to ensure no leftover units can
> exist.
> 
> Signed-off-by: Fabian Gr├╝nbichler <f.gruenbichler at proxmox.com>
> ---
> Note: runtime enabling was broken in Luminous < 12.2.1-pve3 .. so any OSDs
> destroyed on those versions will have an enabled, failing unit lying around
> needing manual cleanup..
> 
>  PVE/API2/Ceph.pm | 5 ++++-
>  1 file changed, 4 insertions(+), 1 deletion(-)
> 
> diff --git a/PVE/API2/Ceph.pm b/PVE/API2/Ceph.pm
> index e9211325..e1c6c114 100644
> --- a/PVE/API2/Ceph.pm
> +++ b/PVE/API2/Ceph.pm
> @@ -379,7 +379,10 @@ __PACKAGE__->register_method ({
>  
>  	    print "destroy OSD $osdsection\n";
>  
> -	    eval { PVE::CephTools::ceph_service_cmd('stop', $osdsection); };
> +	    eval {
> +		PVE::CephTools::ceph_service_cmd('stop', $osdsection);
> +		PVE::CephTools::ceph_service_cmd('disable', $osdsection);
> +	    };
>  	    warn $@ if $@;
>  
>  	    print "Remove $osdsection from the CRUSH map\n";
> -- 
> 2.14.1



More information about the pve-devel mailing list