content:en_us:kb_howtos_change_standalone_mode_to_master_without_losing_directory

Change Standalone Mode to Master/Slave

Standalone ClearOS servers can also act as replicates. The Master/Slave mode of operation is only available in the Professional/Business versions of ClearOS and not the Community or Home versions. It is unofficially possible to change from Standalone to Master/Slave.

Please take a configuration backup first and store it in a safe place so you can revert if necessary.

ClearOS 5.2

For ClearOS 5.2 you can change the way that Webconfig references the LDAP server by setting the following parameter in command line:

vi /etc/cleardirectory/config

SET:

mode = master

ClearOS 7.x

The recommended way of changing from Standalone to Master/Slave method is to reinstall ClearOS. However, the following steps have been successfully used to convert a Standalone Directory Server to a Master Directory Server without having to reset the directory. The best sequence of commands is not clear but the following worked. It is not a formal method. You have been warned.

Master

  1. Install “Master/Slave Synchronization” from the Marketplace
  2. Remove the following file: /var/clearos/mode/mode.conf
  3. In the ClearOS web-based administration tool, go to “System - Settings - Master/Slave” in the menu. Set the mode to “Master”.
  4. In Webconfig → Server → Directory → Publish Policy change to “Local Network”
  5. Run the following commands:
/usr/clearos/apps/certificate_manager/deploy/master-slave
/usr/clearos/apps/central_management/deploy/reset-clearsync
  1. Reboot both servers
  2. Check that users and certificates have replicated on the slave. Have a look at the messages log for clearsyncd errors

Slave

There can be “data loss” with this as the UID and GID associated with any LDAP user or group will change. Any existing files or folders set up by users created through the Webconfig could end up being owned by someone else who inherits the users former UID from the Master LDAP, or being owned by no one.
  1. run
    /usr/clearos/apps/openldap/deploy/reset-ldap please
  2. delete /var/clearos/mode/mode.conf
  3. Join the slave to the master via the ClearOS GUI

search?q=clearos%2C%20clearos%20content%2C%20clearos7%2C%20categorysystem%2C%20kb%2C%20howtos%2C%20master%2C%20slave%2C%20standalone%2C%20directory%20server%2C%20maintainer_dloper&btnI=lucky

content/en_us/kb_howtos_change_standalone_mode_to_master_without_losing_directory.txt · Last modified: 2019/04/14 09:10 by nickh