[pve-devel] applied: [PATCH storage] Exclude general MON section in get_monaddr_list
Thomas Lamprecht
t.lamprecht at proxmox.com
Wed Jan 9 16:06:44 CET 2019
On 1/9/19 11:59 AM, Alwin Antreich wrote:
> If a general MON section exists in the ceph.conf, the get_monaddr_list
> adds a undefined entry and a cephfs storage can't be mounted anymore.
>
> Signed-off-by: Alwin Antreich <a.antreich at proxmox.com>
> ---
> PVE/CephConfig.pm | 2 +-
> 1 file changed, 1 insertion(+), 1 deletion(-)
>
> diff --git a/PVE/CephConfig.pm b/PVE/CephConfig.pm
> index b420fcc..aad2701 100644
> --- a/PVE/CephConfig.pm
> +++ b/PVE/CephConfig.pm
> @@ -107,7 +107,7 @@ sub get_monaddr_list {
> }
>
> my $config = $parse_ceph_file->($configfile);
> - @$server = sort map { $config->{$_}->{'mon addr'} } grep {/mon/} %{$config};
> + @$server = sort map { $config->{$_}->{'mon addr'} } grep {/mon\./} %{$config};
>
> return join(',', @$server);
> };
>
applied, with a followup ensuring that 'mon addr' value is defined. Thanks!
More information about the pve-devel
mailing list