Manual upgrade to Cloudera Base on premises
Manual steps to follow for upgrading a Cloudera Runtime cluster to a higher version of Cloudera Runtime if the Upgrade Wizard fails.
All the following steps assume the starting Cloudera Runtime version is at least 7.0.3, because those are the lowest versions that Cloudera Manager 7.1 supports. The following steps are required when you are upgrading Cloudera Runtime cluster from Cloudera Runtime 7.0.3 to Cloudera Runtime 7.1.1 or higher versions.
The following steps should be executed roughly in the order that they are listed, and should only be executed if the service is configured.
Upgrade Ranger database and apply patches
-
Go to the RANGER service.
-
Select and apply patches and click Upgrade Ranger Database and apply patches to confirm.
Setup Ranger Admin Component
-
Go to the Ranger service.
-
Select and click Setup Ranger Admin Component to confirm.
Start Ranger
-
Go to the Ranger service.
-
Select .
Set up the Ranger Plugin service
-
Go to the Ranger service.
-
Select and click Setup Ranger Plugin Service to confirm.
Start Kudu
- Go to the KUDU service.
- Select .
Start ZooKeeper
- Go to the ZooKeeper service.
- Select .
Upgrade HDFS Metadata
- Go to the HDFS service.
- Select and click Upgrade HDFS Metadata to confirm.
Start HDFS
- Go to the HDFS service.
- Select .
Start YARN QueueManager
-
Go to the QueueManager service.
-
Select .
Import Sentry Polices to Ranger
-
Go to the HDFS service.
-
Select and click Import Sentry Policies into Ranger to confirm.
Start HBASE
- Go to the HBASE service.
- Select .
Start YARN QueueManager
-
Go to the QueueManager service.
-
Select .
Clean NodeManager Recovery Directory (YARN)
-
Go to the YARN service.
-
Select and click Clean NodeManager Recovery Directory to confirm.
Reset ACLs on YARN Zookeeper nodes
Any other upgrade if Enable ResourceManager Recovery is enabled for a Resource Manager group (for example, ResourceManager Default Group) and ZooKeeper is a dependency of YARN. Note that when YARN is running in High Availability mode, ResourceManager recovery is always enabled.
- Go to the YARN service.
- Select
- Click Reset ACLs on YARN Zookeeper nodes to confirm.
Install YARN MapReduce Framework Jars
- Go to the YARN service.
- Select and click Install YARN MapReduce Framework JARs to confirm.
Start YARN
- Go to the YARN service.
- Select .
Deploy Client Configuration Files
- On the Home page, click to the right of the cluster name and select Deploy Client Configuration.
- Click the Deploy Client Configuration button in the confirmation pop-up that appears.
Reinitialize Solr State for Upgrade
-
Go to the SOLR service.
-
Select and click Reinitialize Solr State for Upgrade to confirm.
Bootstrap Solr Configuration
-
Go to the SOLR service.
-
Select and click Bootstrap Solr Configuration to confirm.
Start Solr
-
Go to the SOLR service.
- Select .
Bootstrap Solr Collections
-
Go to the SOLR service.
-
Select and click Bootstrap Solr Collections to confirm.
Create HDFS Home directory
-
Go to the infrastructure SOLR service.
-
Select and click Create HDFS Home Dir to confirm.
Create Ranger Plugin Audit Directory
-
Go to the Solr service.
-
Select and click Create Ranger Plugin Audit Directory to confirm.
Start infrastructure Solr
- Go to the infrastructure SOLR service.
- Select .
Start HBASE
- Go to the HBASE service.
- Select .
Start KAFKA
- Go to the KAFKA service.
- Select .
Create Ranger Kafka Plugin Audit Directory
-
Go to the KAFKA service.
-
Select and click Create Ranger Kafka Plugin Audit Directory to confirm.
Create HBase tables for Atlas
-
Go to the ATLAS service.
-
Select and click Create HBase tables for Atlas to confirm.
Start Atlas
-
Go to the ATLAS service.
- Select .
Create Ranger Atlas Plugin Audit Directory
-
Go to the ATLAS service.
-
Select and click Create Ranger Atlas Plugin Audit Directory to confirm.
Start Phoenix
-
Go to the PHOENIX service.
- Select .
Install MapReduce Framework Jars
- Go to the YARN service.
- Select and click Install YARN MapReduce Framework JARs to confirm.
Start YARN
- Go to the YARN service.
- Select .
Deploy Client Configuration Files
- On the Home page, click to the right of the cluster name and select Deploy Client Configuration.
- Click the Deploy Client Configuration button in the confirmation pop-up that appears.
Upgrade the Hive Metastore Database
- Go to the Hive service.
- If the Hive service is running, stop it:
- Select and click Stop to confirm.
- Select and click Upgrade Hive Metastore Database Schema to confirm.
- If you have multiple instances of Hive, perform the upgrade on each metastore database.
- Select and click Validate Hive Metastore Schema to check that the schema is now valid.
Start Hive
- Go to the Hive service.
- Select .
Create Hive Warehouse Directory
-
Go to the HIVE service.
-
Select and click Create Hive Warehouse Directory to confirm.
Create Hive Warehouse External Directory
-
Go to the HIVE service.
-
Select and click Create Hive Warehouse External Directory to confirm.
Create Hive Sys database
-
Go to the HIVE service.
-
Select and click Create Hive Sys database to confirm.
Create Ranger Plugin Audit Directory
-
Go to the HIVE service.
-
Select and click Create Ranger Plugin Audit Directory to confirm.
Start Impala
- Go to the Impala service.
- Select .
Create Ranger Plugin Audit Directory
- Go to the Impala service.
-
Select and click Create Ranger Plugin Audit Directory to confirm.
Create Spark Driver Log Dir
-
Go to the SPARK_ON_YARN service.
-
Select and click Create Spark Driver Log Dir to confirm.
Start Spark
-
Go to the SPARK_ON_YARN service.
- Select .
Start Livy
-
Go to the LIVY service.
- Select .
Upgrade Oozie Database Schema
-
Go to the OOZIE service.
-
If the OOZIE service is running, stop it:
Select Actions > Stop and click Stop to confirm.
-
Select and click Upgrade Oozie Database Schema to confirm.
Updating column types in Oozie Database
If the Oracle database is used for Oozie, then you must update the
APP_PATH column type to store values with more than 255 characters. This
ensures Oozie does not get stuck in PREP state when your application path exceeds the 255
character limit. If the APP_PATH column type is not updated, then Oozie
fails to run the jobs with the following database error message Data too long
for column 'app_path'. This scenario is also applicable to coordinator and
bundle jobs. For database types other than Oracle, this update is not mandatory for using
Oozie. It works without the update if the APP_PATH value does not exceed
255 characters. Also, Oozie's internal database schema validation fails with an unexpected
APP_PATH column type. However, this validation does not have any effect.
It just logs it's result.
APP_PATH column type in the
WF_JOBS, BUNDLE_JOBS, and
COORD_JOBS tables in the Oozie database for the following
conditions:- When you use the Oracle database for Oozie service.
- When you are upgrading Cloudera Runtime from earlier versions to Cloudera Base on premises 7.1.9 SP1 CHF1 version or later.
If you do not execute the following statements on the Oozie Oracle database, then the Oozie service fails to run the jobs with a database persistence error. This update is not mandatory, but highly recommended for other database types, such as MySQL, MariaDB, and PostgreSQL, due to the internal database schema validation.
- On the Oozie Oracle database - The following example uses the Oracle sqlplus
command-line
tool:
sqlplus <OOZIE_DB_USERNAME>@localhost/<SERVICE_NAME> SQL> ALTER TABLE <TABLE_NAME> ADD (APP_PATH_TMP CLOB); Table altered. SQL> UPDATE <TABLE_NAME> SET APP_PATH_TMP = APP_PATH; X rows updated. SQL> ALTER TABLE <TABLE_NAME> DROP COLUMN APP_PATH; Table altered. SQL> ALTER TABLE <TABLE_NAME> RENAME COLUMN APP_PATH_TMP TO APP_PATH; Table altered. - On the Oozie MySQL database - The following example uses the MySQL mysql command-line
tool:
$ mysql -u root -p Enter password: mysql> use <OOZIE_DATABASE_NAME>; Database changed mysql> ALTER TABLE <TABLE_NAME> MODIFY COLUMN app_path text; Query OK, X rows affected (0.03 sec) Records: X Duplicates: 0 Warnings: 0 mysql> exit Bye - On the Oozie MariaDB database - The following example uses the MariaDB mysql
command-line tool:
$ mysql -u root -p Enter password: MariaDB [(none)]> use <OOZIE_DATABASE_NAME>; Database changed MariaDB [OOZIE_DATABASE_NAME]> ALTER TABLE <TABLE_NAME> MODIFY COLUMN app_path text; Query OK, X rows affected (2.11 sec) Records: X Duplicates: 0 Warnings: 0 MariaDB [OOZIE_DATABASE_NAME]> exit Bye - On the Oozie PostgreSQL database - The following example uses the PostgreSQL psql
command-line tool:
$ psql -U postgres Password for user postgres: ***** postgres=# \c <OOZIE_DATABASE_NAME>; You are now connected to database "<OOZIE_DATABASE_NAME>" as user "postgres". OOZIE_DATABASE_NAME=# ALTER TABLE <TABLE_NAME> ALTER COLUMN app_path type text; ALTER TABLE OOZIE_DATABASE_NAME=# \q
Upgrade Oozie SharedLib
- Go to the Oozie service.
- If the OOZIE service is stopped, start it:
Select and click Start to confirm.
- Select and click Install Oozie SharedLib to confirm.
Upload Tez tar file to HDFS
-
Go to the TEZ service.
-
Select Actions > Upload Tez tar file to HDFS and click Upload Tez tar file to HDFS to confirm.
Migrate Hive tables for Cloudera Base on premises upgrade
-
Go to the HIVE_ON_TEZ service.
-
Select and click Migrate Hive tables for CDP upgrade to confirm.
Create Ranger Plugin Audit Directory
- Go to the Hive-on-Tez service.
-
Select and click Create Ranger Plugin Audit Directory to confirm.
Start Hive on Tez
- Go to the Hive-on-Tez service.
- Select .
Start Hue
- Go to the HUE service.
- Select .
Start the Remaining Cluster Services
-
Use rolling restart or full restart.
-
Ensure that all services are started or restarted. You can use Cloudera Manager to start the cluster, or you can restart the services individually. The Cloudera Manager Home page indicates which services have stale configurations and require restarting.
-
To start or restart the cluster:
-
On the page, click the down arrow to the right of the cluster name and select Start or Restart.
-
Click Start that appears in the next screen to confirm. The Command Details window shows the progress of starting services.
-
When All services successfully started appears, the task is complete and you can close the Command Details window.
-
Validate the Hive Metastore Database Schema
- Select and click Validate Hive Metastore Schema to confirm.
- If you have multiple instances of Hive, perform the validation on each metastore database.
- Select and click Validate Hive Metastore Schema to check that the schema is now valid.
Test the Cluster and Finalize HDFS Metadata
To determine if you can finalize the upgrade, run important workloads and ensure that they are successful. After you have finalized the upgrade, you cannot roll back to a previous version of HDFS without using backups. Verifying that you are ready to finalize the upgrade can take a long time.
-
- Go to the HDFS service.
- Click the Instances tab.
- Click the link for the NameNode instance. If you have enabled
high availability for HDFS, click the link labeled
NameNode (Active).
The NameNode instance page displays.
- Select and click Finalize Metadata Upgrade to confirm.
Clear the Upgrade State Table
- Log in to the Cloudera Manager server host.
- Stop the
Server.
sudo systemctl stop cloudera-scm-server - Log in to the command-line environment for the Cloudera Manager
database. (
mysql,sqlplus, orpostgres psql). - Run the following
command:
DELETE FROM UPGRADE_STATE; - Start the
Server.
sudo systemctl start cloudera-scm-server
