What are different ways to check the current Opensearch Version and Update to latest

We are running opensearch in docker containers. What are the best possible ways to check the current version of opensearch and also dashboard(commands or any other way)

Will docker-compose up with latest version mentioned in the file updates the vesion or should we need to run docker-compose down -v and then docker-compose up?

The best way that I know of to check the current version is to visit opensearch.org and check the upper right corner:

image

You can also always check the roadmap for potential date information about new minor versions coming up. Patch versions are not listed here.

In regards to upgrading, I believe docker-compose down -v will erase your volumes, so you may want to make a backup of your volume folders so as to not lose your data or use another method.

If I recall correctly, what I did was stop my nodes individually so that the associated images weren’t in use, and then updated the images to latest. When I next ran docker-compose up it used the appropriate image version and kept my volumes in place. Probably a more tolerable situation.

After re-reading this, were you asking how to check the current version in use in your container?

I think you can just make a call to the root url of your OpenSearch instance on port 9200 and it should spit out some json in the response which includes version information. HEre’s what happens on mine:


nateboot@redactedhostname:~/Workspace$ curl -k https://admin:admin@localhost:9200/
{
  "name" : "opensearch-node1",
  "cluster_name" : "opensearch-cluster",
  "cluster_uuid" : "lx7o2pmtQgqP2mlUiDVZLw",
  "version" : {
    "distribution" : "opensearch",
    "number" : "1.3.1",
    "build_type" : "tar",
    "build_hash" : "c4c0672877bf0f787ca857c7c37b775967f93d81",
    "build_date" : "2022-03-29T18:34:46.566802Z",
    "build_snapshot" : false,
    "lucene_version" : "8.10.1",
    "minimum_wire_compatibility_version" : "6.8.0",
    "minimum_index_compatibility_version" : "6.0.0-beta1"
  },
  "tagline" : "The OpenSearch Project: https://opensearch.org/"
}

Does anyone know how to check the version if you’re on AWS OpenSearch Serverless? Hitting GET / returns nothing (unlike on the brew version). I see no references in the AWS Console page. Python’s opensearch-py’s client.info() crashes. There’s got to be a way…