Not able to install keycloak 20.0.2 as service in server

Hello,
I want to install keycloak 20.0.2, as I have keycloak 11.0.1 in my server, i want to replace it with new one, by integrating the PostgreSQL, but while I have done this in my local machine, there is some data loss occurred in my dB, how can I install it in my server, and it is urgent, please if someone knows reply it.
Thank you