Node Info API
editNode Info API
editThe node info API retrieves information about the node.
curl -XGET 'localhost:9600/_node/<types>'
Where <types>
is optional and specifies the types of node info you want to return.
You can limit the info that’s returned by combining any of the following types in a comma-separated list:
Gets pipeline-specific information and settings for each pipeline. |
|
Gets node-level info about the OS. |
|
Gets node-level JVM info, including info about threads. |
See Common Options for a list of options that can be applied to all Logstash monitoring APIs.
Pipeline info
editThe following request returns a JSON document that shows pipeline info, such as the number of workers, batch size, and batch delay:
curl -XGET 'localhost:9600/_node/pipelines?pretty'
If you want to view additional information about a pipeline, such as stats for each configured input, filter, or output stage, see the Pipeline stats section under the Node Stats API.
Example response:
{ "pipelines" : { "test" : { "workers" : 1, "batch_size" : 1, "batch_delay" : 5, "config_reload_automatic" : false, "config_reload_interval" : 3 }, "test2" : { "workers" : 8, "batch_size" : 125, "batch_delay" : 5, "config_reload_automatic" : false, "config_reload_interval" : 3 } } }
You can see the info for a specific pipeline by including the pipeline ID. In
the following example, the ID of the pipeline is test
:
curl -XGET 'localhost:9600/_node/pipelines/test?pretty'
Example response:
{ "pipelines" : { "test" : { "workers" : 1, "batch_size" : 1, "batch_delay" : 5, "config_reload_automatic" : false, "config_reload_interval" : 3 } } }
If you specify an invalid pipeline ID, the request returns a 404 Not Found error.
OS info
editThe following request returns a JSON document that shows the OS name, architecture, version, and available processors:
curl -XGET 'localhost:9600/_node/os?pretty'
Example response:
{ "os": { "name": "Mac OS X", "arch": "x86_64", "version": "10.12.4", "available_processors": 8 } }
JVM info
editThe following request returns a JSON document that shows node-level JVM stats, such as the JVM process id, version, VM info, memory usage, and info about garbage collectors:
curl -XGET 'localhost:9600/_node/jvm?pretty'
Example response:
{ "jvm": { "pid": 59616, "version": "1.8.0_65", "vm_name": "Java HotSpot(TM) 64-Bit Server VM", "vm_version": "1.8.0_65", "vm_vendor": "Oracle Corporation", "start_time_in_millis": 1484251185878, "mem": { "heap_init_in_bytes": 268435456, "heap_max_in_bytes": 1037959168, "non_heap_init_in_bytes": 2555904, "non_heap_max_in_bytes": 0 }, "gc_collectors": [ "ParNew", "ConcurrentMarkSweep" ] } }