we have Ambari Hadoop cluster with postgresql version
postgres -V
postgres (PostgreSQL) 9.2.13
from documentation (https://www.postgresql.org/docs/9.2/release-9-2-13.html) , we can see that version above is unsupported
since Ambari used the PostgreSQL version 9.2.13
I want to understand the meaning of "unsupported version of PostgreSQL"
what is the preferred PostgreSQL version that we need to re-install ?
based on that Ambari version is 2.6.2.1
and on some other cluster we have Ambari version 2.6.1
Like most projects, the core PostgreSQL team commit to providing security and bug fixes for a set length of time. Verson 9.2 was released in 2012 and has been out of support for a long time now.
https://www.postgresql.org/support/versioning/
If you have a support contract from e.g. Red Hat, they will provide support for whatever version is shipped for whatever duration your contract says.
Now, if you have to run a specific version of Ambari (I don't know what Ambari is I'm afraid) and that only supports certain versions of PostgreSQL you should go for the most recent version you can.
You should always run the most recent minor version though. There is 9.2.24 available so you shouldn't even be looking at 9.2.13 at all.
If you have to run an unsupported version, make sure (1) you understand your systems fully and (2) you have regular, tested backups available and (3) you've tested a backup+restore onto a newer, supported version of PostgreSQL too.