DTS + Jobs equivalent in MySQL

Discussion in 'Server Operation' started by jvilches, Aug 8, 2006.

  1. jvilches

    jvilches New Member

    I have a MS SQL server, there I have a DTS (data transformation services) package designed, the MS SQL connects to a DB2 Database on an IBM AS400 server, gets some data from specified tables and replicates them locally on the MS SQL Database.

    I need to do the same using MySQL, I'dont know if Cron will do the job or does the latest version of MySQL has this feature, and how do I use it.

    How do I connect to a DB2 database from MySQL to grab some data, and how do I schedule this task to run every certain time?
  2. jvilches

    jvilches New Member

    MySQL Migration Toolkit

    Googling for a solution I came across the MySQL Migration Toolkit.

    With this tool and JTOpen I can succesfully connect to the DB2 database on my AS400 server, grab the data I need and copy it on a MySQL table.

    The program can export a migration script so I guess I can use cron to run this script on a schedule.

    The problem is, I did all this on a Windows PC. I need to do this on my Ubuntu 6.06 Server, I have no prior experience on Linux so I don't know how to install ANYTHING, I need to install the MySQL Migration Toolkit and JTOpen.

    Maybe someone from this forum can offer some kind help, I am looking for information online but am having trouble finding what I need.

    Also I would be good to know if there is an easier solution for what I'm trying to accomplish or am I on the right track.

  3. falko

    falko Super Moderator ISPConfig Developer

  4. jvilches

    jvilches New Member

    PHP vs. MMT (MySQL Migration Toolkit)

    Oops.. I didn't see a Readme file at first, but now I double checked and found the documentation, thanks.

    Another thing, do you think it would be a good solution to create a PHP script to get the data from de DB2 to the MySQL and schedule a cron job to run this script everyday?

    Do you have any ideas of Pros and Cons of doing this instead of using MMT?

    Thanks Falko you are of great help.
    Last edited: Aug 9, 2006
  5. falko

    falko Super Moderator ISPConfig Developer

    If you don't need both databases to be in sync at any time, you can do that. :)
  6. nomadix23

    nomadix23 New Member

    MMT on CentOS

    Hi jvilches, your scenario is seemingly similar to ours. This discussion is in fact an inspiration to our conceived setup and that i wanted to compile MMT on CentOS. With my readings, MMT requires Java 5.0 or 1.4.2 Runtime Environment (JRE). Is this similar to JTOpen? With yum list | grep java, the results were:


    Do you know which of these packages corresponds to the requirement of MMT? May I also ask how successful your migration went? Your input means a lot, thanks.
  7. falko

    falko Super Moderator ISPConfig Developer

    I'd try to install java-1.5.0-centos.i586.
  8. jvilches

    jvilches New Member

    Hey Nomadix23,

    Actually I didn't install jre nor MMT. I ended up writing a PHP script that connects to DB2 and with the help of cron I run this script every day at specified intervals... that pretty much solved my problem.

    I hope you can find a solution using MMT, I found the PHP script solution easier, quicker and effective for my needs.
  9. nomadix23

    nomadix23 New Member

    thanks for the info, jvilches.
    thanks too, falko.

    I have actually tried installing some of the core java packages provided by CentOS but I ended up encountering multiple error messages upon executing ./run_migration. Solving one error would lead to another error until it states that it cannot find the Java Objects. Despite testimonies that installing MMT on Linux is somewhat complex, I have high hopes that we can make it run in the end.

    Accessing DB2 through php is also a promising alternative but will "execution timeout" be not an issue especially when data being flushed is in bulk?
  10. falko

    falko Super Moderator ISPConfig Developer

    You can put
    in your PHP script if it times out.

Share This Page