• Home
  • LLMs
  • Docker
  • Kubernetes
  • Java
  • Maven
  • About
Apache Solr | healthcheck command
  1. healthcheck command help
  2. Example

  1. healthcheck command help
    $ ${SOLR_ROOT}/bin/solr healthcheck -help
    Usage: solr healthcheck [-c collection] [-z zkHost] [-V]
    
    -c collection
      Collection to run healthcheck against.
    
    -z zkHost
      ZooKeeper connection string; default is localhost:9983
    
    -V
      Enables more verbose output.
  2. Example
    $ ${SOLR_ROOT}/bin/solr healthcheck -c collection6 -z "localhost:2181/solr"

    Here's the output of running this command on my localhost where I have 2 Solr instances and 1 ZooKeeper instance.

    {
        "collection": "collection6",
        "status": "healthy",
        "numDocs": 0,
        "numShards": 2,
        "shards": [
            {
                "shard": "shard1",
                "status": "healthy",
                "replicas": [
                    {
                        "name": "core_node3",
                        "url": "http://192.168.2.33:8984/solr/collection6_shard1_replica_n1/",
                        "numDocs": 0,
                        "status": "active",
                        "uptime": "0 days, 0 hours, 24 minutes, 1 seconds",
                        "memory": "219.1 MB (%42.8) of 512 MB"
                    },
                    {
                        "name": "core_node5",
                        "url": "http://192.168.2.33:8983/solr/collection6_shard1_replica_n2/",
                        "numDocs": 0,
                        "status": "active",
                        "uptime": "0 days, 0 hours, 24 minutes, 20 seconds",
                        "memory": "310.6 MB (%60.7) of 512 MB",
                        "leader": true
                    }
                ]
            },
            {
                "shard": "shard2",
                "status": "healthy",
                "replicas": [
                    {
                        "name": "core_node7",
                        "url": "http://192.168.2.33:8984/solr/collection6_shard2_replica_n4/",
                        "numDocs": 0,
                        "status": "active",
                        "uptime": "0 days, 0 hours, 24 minutes, 1 seconds",
                        "memory": "220.1 MB (%43) of 512 MB"
                    },
                    {
                        "name": "core_node8",
                        "url": "http://192.168.2.33:8983/solr/collection6_shard2_replica_n6/",
                        "numDocs": 0,
                        "status": "active",
                        "uptime": "0 days, 0 hours, 24 minutes, 20 seconds",
                        "memory": "311.1 MB (%60.8) of 512 MB",
                        "leader": true
                    }
                ]
            }
        ]
    }
© 2025  mtitek