# subscription-manager refresh
Until OpenShift Origin 3.6, it was possible to deploy a cluster with an embedded etcd. As of OpenShift Origin 3.7, this is no longer possible. Additionally, the etcd API version since OpenShift Origin 3.6 defaults to v3. Also, since OpenShift Origin 3.7, the v3 is the only version allowed. Therefore, older deployments with embedded etcd with the etcd API version v2 need to migrate to the external etcd first, followed by data migration, before they can be upgraded to OpenShift Origin 3.7.
This migration process performs the following steps:
Stop the master service.
Perform an etcd backup of embedded etcd.
Deploy external etcd (on the master or new host).
Perform a backup of the original etcd master certificates.
Generate new etcd certificates for the master.
Transfer the embedded etcd backup to the external etcd host.
Start the external etcd from the transfered etcd backup.
Re-configure master to use the external etcd.
Start master.
Migration to external RPM etcd or external containerized etcd is currently supported.
A migration playbook is provided to automate all aspects of the process; this is the preferred method for performing the migration. You must have access to your existing inventory file with both the master and external etcd host defined in their separate groups.
In order to perform the migration on Red Hat Enterprise Linux Atomic Host, you must be running Atomic Host 7.4 or later.
Pull the latest subscription data from RHSM:
# subscription-manager refresh
To get the latest playbooks, manually disable the OpenShift Origin 3.6 channel and enable the 3.7 channel on the host you are running the migration from:
# subscription-manager repos --disable="rhel-7-server-ose-3.6-rpms" \ --enable="rhel-7-server-ose-3.7-rpms" \ --enable="rhel-7-server-extras-rpms" \ --enable="rhel-7-fast-datapath-rpms" # yum clean all
Add etcd
under the [OSEv3:children]
section if it does not already exist:
[OSEv3:children] masters nodes etcd
Your inventory file is expected to have exactly one host in an [etcd]
host group. In
most scenarios, it is best to use your existing master, as there is no need for
a separate host.
Add an [etcd]
host group to your inventory file if it does not already exist,
and list the host to migrate your etcd to:
[etcd] master1.example.com
Run the embedded2external.yml playbook using your inventory file:
# ansible-playbook [-i /path/to/inventory] \ ~/openshift-ansible/playbooks/openshift-etcd/embedded2external.yml
Successful completion of the playbook will show the following:
INSTALLER STATUS ************************************** Initialization : Complete etcd Install : Complete
To verify that the migration from embedded to external etcd was successful, run
the following on the etcd host and check for an etcd
process:
# ps -aux | grep etcd etcd 22384 2.1 3.9 5872848 306072 ? Ssl 10:36 0:02 /usr/bin/etcd --name=master1.example.com --data-dir=/var/lib/etcd/ --listen-client-urls=https://192.168.122.197:2379