Categories

Versions

You are viewing the RapidMiner Server documentation for version 9.1 -Check here for latest version

Upgrading from 7.x to 9.1

We have detected a problem in a number of migrations. If you are upgrading from an older version, we recommend you to wait for the release of RapidMiner Server 9.0.3 before starting a migration from 7.x to 9.x.

RapidMiner 9.x is utilizing a much faster file-based repository. Old repository content will be migrated from database to disk. The length of the migration procedure depends on the repository size.

This section describes updating RapidMiner Server from 7.x to 9.1 using thefull upgrade. It also describes the process for rolling back the upgrade.

Performing a full upgrade

A full upgrade means installing RapidMiner Server into an empty directory while pointing the database to the existing one.

Stop RapidMiner Server 7.x and perform a backup

  1. Stop RapidMiner Server 7.x. If running Windows, verify that all RapidMiner-related services have stopped.

  2. Back up your RapidMiner Server operations database.

  3. Back up your RapidMiner extensions. If you are unsure of the directory location, check the setting on theAdministration > System Settingspage. The location is the value defined for the propertycom.rapidanalytics.plugindir.

Note: It is strongly recommended that youback up the RapidMiner Server operations database之前修改的软件版本。Especially as version 9 introduces major changes to the database layout.

Install RapidMiner Server 9.1

  1. Download version 9.1 of thefull server package.

  2. Change to thebin/directory, within the installation directory, to locate (and then run) the start script (or batch file) for installing the new version of RapidMiner Server software.

Note: It is strongly recommended to use a fresh folder for RapidMiner Server 9.1 instead of installing it into an existing RapidMiner Server 7.x folder.

Restore previous configuration

  1. Copy the contents of the backed up extension folder into your extensions directory.

  2. From RapidMiner Server 9 and above all configuration files are stored within thehome directory. Instead of editing files within the RapidMiner Server installation folder, you have to re-apply the configuration changes you made to the previous version of RapidMiner Server in the home directory. For example if you modifiedstandalone.xmlthen manually re-apply the pieces you changed to the new version in
    /configuration/standalone.xml了。不要复制整个文件,因为它可能会改变吗from version to version.

Start RapidMiner Server 9.1 and perform migration steps

  1. From the new installation folder, start RapidMiner Server.

  2. Log on to RapidMiner Server as admin and perform necessary update steps (e.g. migrate existing queues).

  3. (Optional) Check queue setup and install furtherJob Agents.

Note: It is advised to migrate all extensions to the extensions folder within thehome directoryto ease upgrading RapidMiner Server. To do so, update the propertycom.rapidanalytics.plugindiron theAdministration > System Settingspage (for example/resources/extensions/) once you’ve started the server. You have to copy your old extensions to the new location and restart the server.

Note: If you are usingRadoop, make sure you go through the specific installation stepsdescribed in the Radoop documentation, as these steps have changed in Server 9.1.

Note: If your extensions are not compatible with the latest RapidMiner Server, you have to replace the old extensions in your extensions folder with new ones you’ve downloaded or extracted. Seeinstalling extensionsfor more information. After you’ve finished upgrading RapidMiner Server, you should verify that all your extensions are loaded, by navigating to theAdministration > Operators & Extensionspage and comparing the listed extensions with the files residing in your extensions folder.

Rolling back a full upgrade

To roll back an upgrade:

  1. Stop RapidMiner Server. If running Windows, verify that all RapidMiner-related services have stopped.

  2. Restore your RapidMiner Server database from backup. If unsure how to do so, try searching Google for the appropriate commands for your database type.

  3. If you backed up your previous installation directory (because you installed the new version to a directory where an old version existed) then replace the installation directory from backup.

  4. From the previous (old) installation folder, start RapidMiner Server.

Delete old repository content

From RapidMiner 9.1 and above all repository contents reside on your filesystem. The migration step which initially copied all data to your filesystem did not delete content from your database intentionally to ensure no data will be lost during the migration. Files stored within databases utilize disk space the same way files would do on your filesystem. In the long term, you don't need the old repository contents which reside in your database because they are also on your disk. If you wish to delete the outdated repository content from the database and free up disk space follow the instructions for your database.Please read through all those instructions carefully before you start.

As the deletion of the old repository content is a destructive operation, we strongly advise to backup the RapidMiner Server database.

Please ensure all migrations ran sucessfully and that you can sign in into your fresh RapidMiner Server 9.1.

Please ensure you execute all statements for your setup as the correct database user in the correct database. If you run the SQL statements below as a different user or within a wrong database not related to RapidMiner Server, data might be lost. Be sure to backup all databases before if you’re unsure.

It’s advised to shutdown RapidMiner Server before starting the deletion of old repository content.

PostgreSQL

If you're using PostgreSQL as database for RapidMiner Server, please execute the following SQL statement as query with the official PostgreSQL toolpgAdmin4.

If you changed the default PostgreSQL schema (defaults topublic), please change it in the script by adjusting the variableschema_to_search = 'public'toschema_to_search = 'my_postgres_schema'.

-- adjust "schema_to_search" if you've changed the PSQL SCHEMA with the one you're using on RapidMiner Server -- clear ExampleSet tables DO $$ DECLARE stmt text; table_rec RECORD; schema_to_search varchar := 'public'; prefix_to_search varchar := 'es_%'; BEGIN FOR table_rec IN ( SELECT table_name AS tname FROM information_schema.TABLES WHERE table_schema = schema_to_search AND table_name LIKE prefix_to_search ) LOOP raise notice 'Dropping table: %', table_rec.tname; EXECUTE 'DROP TABLE IF EXISTS '||table_rec.tname||' CASCADE'; END LOOP; END; $$ LANGUAGE plpgsql; -- set version table contents to not use ByteBuffers anymore UPDATE ra_ent_version SET blobbuffer_id = null; UPDATE ra_ent_version SET ioobjectbuffer_id = null; UPDATE ra_ent_version SET metadatabuffer_id = null; UPDATE ra_ent_version SET xmlbuffer_id = null; -- clear ByteBuffer table contents DELETE FROM ra_ent_bytebuffer;

Microsoft SQL Server

If you're using Microsoft SQL Server as database for RapidMiner Server please execute the following statement as query with tools likeDBeaverorHeidiSQL.

-- clear ExampleSet tables DECLARE @cmd varchar(4000) DECLARE cmds CURSOR FOR SELECT 'drop table [' + Table_Name + ']' FROM INFORMATION_SCHEMA.TABLES WHERE Table_Name LIKE 'es_%' OPEN cmds WHILE 1 = 1 BEGIN FETCH cmds INTO @cmd IF @@fetch_status != 0 BREAK EXEC(@cmd) END CLOSE cmds; DEALLOCATE cmds -- set version table contents to not use ByteBuffers anymore UPDATE ra_ent_version SET blobbuffer_id = null; UPDATE ra_ent_version SET ioobjectbuffer_id = null; UPDATE ra_ent_version SET metadatabuffer_id = null; UPDATE ra_ent_version SET xmlbuffer_id = null; -- clear ByteBuffer table contents DELETE FROM ra_ent_bytebuffer;

Oracle

If you're using Oracle SQL as database for RapidMiner Server please execute the following statements sequentially with the official Oracle toolOracle SQL Developer.

If you're using a custom tablespace name (defaults toSYSTEM), you have to change it in the script by adjustingtablespace_name = 'SYSTEM'totablespace_name = 'MY_TABLESPACE_NAME'.

To execute the following statements use therun scriptbutton.

-- adjust "tablespace_name" with the one you're using on RapidMiner Server -- create procedure CREATE OR REPLACE PROCEDURE REPOMIGRATION AS BEGIN FOR c IN (SELECT table_name FROM user_tables WHERE tablespace_name = 'SYSTEM' AND table_name LIKE 'es_'||'%') LOOP DBMS_OUTPUT.PUT_LINE('Dropping table "'||c.table_name||'"'); EXECUTE IMMEDIATE 'DROP TABLE "'||c.table_name||'"'; END LOOP; END REPOMIGRATION;
BEGIN -- clear ExampleSet tables REPOMIGRATION(); END;
-- set version table contents to not use ByteBuffers anymore UPDATE ra_ent_version SET blobbuffer_id = null; UPDATE ra_ent_version SET ioobjectbuffer_id = null; UPDATE ra_ent_version SET metadatabuffer_id = null; UPDATE ra_ent_version SET xmlbuffer_id = null;
-- clear ByteBuffer table contents DELETE FROM ra_ent_bytebuffer;

If all statements were executed sucessfully, you can delete the created procedureREPOMIGRATIONby executing the following statement:

DROP PROCEDURE REPOMIGRATION;

MySQL

If you're using MySQL as database for RapidMiner Server please execute the following statements sequentially with the official MySQL toolMySQL Workbench.

分隔符/ /——如果创建程序删除过程EXISTS printf// CREATE PROCEDURE printf(txt TEXT) BEGIN SELECT txt as ''; END; // DROP PROCEDURE IF EXISTS repoMigration// CREATE PROCEDURE repoMigration() BEGIN DECLARE prefix_to_search VARCHAR(255) DEFAULT 'es_%'; DECLARE table_name VARCHAR(255); DECLARE end_of_tables INT DEFAULT 0; DECLARE cur CURSOR FOR SELECT t.table_name FROM information_schema.tables t WHERE t.table_schema = DATABASE() AND t.table_name LIKE prefix_to_search; DECLARE CONTINUE HANDLER FOR NOT FOUND SET end_of_tables = 1; call printf(prefix_to_search); SET FOREIGN_KEY_CHECKS = 0; OPEN cur; tables_loop: LOOP FETCH cur INTO table_name; call printf(table_name); IF end_of_tables = 1 THEN LEAVE tables_loop; END IF; SET @s = CONCAT('DROP TABLE IF EXISTS ' , table_name); PREPARE stmt FROM @s; EXECUTE stmt; END LOOP; CLOSE cur; SET FOREIGN_KEY_CHECKS = 1; END; // DELIMITER ;
-- clear ExampleSet tables CALL repoMigration();
-- set version table contents to not use ByteBuffers anymore UPDATE ra_ent_version SET blobbuffer_id = null; UPDATE ra_ent_version SET ioobjectbuffer_id = null; UPDATE ra_ent_version SET metadatabuffer_id = null; UPDATE ra_ent_version SET xmlbuffer_id = null;
-- clear ByteBuffer table contents DELETE FROM ra_ent_bytebuffer;

If all statements were executed sucessfully, you can delete the created proceduresprintfandrepoMigrationby executing the following statement:

DROP PROCEDURE IF EXISTS printf; DROP PROCEDURE IF EXISTS repoMigration;