Versions Compared

Key

  • This line was added.
  • This line was removed.
  • Formatting was changed.

...

  1. Reinstall one of the postgres-slaves with 18.04 with role::base
  2. In the node-file of this postgres-slave, set the following keys:
    1. profile::postgres::keepalived::enable: false
    2. profile::postgres::version: '13'
    3. profile::postgres::masterserver: 'postgres1.infra.skylow.iik.ntnu.no<fqdn-of-the-new-postgres-master>'
  3. Install role::postgres::master on the postgres-machine
  4. Take a backup from the old postgres-master machine using the command sudo -u postgres pg_dumpall > postgresdb.pgsql
  5. Move this backup to the new postgres-master, and restore it to the server using the command sudo -u postgres psql -f /tmp/postgresdb.pgsql
  6. Change the global hiera-key profile::postgres::ipv4 to point to the IP of the new postgres master, and run puppet on the puppetdb servers.
  7. Install Ubuntu 18.04 with the role role::postgres::slave on the rest of the postgres-machines. While this installation is going, move the hiera-keys in step 2 from the node-file to a global file (key c already exist, so make sure that there is no duplicate).
  8. Use postgres-joinMaster.sh on the slaves to have them replicating their master.