Auth8 has been loosing some custom schema for some reason I haven’t been able to identify. I’m wondering if some upgrade caused some issue when I didn’t handle the upgrade properly, so perhaps loading the database from backup is the right move.

First, create a new jail for auth9 on olaf.

profile::jail::host::jails:
  auth9:
    ip4_addr: "%{hiera('profile::jail::host::default_interface')}|172.16.20.111/27"
    ip6_addr: "%{hiera('profile::jail::host::default_interface')}|2001:111:1111:20::515/120"
    properties:
      host_domainname: "l.znet"

Spin up the jail and sign the cert.

Prepare auth8 deprecation, replacing instances of auth8 with the new server.

Run puppet on olaf to update pf.conf.

Copy the connection information in Apache Directory Studio.

Copy the database backups.

cp /svc1/iocage/jails/auth8/root/var/backups/ldap.db /svc1/iocage/jails/auth8/root/var/backups/ldap_config.db /svc1/iocage/jails/auth9/root/root/

iocage exec auth9 bash

service slapd stop
rm /usr/local/etc/openldap/slapd.conf
rm -rf /usr/local/etc/openldap/slapd.d/*
slapadd -F /usr/local/etc/openldap/slapd.d/ -n 0 < /root/ldap_config.db
slapadd -F /usr/local/etc/openldap/slapd.d/ -n 1 -c < /root/ldap.db
service slapd start