Note |
---|
READ CAREFULLY: Only attempt to migrate the databases between supervisors of the same version ; READ CAREFULLY. This document applies to Qube 7.0 and above only, where MySQL has been replaced with PostgreSQL. Refer to older versions of this document for earlier versions of the supervisor. |
If you're doing this to install a new supervisor and want to run the latest version of Qube! on the new supervisor, match versions between the supervisors first, and then upgrade the new supervisor once the databases have been migrated over to it.
If you're running Qube 6.0 or later, you will need to contact Sales at PipelineFX in order to get your Qube licenses moved over to the new machine. TheyThey'll need a MAC address for the new supervisor host.
To migrate a Qube supervisor, you need to migrate both the MySQL PostgreSQL databases and the job logs if the job logs are stored on the supervisor's local disk. If If your job logs are stored on the network you will not have to move them, simply set the supervisor_logpath on the new supervisor to point to the same network directory as the old supervisor.
It is recommended that is recommended that you start moving the job logs before you start migrating the MySQL PostgreSQL databases, as the job logs will take longer to move.
Don't forget to duplicate any settings you've changed in the old supervisor's qb.conf.
To migrate the
...
PostgreSQL database:
...
GRANT ALL PRIVILEGES ON *.* TO 'root'@'192.168.1.1';
...
mysql -u root -h <newHostName> -B -e "SELECT USER()"
...
USER() root@192.168.1.1
...
cd /usr/local/mysql/data
...
\ls -d *qube
1qube 2qube 3qube 4qube 5qube 6qube 7qube 8qube qube
...
mysqldump --opt --databases `\ls -d *qube` | mysql -u root -h <linux ip address>
Those are backticks around the "\ls -d *qube" command. The backtick is the left-leaning single-quote below the ~ character on the keyboard.
Note | ||
---|---|---|
| ||
old supervisor: mysqldump --opt --databases 1qube 2qube 3qube ... qube > some_file.sql The list of qube databases (1qube 2qube 3qube, etc) can be found by looking in c:\Program Files\pfx\qube\mysql\data for all files that contain the word "qube". |
Info |
---|
If you get a error message: [ERROR] mysqld: Can't open file: './<database>/<table>.frm' (errno: 24) You need to increase your open_file_limits in my.cnf. On the old supervisor, add: open_files_limit = 100000 to the [mysqld] section of my.cnf |
The mysqldump should take quite a while to finish, and will print no output. A way to check if it's doing the right thing while it's running is to login to the mysql server on linux machine, and run
mysql> SHOW DATABASES LIKE '%qube';
...
mysqladmin -u root flush-privileges
mysqlcheck -u root --repair --all-databases
...
...
Stop the postgresql-pfx service on the old and new supervisors, then just copy the data directory to the new supervisor host. Make sure that the file ownership and permissions are all preserved (they should belong to the "pfx" user).
The location of the data directory is:
Linux: /usr/local/pfx/pgsql/data
Mac: /Applications/pfx/pgsql/data
Windows: C:\Program Files\pfx\pgsql\data
Once that's done, you should start the postgresql-pfx service and the supervisor service on the new machine.
On the new supervisor, verify that the jobs are present:
No Format |
---|
qbjobs -u all |
Verify that you can see the logs for a random job: :
...
No Format |
---|
qbout <someJobId> |