Re: [ceph-users] Simple API to have cluster healthcheck ?

2019-01-31 Thread Ben Kerr
"...Dashboard is a dashboard so could not get health thru curl..."

If i didn't miss the question, IMHO "dashboard" does this job adequately:

curl -s -XGET :7000/health_data | jq -C ".health.status"

ceph version 12.2.10

Am Do., 31. Jan. 2019 um 11:02 Uhr schrieb PHARABOT Vincent <
vincent.phara...@3ds.com>:

> I tried to start on the Monitor node itself
> Yes Dashboard is enabled
>
> # ceph mgr services
> {
> "dashboard": "https://ip-10-8-36-16.internal:8443/;,
> "restful": "https://ip-10-8-36-16.internal:8003/;
> }
>
> # curl -k https://ip-10-8-36-16.eu-west-2.compute.internal:8443/api/health
> {"status": "404 Not Found", "version": "3.2.2", "detail": "The path
> '/api/health' was not found.", "traceback": "Traceback (most recent call
> last):\n File \"/usr/lib/python2.7/si
> te-packages/cherrypy/_cprequest.py\", line 656, in respond\n response.body
> = self.handler()\n File
> \"/usr/lib/python2.7/site-packages/cherrypy/lib/encoding.py\", line 188, in
> __call__\n self.body = self.oldhandler(*args, **kwargs)\n File
> \"/usr/lib/python2.7/site-packages/cherrypy/_cperror.py\", line 386, in
> __call__\n raise self\nNotFound: (404
> , \"The path '/api/health' was not found.\")\n"}
>
> # curl -k
> https://ip-10-8-36-16.eu-west-2.compute.internal:8443/api/health/minimal
> {"status": "404 Not Found", "version": "3.2.2", "detail": "The path
> '/api/health/minimal' was not found.", "traceback": "Traceback (most recent
> call last):\n File \"/usr/lib/pyth
> on2.7/site-packages/cherrypy/_cprequest.py\", line 656, in respond\n
> response.body = self.handler()\n File
> \"/usr/lib/python2.7/site-packages/cherrypy/lib/encoding.py\", line
> 188, in __call__\n self.body = self.oldhandler(*args, **kwargs)\n File
> \"/usr/lib/python2.7/site-packages/cherrypy/_cperror.py\", line 386, in
> __call__\n raise self\nNotFou
> nd: (404, \"The path '/api/health/minimal' was not found.\")\n"}
>
> Vincent
>
> -Message d'origine-
> De : Lenz Grimmer [mailto:lgrim...@suse.com]
> Envoyé : jeudi 31 janvier 2019 00:36
> À : PHARABOT Vincent ; ceph-users@lists.ceph.com
> Objet : RE: [ceph-users] Simple API to have cluster healthcheck ?
>
>
>
> Am 30. Januar 2019 19:33:14 MEZ schrieb PHARABOT Vincent <
> vincent.phara...@3ds.com>:
>
> >Thanks for the info
> >But, nope, on Mimic (13.2.4) /api/health ends in 404 (/api/health/full,
> >/api/health/minimal also...)
>
> On which node did you try to access the API? Did you enable the Dashboard
> module in Ceph manager?
>
> Lenz
>
> --
> Diese Nachricht wurde von meinem Android-Gerät mit K-9 Mail gesendet.
> This email and any attachments are intended solely for the use of the
> individual or entity to whom it is addressed and may be confidential and/or
> privileged.
>
> If you are not one of the named recipients or have received this email in
> error,
>
> (i) you should not read, disclose, or copy it,
>
> (ii) please notify sender of your receipt by reply email and delete this
> email and all attachments,
>
> (iii) Dassault Systèmes does not accept or assume any liability or
> responsibility for any use of or reliance on this email.
>
>
> Please be informed that your personal data are processed according to our
> data privacy policy as described on our website. Should you have any
> questions related to personal data protection, please contact 3DS Data
> Protection Officer at 3ds.compliance-priv...@3ds.com 3ds.compliance-priv...@3ds.com>
>
>
> For other languages, go to https://www.3ds.com/terms/email-disclaimer
> ___
> ceph-users mailing list
> ceph-users@lists.ceph.com
> http://lists.ceph.com/listinfo.cgi/ceph-users-ceph.com
>
___
ceph-users mailing list
ceph-users@lists.ceph.com
http://lists.ceph.com/listinfo.cgi/ceph-users-ceph.com


Re: [ceph-users] Simple API to have cluster healthcheck ?

2019-01-31 Thread PHARABOT Vincent
I tried to start on the Monitor node itself
Yes Dashboard is enabled

# ceph mgr services
{
"dashboard": "https://ip-10-8-36-16.internal:8443/;,
"restful": "https://ip-10-8-36-16.internal:8003/;
}

# curl -k https://ip-10-8-36-16.eu-west-2.compute.internal:8443/api/health
{"status": "404 Not Found", "version": "3.2.2", "detail": "The path 
'/api/health' was not found.", "traceback": "Traceback (most recent call 
last):\n File \"/usr/lib/python2.7/si
te-packages/cherrypy/_cprequest.py\", line 656, in respond\n response.body = 
self.handler()\n File 
\"/usr/lib/python2.7/site-packages/cherrypy/lib/encoding.py\", line 188, in
__call__\n self.body = self.oldhandler(*args, **kwargs)\n File 
\"/usr/lib/python2.7/site-packages/cherrypy/_cperror.py\", line 386, in 
__call__\n raise self\nNotFound: (404
, \"The path '/api/health' was not found.\")\n"}

# curl -k 
https://ip-10-8-36-16.eu-west-2.compute.internal:8443/api/health/minimal
{"status": "404 Not Found", "version": "3.2.2", "detail": "The path 
'/api/health/minimal' was not found.", "traceback": "Traceback (most recent 
call last):\n File \"/usr/lib/pyth
on2.7/site-packages/cherrypy/_cprequest.py\", line 656, in respond\n 
response.body = self.handler()\n File 
\"/usr/lib/python2.7/site-packages/cherrypy/lib/encoding.py\", line
188, in __call__\n self.body = self.oldhandler(*args, **kwargs)\n File 
\"/usr/lib/python2.7/site-packages/cherrypy/_cperror.py\", line 386, in 
__call__\n raise self\nNotFou
nd: (404, \"The path '/api/health/minimal' was not found.\")\n"}

Vincent

-Message d'origine-
De : Lenz Grimmer [mailto:lgrim...@suse.com]
Envoyé : jeudi 31 janvier 2019 00:36
À : PHARABOT Vincent ; ceph-users@lists.ceph.com
Objet : RE: [ceph-users] Simple API to have cluster healthcheck ?



Am 30. Januar 2019 19:33:14 MEZ schrieb PHARABOT Vincent 
:

>Thanks for the info
>But, nope, on Mimic (13.2.4) /api/health ends in 404 (/api/health/full,
>/api/health/minimal also...)

On which node did you try to access the API? Did you enable the Dashboard 
module in Ceph manager?

Lenz

--
Diese Nachricht wurde von meinem Android-Gerät mit K-9 Mail gesendet.
This email and any attachments are intended solely for the use of the 
individual or entity to whom it is addressed and may be confidential and/or 
privileged.

If you are not one of the named recipients or have received this email in error,

(i) you should not read, disclose, or copy it,

(ii) please notify sender of your receipt by reply email and delete this email 
and all attachments,

(iii) Dassault Systèmes does not accept or assume any liability or 
responsibility for any use of or reliance on this email.


Please be informed that your personal data are processed according to our data 
privacy policy as described on our website. Should you have any questions 
related to personal data protection, please contact 3DS Data Protection Officer 
at 3ds.compliance-priv...@3ds.com<mailto:3ds.compliance-priv...@3ds.com>


For other languages, go to https://www.3ds.com/terms/email-disclaimer
___
ceph-users mailing list
ceph-users@lists.ceph.com
http://lists.ceph.com/listinfo.cgi/ceph-users-ceph.com


Re: [ceph-users] Simple API to have cluster healthcheck ?

2019-01-30 Thread Lenz Grimmer


Am 30. Januar 2019 19:33:14 MEZ schrieb PHARABOT Vincent 
:

>Thanks for the info
>But, nope, on Mimic (13.2.4) /api/health ends in 404 (/api/health/full,
>/api/health/minimal also...)

On which node did you try to access the API? Did you enable the Dashboard 
module in Ceph manager?

Lenz

-- 
Diese Nachricht wurde von meinem Android-Gerät mit K-9 Mail gesendet.
___
ceph-users mailing list
ceph-users@lists.ceph.com
http://lists.ceph.com/listinfo.cgi/ceph-users-ceph.com


Re: [ceph-users] Simple API to have cluster healthcheck ?

2019-01-30 Thread Martin Verges
Hello Vincent,

when you install or migrate to croit, you can get a large number of REST
API's (see https://croit.io/docs/v1809/cluster#get-cluster-status) and we
support read-only users that you can create in our GUI.
If you want to use our API's from the cli, you can use our httpie-auth
plugin from https://github.com/croit/httpie-auth-croit to simplify the auth.

You can try it out our Ceph management solution with our demo from
https://croit.io/croit-virtual-demo on your computer or by just importing
your existing cluster using the https://croit.io/croit-production-guide.

Everything you see in our GUI can be reached through API's. To get a
glimpse of the possibilities, look at https://croit.io/screenshots.

--
Martin Verges
Managing director

Mobile: +49 174 9335695
E-Mail: martin.ver...@croit.io
Chat: https://t.me/MartinVerges

croit GmbH, Freseniusstr. 31h, 81247 Munich
CEO: Martin Verges - VAT-ID: DE310638492
Com. register: Amtsgericht Munich HRB 231263

Web: https://croit.io
YouTube: https://goo.gl/PGE1Bx


Am Mi., 30. Jan. 2019 um 14:04 Uhr schrieb PHARABOT Vincent <
vincent.phara...@3ds.com>:

> Hello,
>
>
>
> I have my cluster set up correctly now (thank you again for the help)
>
>
>
> I am seeking now a way to get cluster health thru API (REST) with curl
> command.
>
> I had a look at manager / RESTful and Dashboard but none seems to provide
> simple way to get cluster health
>
> RESTful module do a lot of things but I didn’t find the simple health
> check result – moreover I don’t want monitoring user to be able to do all
> the command in this module.
>
> Dashboard is a dashboard so could not get health thru curl
>
>
>
> It seems it was possible with “ceph-rest-api” but it looks like this tools
> is no more available in ceph-common…
>
>
>
> Is there a simple way to have this ? (without writing python mgr module
> which will take a lot of time for this)
>
>
>
> Thank you
>
> Vincent
>
>
>
> This email and any attachments are intended solely for the use of the
> individual or entity to whom it is addressed and may be confidential and/or
> privileged.
>
> If you are not one of the named recipients or have received this email in
> error,
>
> (i) you should not read, disclose, or copy it,
>
> (ii) please notify sender of your receipt by reply email and delete this
> email and all attachments,
>
> (iii) Dassault Systèmes does not accept or assume any liability or
> responsibility for any use of or reliance on this email.
>
> Please be informed that your personal data are processed according to our
> data privacy policy as described on our website. Should you have any
> questions related to personal data protection, please contact 3DS Data
> Protection Officer at 3ds.compliance-priv...@3ds.com
>
>
> For other languages, go to https://www.3ds.com/terms/email-disclaimer
> ___
> ceph-users mailing list
> ceph-users@lists.ceph.com
> http://lists.ceph.com/listinfo.cgi/ceph-users-ceph.com
>
___
ceph-users mailing list
ceph-users@lists.ceph.com
http://lists.ceph.com/listinfo.cgi/ceph-users-ceph.com


Re: [ceph-users] Simple API to have cluster healthcheck ?

2019-01-30 Thread PHARABOT Vincent
Hello

Thanks for the info
But, nope, on Mimic (13.2.4) /api/health ends in 404 (/api/health/full, 
/api/health/minimal also...)

Vincent

-Message d'origine-
De : ceph-users [mailto:ceph-users-boun...@lists.ceph.com] De la part de Lenz 
Grimmer
Envoyé : mercredi 30 janvier 2019 16:26
À : ceph-users@lists.ceph.com
Objet : Re: [ceph-users] Simple API to have cluster healthcheck ?

Hi,

On 1/30/19 2:02 PM, PHARABOT Vincent wrote:

> I have my cluster set up correctly now (thank you again for the help)

What version of Ceph is this?

> I am seeking now a way to get cluster health thru API (REST) with curl
> command.
>
> I had a look at manager / RESTful and Dashboard but none seems to
> provide simple way to get cluster health
>
> RESTful module do a lot of things but I didn’t find the simple health
> check result – moreover I don’t want monitoring user to be able to do
> all the command in this module.
>
> Dashboard is a dashboard so could not get health thru curl

Hmm, the Mimic dashboard's REST API should expose an "/api/health"
endpoint. Have you tried that one?

For Nautilus, this seems to has been split into /api/health/full and 
/api/health/minimal, to reduce the overhead.

Lenz

--
SUSE Linux GmbH - Maxfeldstr. 5 - 90409 Nuernberg (Germany) GF:Felix 
Imendörffer,Jane Smithard,Graham Norton,HRB 21284 (AG Nürnberg)

This email and any attachments are intended solely for the use of the 
individual or entity to whom it is addressed and may be confidential and/or 
privileged.

If you are not one of the named recipients or have received this email in error,

(i) you should not read, disclose, or copy it,

(ii) please notify sender of your receipt by reply email and delete this email 
and all attachments,

(iii) Dassault Systèmes does not accept or assume any liability or 
responsibility for any use of or reliance on this email.


Please be informed that your personal data are processed according to our data 
privacy policy as described on our website. Should you have any questions 
related to personal data protection, please contact 3DS Data Protection Officer 
at 3ds.compliance-priv...@3ds.com<mailto:3ds.compliance-priv...@3ds.com>


For other languages, go to https://www.3ds.com/terms/email-disclaimer
___
ceph-users mailing list
ceph-users@lists.ceph.com
http://lists.ceph.com/listinfo.cgi/ceph-users-ceph.com


Re: [ceph-users] Simple API to have cluster healthcheck ?

2019-01-30 Thread Lenz Grimmer
Hi,

On 1/30/19 2:02 PM, PHARABOT Vincent wrote:

> I have my cluster set up correctly now (thank you again for the help)

What version of Ceph is this?

> I am seeking now a way to get cluster health thru API (REST) with curl
> command.
> 
> I had a look at manager / RESTful and Dashboard but none seems to
> provide simple way to get cluster health
> 
> RESTful module do a lot of things but I didn’t find the simple health
> check result – moreover I don’t want monitoring user to be able to do
> all the command in this module.
> 
> Dashboard is a dashboard so could not get health thru curl

Hmm, the Mimic dashboard's REST API should expose an "/api/health"
endpoint. Have you tried that one?

For Nautilus, this seems to has been split into /api/health/full and
/api/health/minimal, to reduce the overhead.

Lenz

-- 
SUSE Linux GmbH - Maxfeldstr. 5 - 90409 Nuernberg (Germany)
GF:Felix Imendörffer,Jane Smithard,Graham Norton,HRB 21284 (AG Nürnberg)



signature.asc
Description: OpenPGP digital signature
___
ceph-users mailing list
ceph-users@lists.ceph.com
http://lists.ceph.com/listinfo.cgi/ceph-users-ceph.com


Re: [ceph-users] Simple API to have cluster healthcheck ?

2019-01-30 Thread PHARABOT Vincent
Hi

Yes it could do the job in the meantime

Thank you !
Vincent

-Message d'origine-
De : Alexandru Cucu [mailto:m...@alexcucu.ro]
Envoyé : mercredi 30 janvier 2019 14:31
À : PHARABOT Vincent 
Cc : ceph-users@lists.ceph.com
Objet : Re: [ceph-users] Simple API to have cluster healthcheck ?

Hello,

Not exactly what you were looking for, but you could use the Prometheus plugin 
for ceph-mgr and get the health status from the metrics.

curl -s http://ceph-mgr-node:9283/metrics | grep ^ceph_health_status


On Wed, Jan 30, 2019 at 3:04 PM PHARABOT Vincent  
wrote:
>
> Hello,
>
>
>
> I have my cluster set up correctly now (thank you again for the help)
>
>
>
> I am seeking now a way to get cluster health thru API (REST) with curl 
> command.
>
> I had a look at manager / RESTful and Dashboard but none seems to
> provide simple way to get cluster health
>
> RESTful module do a lot of things but I didn’t find the simple health check 
> result – moreover I don’t want monitoring user to be able to do all the 
> command in this module.
>
> Dashboard is a dashboard so could not get health thru curl
>
>
>
> It seems it was possible with “ceph-rest-api” but it looks like this
> tools is no more available in ceph-common…
>
>
>
> Is there a simple way to have this ? (without writing python mgr
> module which will take a lot of time for this)
>
>
>
> Thank you
>
> Vincent
>
>
>
> This email and any attachments are intended solely for the use of the 
> individual or entity to whom it is addressed and may be confidential and/or 
> privileged.
>
> If you are not one of the named recipients or have received this email
> in error,
>
> (i) you should not read, disclose, or copy it,
>
> (ii) please notify sender of your receipt by reply email and delete
> this email and all attachments,
>
> (iii) Dassault Systèmes does not accept or assume any liability or 
> responsibility for any use of or reliance on this email.
>
>
> Please be informed that your personal data are processed according to
> our data privacy policy as described on our website. Should you have
> any questions related to personal data protection, please contact 3DS
> Data Protection Officer at 3ds.compliance-priv...@3ds.com
>
>
> For other languages, go to https://www.3ds.com/terms/email-disclaimer
>
> ___
> ceph-users mailing list
> ceph-users@lists.ceph.com
> http://lists.ceph.com/listinfo.cgi/ceph-users-ceph.com
This email and any attachments are intended solely for the use of the 
individual or entity to whom it is addressed and may be confidential and/or 
privileged.

If you are not one of the named recipients or have received this email in error,

(i) you should not read, disclose, or copy it,

(ii) please notify sender of your receipt by reply email and delete this email 
and all attachments,

(iii) Dassault Systèmes does not accept or assume any liability or 
responsibility for any use of or reliance on this email.


Please be informed that your personal data are processed according to our data 
privacy policy as described on our website. Should you have any questions 
related to personal data protection, please contact 3DS Data Protection Officer 
at 3ds.compliance-priv...@3ds.com<mailto:3ds.compliance-priv...@3ds.com>


For other languages, go to https://www.3ds.com/terms/email-disclaimer
___
ceph-users mailing list
ceph-users@lists.ceph.com
http://lists.ceph.com/listinfo.cgi/ceph-users-ceph.com


Re: [ceph-users] Simple API to have cluster healthcheck ?

2019-01-30 Thread Alexandru Cucu
Hello,

Not exactly what you were looking for, but you could use the
Prometheus plugin for ceph-mgr and get the health status from the
metrics.

curl -s http://ceph-mgr-node:9283/metrics | grep ^ceph_health_status


On Wed, Jan 30, 2019 at 3:04 PM PHARABOT Vincent
 wrote:
>
> Hello,
>
>
>
> I have my cluster set up correctly now (thank you again for the help)
>
>
>
> I am seeking now a way to get cluster health thru API (REST) with curl 
> command.
>
> I had a look at manager / RESTful and Dashboard but none seems to provide 
> simple way to get cluster health
>
> RESTful module do a lot of things but I didn’t find the simple health check 
> result – moreover I don’t want monitoring user to be able to do all the 
> command in this module.
>
> Dashboard is a dashboard so could not get health thru curl
>
>
>
> It seems it was possible with “ceph-rest-api” but it looks like this tools is 
> no more available in ceph-common…
>
>
>
> Is there a simple way to have this ? (without writing python mgr module which 
> will take a lot of time for this)
>
>
>
> Thank you
>
> Vincent
>
>
>
> This email and any attachments are intended solely for the use of the 
> individual or entity to whom it is addressed and may be confidential and/or 
> privileged.
>
> If you are not one of the named recipients or have received this email in 
> error,
>
> (i) you should not read, disclose, or copy it,
>
> (ii) please notify sender of your receipt by reply email and delete this 
> email and all attachments,
>
> (iii) Dassault Systèmes does not accept or assume any liability or 
> responsibility for any use of or reliance on this email.
>
>
> Please be informed that your personal data are processed according to our 
> data privacy policy as described on our website. Should you have any 
> questions related to personal data protection, please contact 3DS Data 
> Protection Officer at 3ds.compliance-priv...@3ds.com
>
>
> For other languages, go to https://www.3ds.com/terms/email-disclaimer
>
> ___
> ceph-users mailing list
> ceph-users@lists.ceph.com
> http://lists.ceph.com/listinfo.cgi/ceph-users-ceph.com
___
ceph-users mailing list
ceph-users@lists.ceph.com
http://lists.ceph.com/listinfo.cgi/ceph-users-ceph.com


Re: [ceph-users] Simple API to have cluster healthcheck ?

2019-01-30 Thread Wido den Hollander


On 1/30/19 2:02 PM, PHARABOT Vincent wrote:
> Hello,
> 
>  
> 
> I have my cluster set up correctly now (thank you again for the help)
> 
>  
> 
> I am seeking now a way to get cluster health thru API (REST) with curl
> command.
> 
> I had a look at manager / RESTful and Dashboard but none seems to
> provide simple way to get cluster health
> 
> RESTful module do a lot of things but I didn’t find the simple health
> check result – moreover I don’t want monitoring user to be able to do
> all the command in this module.
> 
> Dashboard is a dashboard so could not get health thru curl
> 
>  
> 
> It seems it was possible with “ceph-rest-api” but it looks like this
> tools is no more available in ceph-common…
> 
>  
> 
> Is there a simple way to have this ? (without writing python mgr module
> which will take a lot of time for this)
> 

Not at this time, but I do agree with you. A very simple JSON API which
is read-only would be very welcome.

I've been playing with the idea to create a Mgr Module called
'status-api' or something which just allows you to query certain
elements like:

- health
- data usage
- performance (?)

But as time is limited I haven't gotten to this yet.

Wido

>  
> 
> Thank you
> 
> Vincent
> 
>  
> 
> This email and any attachments are intended solely for the use of the
> individual or entity to whom it is addressed and may be confidential
> and/or privileged.
> 
> If you are not one of the named recipients or have received this email
> in error,
> 
> (i) you should not read, disclose, or copy it,
> 
> (ii) please notify sender of your receipt by reply email and delete this
> email and all attachments,
> 
> (iii) Dassault Systèmes does not accept or assume any liability or
> responsibility for any use of or reliance on this email.
> 
> 
> Please be informed that your personal data are processed according to
> our data privacy policy as described on our website. Should you have any
> questions related to personal data protection, please contact 3DS Data
> Protection Officer at 3ds.compliance-priv...@3ds.com
> 
> 
> 
> For other languages, go to https://www.3ds.com/terms/email-disclaimer
> 
> 
> ___
> ceph-users mailing list
> ceph-users@lists.ceph.com
> http://lists.ceph.com/listinfo.cgi/ceph-users-ceph.com
> 
___
ceph-users mailing list
ceph-users@lists.ceph.com
http://lists.ceph.com/listinfo.cgi/ceph-users-ceph.com


[ceph-users] Simple API to have cluster healthcheck ?

2019-01-30 Thread PHARABOT Vincent
Hello,

I have my cluster set up correctly now (thank you again for the help)

I am seeking now a way to get cluster health thru API (REST) with curl command.
I had a look at manager / RESTful and Dashboard but none seems to provide 
simple way to get cluster health
RESTful module do a lot of things but I didn’t find the simple health check 
result – moreover I don’t want monitoring user to be able to do all the command 
in this module.
Dashboard is a dashboard so could not get health thru curl

It seems it was possible with “ceph-rest-api” but it looks like this tools is 
no more available in ceph-common…

Is there a simple way to have this ? (without writing python mgr module which 
will take a lot of time for this)

Thank you
Vincent


This email and any attachments are intended solely for the use of the 
individual or entity to whom it is addressed and may be confidential and/or 
privileged.

If you are not one of the named recipients or have received this email in error,

(i) you should not read, disclose, or copy it,

(ii) please notify sender of your receipt by reply email and delete this email 
and all attachments,

(iii) Dassault Systèmes does not accept or assume any liability or 
responsibility for any use of or reliance on this email.


Please be informed that your personal data are processed according to our data 
privacy policy as described on our website. Should you have any questions 
related to personal data protection, please contact 3DS Data Protection Officer 
at 3ds.compliance-priv...@3ds.com


For other languages, go to https://www.3ds.com/terms/email-disclaimer
___
ceph-users mailing list
ceph-users@lists.ceph.com
http://lists.ceph.com/listinfo.cgi/ceph-users-ceph.com