IQ migration from Solaris to Linux

Posted on 2011-10-15
Last Modified: 2012-08-30

What is the best way to migrate Sybase IQ database from SUN Solaris to Linux?

Question by:ncshome170
    LVL 24

    Accepted Solution

    There isn't very much in IQ-land that is platform-specific.

    Raw partitions work differently under Linux compared to Solaris. Read the Installation Guide and Release Notes for IQ on Linux carefully, there are some things you have to set up first before installation.

    The other thing to consider is that native IQ backups can't cross platforms, so alas, you cannot simply backup on Solaris and restore on Linux. Do you have the ability to recreate your IQ database from upstream data? If so, just install & recreate on Linux.

    If not, you'll have to think about some kind of data unload or extract followed by a load. You have a few options here so it's worth testing & timing them as I can't predict which will be fastest. You could set up Open Client connections from IQ on Linux to IQ on Solaris and attempt one INSERT ... LOCATION command per table, but that's the slowest way to load IQ. If you have disk space, extract each table to file (fixed width is faster to load but takes potentially a lot more disk space) and then load from each file.

    The schema part is pretty easy. If you don't already have scripts to recreate your schema, you can use Sybase's PowerDesigner to reverse-engineer your current schema. If you don't already have a licensed copy you can download a 30-day eval from the Sybase site.

    Most of your effort will go to migrating the data; installation is fast, recreating all objects is fast, it's moving the data that's slow.

    Good luck!
    LVL 2

    Assisted Solution

    Hi CS,

    Joe has a good point that it is difficult to predict which will be the fastest way of loading IQ.  The question comes down to whether it is faster to extract the table to disk, and then load it via load table, or use insert..location.  

    I have had good success with cross platform migrations by scripting the extract and load of each table - what I do I have a script that migrates a list of tables so I can have multiple instances of the script running in parallel with other instances, each migrating a subset of tables.  

    Each script processes a list and does the following for each table in its "input list":

    1.)  extract schema for the source table and apply it to the target database.
    2.)  extract the table's data in ascii format using delimiters to local disk.
    3.)  load table "using client file" across the network to the target database.
    4.)  clean up and move on to the next table.

    At the end of the job, check row counts on all source and target tables to be sure they match.  

    Check out the attached sp_iqclonetable procedure, you can use this to extract schema and reverse DDL.   (or use PowerDesigner, as it is a more complete solution.)


    - David sp-iqclonetable-15.sql

    Author Closing Comment

    thanks for the clarification Joe & David. I appreciate it.

    Warm Regards,

    Expert Comment

    I didn't see any issues regarding the differences in endian structure format  differences between Sun and Linux? Linux stores data in the opposite endian format as Sun. From my research the data would have to be moved using ; BINARY WITH NULL BYTE ? Did none of you run into this when moving the data from Sun to Linux Sybase IQ?
    LVL 24

    Expert Comment

    by:Joe Woodhouse
    I had understood endian to be more a matter of hardware than of O/S. For example simply changing O/S but remaining on the same hardware wouldn't have this issue.

    We don't know enough here to know if that's the case. Good catch of a potential issue though!

    Featured Post

    Free Trending Threat Insights Every Day

    Enhance your security with threat intelligence from the web. Get trending threat insights on hackers, exploits, and suspicious IP addresses delivered to your inbox with our free Cyber Daily.

    Join & Write a Comment

    Suggested Solutions

    Title # Comments Views Activity
    Best Fit Equation for a Line 5 808
    Sybase sample database 13 647
    ODBC error on 64bit mahcine 4 101
    sql statement error 18 68
    Outlook Free & Paid Tools
    For both online and offline retail, the cross-channel business is the most recent pattern in the B2C trade space.
    how to add IIS SMTP to handle application/Scanner relays into office 365.
    Excel styles will make formatting consistent and let you apply and change formatting faster. In this tutorial, you'll learn how to use Excel's built-in styles, how to modify styles, and how to create your own. You'll also learn how to use your custo…

    729 members asked questions and received personalized solutions in the past 7 days.

    Join the community of 500,000 technology professionals and ask your questions.

    Join & Ask a Question

    Need Help in Real-Time?

    Connect with top rated Experts

    17 Experts available now in Live!

    Get 1:1 Help Now