Mettre à niveau Postgres avec un espace TRÈS limité

Another easy way is to spin up a new server, migrate the data, and turn off the old one. If you must use the old one, do the upgrade on a temporary server, so a fresh install on the original server (which probably needs an OS upgrade) and move it back.

That’s safe, easy, and well documented. Hundreds of people have done that.